<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/tty, branch v3.1-rc9</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/drivers/tty?h=v3.1-rc9</id>
<link rel='self' href='https://git.amat.us/linux/atom/drivers/tty?h=v3.1-rc9'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2011-09-15T01:09:38Z</updated>
<entry>
<title>cris: fix a build error in drivers/tty/serial/crisv10.c</title>
<updated>2011-09-15T01:09:38Z</updated>
<author>
<name>WANG Cong</name>
<email>xiyou.wangcong@gmail.com</email>
</author>
<published>2011-09-14T23:22:06Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=83ede96e98f5a7eb3ed07c78cb1dd166581eb864'/>
<id>urn:sha1:83ede96e98f5a7eb3ed07c78cb1dd166581eb864</id>
<content type='text'>
Fix these errors:

    drivers/tty/serial/crisv10.c:4453: error: 'if_ser0' undeclared (first use in this function): 2 errors in 2 logs
    drivers/tty/serial/crisv10.c:4453: error: (Each undeclared identifier is reported only once: 2 errors in 2 logs
    drivers/tty/serial/crisv10.c:4453: error: for each function it appears in.): 2 errors in 2 logs

"if_ser0" is a typo, it should be "if_serial_0".

Signed-off-by: WANG Cong &lt;xiyou.wangcong@gmail.com&gt;
Cc: Mikael Starvik &lt;starvik@axis.com&gt;
Cc: Jesper Nilsson &lt;jesper.nilsson@axis.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Merge branch 'sh-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-3.x</title>
<updated>2011-08-29T20:34:48Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2011-08-29T20:34:48Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=c42a2634d8495a764e918a8c4252c100ef23b369'/>
<id>urn:sha1:c42a2634d8495a764e918a8c4252c100ef23b369</id>
<content type='text'>
* 'sh-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-3.x:
  sh: fix the compile error in setup-sh7757.c
  serial: sh-sci: report CTS as active for get_mctrl
  sh: Add unaligned memory access for PC relative intructions
  sh: Fix unaligned memory access for branches without delay slots
  sh: Fix up fallout from cpuidle changes.
  serial: sh-sci: console Runtime PM support
  sh: Fix conflicting definitions of ptrace_triggered
  serial: sh-sci: fix DMA build by including dma-mapping.h
  serial: sh-sci: Fix up default regtype probing.
  sh: intc: enable both edges GPIO interrupts on sh7372
  shwdt: fix usage of mod_timer
  clocksource: sh_cmt: wait for CMCNT on init V2
</content>
</entry>
<entry>
<title>serial: sh-sci: report CTS as active for get_mctrl</title>
<updated>2011-08-29T06:47:33Z</updated>
<author>
<name>Yoshii Takashi</name>
<email>takashi.yoshii.zj@renesas.com</email>
</author>
<published>2011-08-23T08:27:18Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=4480a688b2beaa82ecac269b6e21bf1a26251bf9'/>
<id>urn:sha1:4480a688b2beaa82ecac269b6e21bf1a26251bf9</id>
<content type='text'>
sh-sci.c sets hardware up and then let the HW do all flow controls.
There is no software code, nor needs to get/set real CTS signal.

But, when turning CRTSCTS on through termios, uart_set_termios() in
serial_core.c checks CTS, and stops TX if it is inactive at the moment.

Because sci_get_mctrl() returns a fixed value DTR|RTS|DSR but CTS,
the sequence
  open -&gt; set CRTSCTS -&gt; write
hit the case and stop working, no more outputs.

This patch makes sci_get_mctrl() report CTS in addition.

Signed-off-by: Takashi YOSHII &lt;takashi.yoshii.zj@renesas.com&gt;
Signed-off-by: Paul Mundt &lt;lethal@linux-sh.org&gt;
</content>
</entry>
<entry>
<title>Merge branch 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm</title>
<updated>2011-08-28T17:05:39Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2011-08-28T17:05:39Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=c11a7e26f8ee60bda0e64983291113ce5d04df55'/>
<id>urn:sha1:c11a7e26f8ee60bda0e64983291113ce5d04df55</id>
<content type='text'>
* 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
  ARM: mach-shmobile: sh7372 LCDC1 suspend fix V2 (incremental)
  OMAP: omap_device: only override _noirq methods, not normal suspend/resume
  PM / Runtime: Correct documentation of pm_runtime_irq_safe()
  ARM: mach-shmobile: sh7372 LCDC1 suspend fix
  sh-sci / PM: Use power.irq_safe
  PM: Use spinlock instead of mutex in clock management functions
</content>
</entry>
<entry>
<title>sh-sci / PM: Use power.irq_safe</title>
<updated>2011-08-24T19:41:08Z</updated>
<author>
<name>Rafael J. Wysocki</name>
<email>rjw@sisk.pl</email>
</author>
<published>2011-08-24T19:41:08Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=5a50a01bf00c8191073fdf518e1af1e950ac3af5'/>
<id>urn:sha1:5a50a01bf00c8191073fdf518e1af1e950ac3af5</id>
<content type='text'>
Since sci_port_enable() and sci_port_disable() may be run with
interrupts off and they execute pm_runtime_get_sync() and
pm_runtime_put_sync(), respectively, the SCI device's
power.irq_safe flag has to be set to indicate that it is safe
to execute runtime PM callbacks for this device with interrupts off.

Signed-off-by: Rafael J. Wysocki &lt;rjw@sisk.pl&gt;
Acked-by: Magnus Damm &lt;damm@opensource.se&gt;
</content>
</entry>
<entry>
<title>omap-serial: Allow IXON and IXOFF to be disabled.</title>
<updated>2011-08-23T17:58:38Z</updated>
<author>
<name>Nick Pelly</name>
<email>npelly@google.com</email>
</author>
<published>2011-07-15T20:53:08Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=b280a97d1caf6fe1d38b51ebb31219391f5ad1a0'/>
<id>urn:sha1:b280a97d1caf6fe1d38b51ebb31219391f5ad1a0</id>
<content type='text'>
Fixes logic bug that software flow control cannot be disabled, because
serial_omap_configure_xonxoff() is not called if both IXON and IXOFF bits
are cleared.

Signed-off-by: Nick Pelly &lt;npelly@google.com&gt;
Acked-by: Govindraj.R &lt;govindraj.raja@ti.com&gt;
Tested-by: Govindraj.R &lt;govindraj.raja@ti.com&gt;
Cc: stable &lt;stable@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>TTY: serial, document ignoring of uart-&gt;ops-&gt;startup error</title>
<updated>2011-08-23T17:10:38Z</updated>
<author>
<name>Jiri Slaby</name>
<email>jslaby@suse.cz</email>
</author>
<published>2011-08-17T11:48:15Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=0055197e984e5fbe6f48f37fc50dd30254915493'/>
<id>urn:sha1:0055197e984e5fbe6f48f37fc50dd30254915493</id>
<content type='text'>
When a user has SYS_ADMIN capabilities and uart-&gt;ops-&gt;startup returns
an error in uart_startup, we silently drop the error. We then return 0
and behave as if it didn't fail. (Not quite, since we set TTY_IO_ERROR
bit and leave ASYNC_INITIALIZED bit cleared.)

This all is to allow setserial to work with improperly configured or
unconfigured ports. User can thus set port properties and reconfigure
properly.

This patch only documents this behavior.

Signed-off-by: Jiri Slaby &lt;jslaby@suse.cz&gt;
Cc: Alan Cox &lt;alan@lxorguk.ukuu.org.uk&gt;
Cc: Russel King &lt;linux@arm.linux.org.uk&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>TTY: pty, fix pty counting</title>
<updated>2011-08-23T17:10:38Z</updated>
<author>
<name>Jiri Slaby</name>
<email>jslaby@suse.cz</email>
</author>
<published>2011-08-10T12:59:28Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=24d406a6bf736f7aebdc8fa0f0ec86e0890c6d24'/>
<id>urn:sha1:24d406a6bf736f7aebdc8fa0f0ec86e0890c6d24</id>
<content type='text'>
tty_operations-&gt;remove is normally called like:
queue_release_one_tty
 -&gt;tty_shutdown
   -&gt;tty_driver_remove_tty
     -&gt;tty_operations-&gt;remove

However tty_shutdown() is called from queue_release_one_tty() only if
tty_operations-&gt;shutdown is NULL. But for pty, it is not.
pty_unix98_shutdown() is used there as -&gt;shutdown.

