linux-stable/drivers/tty
Johan Hovold 74365bc138 serial: 8250_dw: drop bogus uartclk optimisation
The driver was updating the port uartclk before setting the new rate in
an attempt to avoid having the clock notifier redundantly update the
divisors.

The set_termios() callback is however called under the termios semaphore
and tty-port mutex so the worker scheduled by the clock notifier will
block in serial8250_update_uartclk() until the uartclk and divisors have
been updated anyway.

Drop the unnecessary swaps and incorrect comment and simply update the
uartclk field if the clock-rate change was successful.

Tested-by: Serge Semin <fancer.lancer@gmail.com>
Reviewed-by: Serge Semin <fancer.lancer@gmail.com>
Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Johan Hovold <johan@kernel.org>
Link: https://lore.kernel.org/r/20211015111422.1027-4-johan@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-10-21 10:38:49 +02:00
..
hvc tty: hvc: pass DMA capable memory to put_chars() 2021-10-21 10:34:33 +02:00
ipwireless tty: drop put_tty_driver 2021-07-27 12:17:21 +02:00
serdev TTY / Serial patches for 5.15-rc1 2021-09-01 09:51:16 -07:00
serial serial: 8250_dw: drop bogus uartclk optimisation 2021-10-21 10:38:49 +02:00
vt TTY / Serial patches for 5.15-rc1 2021-09-01 09:51:16 -07:00
amiserial.c tty: drop put_tty_driver 2021-07-27 12:17:21 +02:00
ehv_bytechan.c tty: drop put_tty_driver 2021-07-27 12:17:21 +02:00
goldfish.c tty: drop put_tty_driver 2021-07-27 12:17:21 +02:00
Kconfig This pull request contains the following changes for UML: 2021-07-09 10:19:13 -07:00
Makefile
mips_ejtag_fdc.c tty: drop put_tty_driver 2021-07-27 12:17:21 +02:00
moxa.c tty: moxa: merge moxa.h into moxa.c 2021-09-14 11:17:27 +02:00
mxser.c mxser: store FCR state in mxser_port::FCR 2021-10-05 14:08:09 +02:00
n_gsm.c tty: n_gsm: Don't ignore write return value in gsmld_output() 2021-10-05 14:05:59 +02:00
n_hdlc.c tty: remove file from n_tty_ioctl_helper 2021-09-22 16:59:13 +02:00
n_null.c
n_tty.c tty: remove file from n_tty_ioctl_helper 2021-09-22 16:59:13 +02:00
nozomi.c tty: drop put_tty_driver 2021-07-27 12:17:21 +02:00
pty.c tty: pty: correct function name pty_resize() 2021-05-20 16:33:06 +02:00
synclink_gt.c tty: synclink_gt: rename a conflicting function name 2021-09-14 10:51:37 +02:00
sysrq.c tty/sysrq: More intuitive Shift handling 2021-10-10 15:19:43 +02:00
tty.h
tty_audit.c
tty_baudrate.c tty: baudrate: Explicit usage of B0 for encoding input baudrate 2021-10-05 15:00:56 +02:00
tty_buffer.c tty: tty_buffer: Fix the softlockup issue in flush_to_ldisc 2021-10-18 16:53:18 +02:00
tty_io.c tty: Fix data race between tiocsti() and flush_to_ldisc() 2021-08-26 14:51:38 +02:00
tty_ioctl.c tty: remove file from n_tty_ioctl_helper 2021-09-22 16:59:13 +02:00
tty_jobctrl.c tty: tty_jobctrl: Fix 2 incorrectly documented functions 2021-05-20 17:06:15 +02:00
tty_ldisc.c tty: unexport tty_ldisc_release 2021-09-22 16:59:13 +02:00
tty_ldsem.c
tty_mutex.c
tty_port.c tty: tty_port: Fix coding style issues of block comments 2021-05-13 18:29:13 +02:00
ttynull.c tty: drop put_tty_driver 2021-07-27 12:17:21 +02:00
vcc.c tty: drop put_tty_driver 2021-07-27 12:17:21 +02:00