linux/drivers/tty
Paul Walmsley 43cf7c0beb tty: serial: OMAP: transmit FIFO threshold interrupts don't wake the chip
It seems that when the transmit FIFO threshold is reached on OMAP
UARTs, it does not result in a PRCM wakeup.  This appears to be a
silicon bug.  This means that if the MPU powerdomain is in a low-power
state, the MPU will not be awakened to refill the FIFO until the next
interrupt from another device.

The best solution, at least for the short term, would be for the OMAP
serial driver to call a OMAP subarchitecture function to prevent the
MPU powerdomain from entering a low power state while the FIFO has
data to transmit.  However, we no longer have a clean way to do this,
since patches that add platform_data function pointers have been
deprecated by the OMAP maintainer.  So we attempt to work around this
as well.  The workarounds depend on the setting of CONFIG_CPU_IDLE.

When CONFIG_CPU_IDLE=n, the driver will now only transmit one byte at
a time.  This causes the transmit FIFO threshold interrupt to stay
active until there is no more data to be sent.  Thus, the MPU
powerdomain stays on during transmits.  Aside from that energy
consumption penalty, each transmitted byte results in a huge number of
UART interrupts -- about five per byte.  This wastes CPU time and is
quite inefficient, but is probably the most expedient workaround in
this case.

When CONFIG_CPU_IDLE=y, there is a slightly more direct workaround:
the PM QoS constraint can be abused to keep the MPU powerdomain on.
This results in a normal number of interrupts, but, similar to the
above workaround, wastes power by preventing the MPU from entering
WFI.

Future patches are planned for the 3.4 merge window to implement more
efficient, but also more disruptive, workarounds to these problems.

DMA operation is unaffected by this patch.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
Cc: Govindraj Raja <govindraj.r@ti.com>
Cc: Kevin Hilman <khilman@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-01-24 14:11:07 -08:00
..
hvc tty: hvc_dcc: Fix duplicate character inputs 2011-11-15 12:02:13 -08:00
ipwireless
serial tty: serial: OMAP: transmit FIFO threshold interrupts don't wake the chip 2012-01-24 14:11:07 -08:00
vt tty: Fix memory leak in virtual console when enable unicode translation 2012-01-04 16:18:55 -08:00
Kconfig Merge branch 'for-linus' of git://github.com/richardweinberger/linux 2011-11-02 09:45:39 -07:00
Makefile tty/powerpc: introduce the ePAPR embedded hypervisor byte channel driver 2011-08-23 10:32:56 -07:00
amiserial.c TTY: irq: Remove IRQF_DISABLED 2011-09-22 16:08:57 -07:00
bfin_jtag_comm.c atomic: use <linux/atomic.h> 2011-07-26 16:49:47 -07:00
cyclades.c TTY: irq: Remove IRQF_DISABLED 2011-09-22 16:08:57 -07:00
ehv_bytechan.c drivers/tty: don't use the byte channel handle as a parameter in ehv_bytechan.c 2011-09-26 16:38:43 -07:00
isicom.c TTY: irq: Remove IRQF_DISABLED 2011-09-22 16:08:57 -07:00
moxa.c drivers/tty: use printk_ratelimited() instead of printk_ratelimit() 2011-07-01 15:35:45 -07:00
moxa.h
mxser.c TTY: mxser+cyclades remove wait_until_sent debug code 2011-08-23 10:34:07 -07:00
mxser.h
n_gsm.c n_gsm: Fix timings 2011-11-08 10:10:20 -08:00
n_hdlc.c tty: n_hdlc not atomic use tty->flags. 2011-11-30 21:30:49 +09:00
n_r3964.c
n_tracerouter.c
n_tracesink.c
n_tracesink.h
n_tty.c drivers/tty: Remove unneeded spaces 2011-12-09 19:11:35 -08:00
nozomi.c
pty.c TTY: pty, cleanup the pty counting 2011-11-17 11:42:09 -08:00
rocket.c module_param: make bool parameters really bool (drivers & misc) 2012-01-13 09:32:20 +10:30
rocket.h
rocket_int.h
synclink.c module_param: make bool parameters really bool (drivers & misc) 2012-01-13 09:32:20 +10:30
synclink_gt.c
synclinkmp.c module_param: make bool parameters really bool (drivers & misc) 2012-01-13 09:32:20 +10:30
sysrq.c fs: move code out of buffer.c 2012-01-03 22:54:07 -05:00
tty_audit.c
tty_buffer.c
tty_io.c Merge branch 'tty-next' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty 2012-01-09 12:09:24 -08:00
tty_ioctl.c tty: Support compat_ioctl get/set termios_locked 2011-10-18 14:17:11 -07:00
tty_ldisc.c Merge 3.2-rc3 into tty-next to handle merge conflict in tty_ldisc.c 2011-11-26 20:07:25 -08:00
tty_mutex.c TTY: remove tty_locked 2011-08-23 10:34:07 -07:00
tty_port.c TTY: fix UV serial console regression 2012-01-24 12:55:37 -08:00