bcm27xx: update 6.1 patches from RPi foundation
[openwrt/staging/xback.git] / target / linux / bcm27xx / patches-6.1 / 950-1274-serial-sc16is7xx-Don-t-spin-if-no-data-received.patch
1 From 58c600f728f2787e905eff2f678fa9cf09694004 Mon Sep 17 00:00:00 2001
2 From: Phil Elwell <phil@raspberrypi.com>
3 Date: Fri, 2 Feb 2024 15:41:29 +0000
4 Subject: [PATCH 1274/1295] serial: sc16is7xx: Don't spin if no data received
5
6 There are multiple causes of interrupts, errors being one, and only the
7 receipt of data warrants continued polling.
8
9 See: https://github.com/raspberrypi/linux/issues/2676
10
11 Signed-off-by: Phil Elwell <phil@raspberrypi.com>
12 ---
13 drivers/tty/serial/sc16is7xx.c | 2 ++
14 1 file changed, 2 insertions(+)
15
16 --- a/drivers/tty/serial/sc16is7xx.c
17 +++ b/drivers/tty/serial/sc16is7xx.c
18 @@ -762,6 +762,8 @@ static bool sc16is7xx_port_irq(struct sc
19
20 if (rxlen)
21 sc16is7xx_handle_rx(port, rxlen, iir);
22 + else
23 + rc = false;
24 break;
25 /* CTSRTS interrupt comes only when CTS goes inactive */
26 case SC16IS7XX_IIR_CTSRTS_SRC: