serial: 8250: Return early in .start_tx() if there are no chars to send
authorSteffen Trumtrar <s.trumtrar@pengutronix.de>
Thu, 17 Feb 2022 21:18:39 +0000 (22:18 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 25 Feb 2022 09:21:44 +0000 (10:21 +0100)
commit932d596378b0253354246f4aa3662add4883a167
treea7f1492705cf8de109f45e41df66e496dd3e6d6b
parent52fa786609dc142050b590148b7b9cd63bcdc413
serial: 8250: Return early in .start_tx() if there are no chars to send

Don't start the whole chain for TX if there is no data to send. This is
mostly relevant for rs485 mode as there might be rts-before-send and
rts-after-send delays involved.

Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Link: https://lore.kernel.org/r/20220217211839.443039-1-u.kleine-koenig@pengutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/8250/8250_port.c