So tty_operations-&gt;remove of pty (i.e. pty_unix98_remove()) is never
called. This results in invalid pty_count. I.e. what can be seen in
/proc/sys/kernel/pty/nr.

I see this was already reported at:
  https://lkml.org/lkml/2009/11/5/370
But it was not fixed since then.

This patch is kind of a hackish way. The problem lies in -&gt;install. We
allocate there another tty (so-called tty-&gt;link). So -&gt;install is
called once, but -&gt;remove twice, for both tty and tty-&gt;link. The fix
here is to count both tty and tty-&gt;link and divide the count by 2 for
user.

And to have -&gt;remove called, let's make tty_driver_remove_tty() global
and call that from pty_unix98_shutdown() (tty_operations-&gt;shutdown).

While at it, let's document that when -&gt;shutdown is defined,
tty_shutdown() is not called.

Signed-off-by: Jiri Slaby &lt;jslaby@suse.cz&gt;
Cc: Alan Cox &lt;alan@linux.intel.com&gt;
Cc: "H. Peter Anvin" &lt;hpa@zytor.com&gt;
Cc: stable &lt;stable@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>8250: Fix race condition in serial8250_backup_timeout().</title>
<updated>2011-08-23T17:10:37Z</updated>
<author>
<name>Al Cooper</name>
<email>alcooperx@gmail.com</email>
</author>
<published>2011-07-25T20:19:52Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=dbb3b1ca5609d1f3848cd387d06cc60aaacf7f98'/>
<id>urn:sha1:dbb3b1ca5609d1f3848cd387d06cc60aaacf7f98</id>
<content type='text'>
This is to fix an issue where output will suddenly become very slow.
The problem occurs on 8250 UARTS with the hardware bug UART_BUG_THRE.

BACKGROUND
For normal UARTs (without UART_BUG_THRE): When the serial core layer
gets new transmit data and the transmitter is idle, it buffers the
data and calls the 8250s' serial8250_start_tx() routine which will
simply enable the TX interrupt in the IER register and return. This
should immediately fire a THRE interrupt and begin transmitting the
data.
For buggy UARTs (with UART_BUG_THRE): merely enabling the TX interrupt
in IER does not necessarily generate a new THRE interrupt.
Therefore, a background timer periodically checks to see if there is
pending data, and starts transmission if that is the case.

The bug happens on SMP systems when the system has nothing to transmit,
the transmit interrupt is disabled and the following sequence occurs:
- CPU0: The background timer routine serial8250_backup_timeout()
  starts and saves the state of the interrupt enable register (IER)
  and then disables all interrupts in IER. NOTE: The transmit interrupt
  (TI) bit is saved as disabled.
- CPU1: The serial core gets data to transmit, grabs the port lock and
  calls serial8250_start_tx() which enables the TI in IER.
- CPU0: serial8250_backup_timeout() waits for the port lock.
- CPU1: finishes (with TI enabled) and releases the port lock.
- CPU0: serial8250_backup_timeout() calls the interrupt routine which
  will transmit the next fifo's worth of data and then restores the
  IER from the previously saved value (TI disabled).
At this point, as long as the serial core has more transmit data
buffered, it will not call serial8250_start_tx() again and the
background timer routine will slowly transmit the data.

The fix is to have serial8250_start_tx() get the port lock before
it saves the IER state and release it after restoring IER. This will
prevent serial8250_start_tx() from running in parallel.

Signed-off-by: Al Cooper &lt;alcooperx@gmail.com&gt;
Cc: stable &lt;stable@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
<entry>
<title>serial/8250_pci: delete duplicate data definition</title>
<updated>2011-08-23T17:06:28Z</updated>
<author>
<name>Tomoya MORINAGA</name>
<email>tomoya-linux@dsn.okisemi.com</email>
</author>
<published>2011-07-12T07:08:49Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=dacacc3e794c4c5bab05d97afc19e372e1877943'/>
<id>urn:sha1:dacacc3e794c4c5bab05d97afc19e372e1877943</id>
<content type='text'>
Data definiton "VendorID=10DB, device_id=800D" is already defined.
This patch deletes the duplicate definition.

Signed-off-by: Tomoya MORINAGA &lt;tomoya-linux@dsn.okisemi.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;
</content>
</entry>
</feed>
