summaryrefslogtreecommitdiffstats
path: root/drivers/idle
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2011-07-14 14:35:10 +0200
committerGreg Kroah-Hartman <gregkh@suse.de>2011-08-23 10:34:05 -0700
commit1f33a51d9771b34be3cb6f7fb96a325e17bbac7b (patch)
tree02af221f8f5207680caaca17748c90cd2b0bba24 /drivers/idle
parentae8dbd3eb97aad3929a981d3ab8c3cd2caee4ab1 (diff)
TTY: serial, remove BTM from wait_until_sent
During the BKL removal process, the BKL was switched to tty_lock (BTM). Now we should start pruning the BTM further. Let's start with wait_until_sent of the serial layer. This will allow us to switch to the tty port helpers and thus clean it up much. In wait_until_sent there are some uport members accessed, but neither of them is protected by BTM at the location they are set ('=>' means function call): * uport->fifosize (set in tty_ioctl => uart_ioctl => uart_set_info) * uport->type (set in add_one_port prior to tty_register_device) * uport->timeout (set usually in tty_ioctl => tty_mode_ioctl => tty_set_termios => uart_set_termios => uart_change_speed => uport->ops->set_termios => uart_update_timeout) * call to uport->ops->tx_empty() If the tx_empty hook needs some lock to protect accesses to registers, it should take &uport->lock spinlock like 8250 does. Otherwise there still might be races e.g. with ISRs. This should also fix the issue Andreas is seeing (BTM in comparison to BKL doesn't have any hidden functionality like unlocking during sleeping). Signed-off-by: Jiri Slaby <jslaby@suse.cz> References: https://lkml.org/lkml/2011/5/25/562 Cc: Alan Cox <alan@linux.intel.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Cc: Andreas Bombe <aeb@debian.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/idle')
0 files changed, 0 insertions, 0 deletions