aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2022-04-21 12:17:06 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-04-22 16:21:53 +0200
commitd2b574c0b45eb979971343876944f982e9511bf4 (patch)
tree0706162247d3dd8053dc305bf05afa92f6831410
parentserial: zs: use NULL as a pointer, not 0 (diff)
downloadlinux-dev-d2b574c0b45eb979971343876944f982e9511bf4.tar.xz
linux-dev-d2b574c0b45eb979971343876944f982e9511bf4.zip
serial: qcom: use check for empty instead of pending
The code wants to know if the circ buffer is empty, so use the proper macro. No functional change intended, just saner function name used for that use case. Cc: Andy Gross <agross@kernel.org> Cc: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Jiri Slaby <jslaby@suse.cz> Link: https://lore.kernel.org/r/20220421101708.5640-6-jslaby@suse.cz Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/tty/serial/qcom_geni_serial.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/tty/serial/qcom_geni_serial.c b/drivers/tty/serial/qcom_geni_serial.c
index 1543a6028856..f4961022d7d0 100644
--- a/drivers/tty/serial/qcom_geni_serial.c
+++ b/drivers/tty/serial/qcom_geni_serial.c
@@ -507,7 +507,7 @@ static void qcom_geni_serial_console_write(struct console *co, const char *s,
*/
qcom_geni_serial_poll_tx_done(uport);
- if (uart_circ_chars_pending(&uport->state->xmit)) {
+ if (!uart_circ_empty(&uport->state->xmit)) {
irq_en = readl(uport->membase + SE_GENI_M_IRQ_EN);
writel(irq_en | M_TX_FIFO_WATERMARK_EN,
uport->membase + SE_GENI_M_IRQ_EN);