openwrt/target/linux/bcm27xx/patches-6.1/950-1274-serial-sc16is7xx-Don-t-spin-if-no-data-received.patch
Álvaro Fernández Rojas 20fe7e687e bcm27xx: update 6.1 patches from RPi foundation
Sync 6.1 patches with the RPi foundation.
Since rpi-6.6.y is now the main branch of the RPi foundation, there won't be
any new patches for linux 6.1.

Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
2024-04-07 22:12:42 +02:00

27 lines
847 B
Diff

From 58c600f728f2787e905eff2f678fa9cf09694004 Mon Sep 17 00:00:00 2001
From: Phil Elwell <phil@raspberrypi.com>
Date: Fri, 2 Feb 2024 15:41:29 +0000
Subject: [PATCH 1274/1295] serial: sc16is7xx: Don't spin if no data received
There are multiple causes of interrupts, errors being one, and only the
receipt of data warrants continued polling.
See: https://github.com/raspberrypi/linux/issues/2676
Signed-off-by: Phil Elwell <phil@raspberrypi.com>
---
drivers/tty/serial/sc16is7xx.c | 2 ++
1 file changed, 2 insertions(+)
--- a/drivers/tty/serial/sc16is7xx.c
+++ b/drivers/tty/serial/sc16is7xx.c
@@ -762,6 +762,8 @@ static bool sc16is7xx_port_irq(struct sc
if (rxlen)
sc16is7xx_handle_rx(port, rxlen, iir);
+ else
+ rc = false;
break;
/* CTSRTS interrupt comes only when CTS goes inactive */
case SC16IS7XX_IIR_CTSRTS_SRC: