]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
6.13-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 9 Apr 2025 08:05:56 +0000 (10:05 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 9 Apr 2025 08:05:56 +0000 (10:05 +0200)
added patches:
tty-serial-fsl_lpuart-fix-unused-variable-sport-build-warning.patch
tty-serial-fsl_lpuart-use-port-struct-directly-to-simply-code.patch

queue-6.13/series
queue-6.13/tty-serial-fsl_lpuart-fix-unused-variable-sport-build-warning.patch [new file with mode: 0644]
queue-6.13/tty-serial-fsl_lpuart-use-port-struct-directly-to-simply-code.patch [moved from queue-6.13/tty-serial-fsl_lpuart-use-port-struct-directly-to-si.patch with 85% similarity]

index 094f8f6b2b52cf3696b5a539bb244bec20f8b54e..9e78c79292ff01f5e66a25ba5bf91e79af63c1a6 100644 (file)
@@ -427,7 +427,8 @@ staging-gpib-agilent-usb-code-cleanup.patch
 staging-gpib-agilent-usb-console-messaging-cleanup.patch
 staging-gpib-fix-oops-after-disconnect-in-agilent-us.patch
 tty-serial-fsl_lpuart-use-u32-and-u8-for-register-va.patch
-tty-serial-fsl_lpuart-use-port-struct-directly-to-si.patch
+tty-serial-fsl_lpuart-use-port-struct-directly-to-simply-code.patch
+tty-serial-fsl_lpuart-fix-unused-variable-sport-build-warning.patch
 tty-serial-lpuart-only-disable-cts-instead-of-overwr.patch
 wifi-mac80211-fix-sparse-warning-for-monitor_sdata.patch
 usbnet-fix-npe-during-rx_complete.patch
diff --git a/queue-6.13/tty-serial-fsl_lpuart-fix-unused-variable-sport-build-warning.patch b/queue-6.13/tty-serial-fsl_lpuart-fix-unused-variable-sport-build-warning.patch
new file mode 100644 (file)
index 0000000..263b369
--- /dev/null
@@ -0,0 +1,40 @@
+From 9f8fe348ac9544f6855f82565e754bf085d81f88 Mon Sep 17 00:00:00 2001
+From: Sherry Sun <sherry.sun@nxp.com>
+Date: Mon, 24 Mar 2025 10:10:51 +0800
+Subject: tty: serial: fsl_lpuart: Fix unused variable 'sport' build warning
+
+From: Sherry Sun <sherry.sun@nxp.com>
+
+commit 9f8fe348ac9544f6855f82565e754bf085d81f88 upstream.
+
+Remove the unused variable 'sport' to avoid the kernel build warning.
+
+Fixes: 3cc16ae096f1 ("tty: serial: fsl_lpuart: use port struct directly to simply code")
+Reported-by: kernel test robot <lkp@intel.com>
+Closes: https://lore.kernel.org/oe-kbuild-all/202503210614.2qGlnbIq-lkp@intel.com/
+Signed-off-by: Sherry Sun <sherry.sun@nxp.com>
+Link: https://lore.kernel.org/r/20250324021051.162676-1-sherry.sun@nxp.com
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/tty/serial/fsl_lpuart.c |    3 ---
+ 1 file changed, 3 deletions(-)
+
+--- a/drivers/tty/serial/fsl_lpuart.c
++++ b/drivers/tty/serial/fsl_lpuart.c
+@@ -639,8 +639,6 @@ static void lpuart32_wait_bit_set(struct
+ static int lpuart_poll_init(struct uart_port *port)
+ {
+-      struct lpuart_port *sport = container_of(port,
+-                                      struct lpuart_port, port);
+       unsigned long flags;
+       u8 temp;
+@@ -693,7 +691,6 @@ static int lpuart_poll_get_char(struct u
+ static int lpuart32_poll_init(struct uart_port *port)
+ {
+       unsigned long flags;
+-      struct lpuart_port *sport = container_of(port, struct lpuart_port, port);
+       u32 temp;
+       port->fifosize = 0;
similarity index 85%
rename from queue-6.13/tty-serial-fsl_lpuart-use-port-struct-directly-to-si.patch
rename to queue-6.13/tty-serial-fsl_lpuart-use-port-struct-directly-to-simply-code.patch
index 3ef732cf907e67125345e3b36addaf431418db27..9af40262da435ebdf025fe3b3052f34d79e9018c 100644 (file)
@@ -1,11 +1,11 @@
-From 9223be8453b362b46aff91a9d0f140f9c8b4e3d5 Mon Sep 17 00:00:00 2001
-From: Sasha Levin <sashal@kernel.org>
+From 3cc16ae096f164ae0c6b98416c25a01db5f3a529 Mon Sep 17 00:00:00 2001
+From: Sherry Sun <sherry.sun@nxp.com>
 Date: Wed, 12 Mar 2025 10:39:03 +0800
 Subject: tty: serial: fsl_lpuart: use port struct directly to simply code
 
 From: Sherry Sun <sherry.sun@nxp.com>
 
-[ Upstream commit 3cc16ae096f164ae0c6b98416c25a01db5f3a529 ]
+commit 3cc16ae096f164ae0c6b98416c25a01db5f3a529 upstream.
 
 Most lpuart functions have the parameter struct uart_port *port, but
 still use the &sport->port to get the uart_port instead of use it
@@ -15,17 +15,13 @@ of covert it from struct sport.
 Signed-off-by: Sherry Sun <sherry.sun@nxp.com>
 Link: https://lore.kernel.org/r/20250312023904.1343351-3-sherry.sun@nxp.com
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-Stable-dep-of: e98ab45ec518 ("tty: serial: lpuart: only disable CTS instead of overwriting the whole UARTMODIR register")
-Signed-off-by: Sasha Levin <sashal@kernel.org>
 ---
- drivers/tty/serial/fsl_lpuart.c | 213 +++++++++++++++-----------------
- 1 file changed, 102 insertions(+), 111 deletions(-)
+ drivers/tty/serial/fsl_lpuart.c |  210 +++++++++++++++++++---------------------
+ 1 file changed, 102 insertions(+), 108 deletions(-)
 
-diff --git a/drivers/tty/serial/fsl_lpuart.c b/drivers/tty/serial/fsl_lpuart.c
-index 1afcfc40079d5..2971de64f6a3d 100644
 --- a/drivers/tty/serial/fsl_lpuart.c
 +++ b/drivers/tty/serial/fsl_lpuart.c
-@@ -581,7 +581,7 @@ static int lpuart_dma_tx_request(struct uart_port *port)
+@@ -581,7 +581,7 @@ static int lpuart_dma_tx_request(struct
        ret = dmaengine_slave_config(sport->dma_tx_chan, &dma_tx_sconfig);
  
        if (ret) {
@@ -34,7 +30,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
                                "DMA slave config failed, err = %d\n", ret);
                return ret;
        }
-@@ -611,13 +611,13 @@ static void lpuart_flush_buffer(struct uart_port *port)
+@@ -611,13 +611,13 @@ static void lpuart_flush_buffer(struct u
        }
  
        if (lpuart_is_32(sport)) {
@@ -52,12 +48,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
        }
  }
  
-@@ -639,38 +639,36 @@ static void lpuart32_wait_bit_set(struct uart_port *port, unsigned int offset,
- static int lpuart_poll_init(struct uart_port *port)
- {
--      struct lpuart_port *sport = container_of(port,
--                                      struct lpuart_port, port);
+@@ -644,33 +644,33 @@ static int lpuart_poll_init(struct uart_
        unsigned long flags;
        u8 temp;
  
@@ -104,11 +95,8 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
        return 0;
  }
-@@ -693,33 +691,32 @@ static int lpuart_poll_get_char(struct uart_port *port)
- static int lpuart32_poll_init(struct uart_port *port)
- {
-       unsigned long flags;
--      struct lpuart_port *sport = container_of(port, struct lpuart_port, port);
+@@ -696,30 +696,30 @@ static int lpuart32_poll_init(struct uar
+       struct lpuart_port *sport = container_of(port, struct lpuart_port, port);
        u32 temp;
  
 -      sport->port.fifosize = 0;
@@ -149,7 +137,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
        return 0;
  }
-@@ -1449,12 +1446,9 @@ static void lpuart_dma_rx_free(struct uart_port *port)
+@@ -1449,12 +1449,9 @@ static void lpuart_dma_rx_free(struct ua
  static int lpuart_config_rs485(struct uart_port *port, struct ktermios *termios,
                        struct serial_rs485 *rs485)
  {
@@ -164,7 +152,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
        if (rs485->flags & SER_RS485_ENABLED) {
                /* Enable auto RS-485 RTS mode */
-@@ -1472,32 +1466,29 @@ static int lpuart_config_rs485(struct uart_port *port, struct ktermios *termios,
+@@ -1472,32 +1469,29 @@ static int lpuart_config_rs485(struct ua
                        modem &= ~UARTMODEM_TXRTSPOL;
        }
  
@@ -204,7 +192,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
        if (rs485->flags & SER_RS485_ENABLED) {
                /* Enable auto RS-485 RTS mode */
-@@ -1515,10 +1506,10 @@ static int lpuart32_config_rs485(struct uart_port *port, struct ktermios *termio
+@@ -1515,10 +1509,10 @@ static int lpuart32_config_rs485(struct
                        modem &= ~UARTMODIR_TXRTSPOL;
        }
  
@@ -217,7 +205,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
        return 0;
  }
-@@ -1829,11 +1820,11 @@ static int lpuart_startup(struct uart_port *port)
+@@ -1829,11 +1823,11 @@ static int lpuart_startup(struct uart_po
        u8 temp;
  
        /* determine FIFO size and enable FIFO mode */
@@ -231,7 +219,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
        sport->rxfifo_size = UARTFIFO_DEPTH((temp >> UARTPFIFO_RXSIZE_OFF) &
                                            UARTPFIFO_FIFOSIZE_MASK);
-@@ -1889,11 +1880,11 @@ static int lpuart32_startup(struct uart_port *port)
+@@ -1889,11 +1883,11 @@ static int lpuart32_startup(struct uart_
        u32 temp;
  
        /* determine FIFO size */
@@ -245,7 +233,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
        sport->rxfifo_size = UARTFIFO_DEPTH((temp >> UARTFIFO_RXSIZE_OFF) &
                                            UARTFIFO_FIFOSIZE_MASK);
-@@ -1906,7 +1897,7 @@ static int lpuart32_startup(struct uart_port *port)
+@@ -1906,7 +1900,7 @@ static int lpuart32_startup(struct uart_
        if (is_layerscape_lpuart(sport)) {
                sport->rxfifo_size = 16;
                sport->txfifo_size = 16;
@@ -254,7 +242,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
        }
  
        lpuart_request_dma(sport);
-@@ -1966,8 +1957,8 @@ static void lpuart32_shutdown(struct uart_port *port)
+@@ -1966,8 +1960,8 @@ static void lpuart32_shutdown(struct uar
        uart_port_lock_irqsave(port, &flags);
  
        /* clear status */
@@ -265,7 +253,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
        /* disable Rx/Tx DMA */
        temp = lpuart32_read(port, UARTBAUD);
-@@ -1996,12 +1987,12 @@ lpuart_set_termios(struct uart_port *port, struct ktermios *termios,
+@@ -1996,12 +1990,12 @@ lpuart_set_termios(struct uart_port *por
        unsigned int old_csize = old ? old->c_cflag & CSIZE : CS8;
        unsigned int sbr, brfa;
  
@@ -284,7 +272,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
        /*
         * only support CS8 and CS7, and for CS7 must enable PE.
         * supported mode:
-@@ -2033,7 +2024,7 @@ lpuart_set_termios(struct uart_port *port, struct ktermios *termios,
+@@ -2033,7 +2027,7 @@ lpuart_set_termios(struct uart_port *por
         * When auto RS-485 RTS mode is enabled,
         * hardware flow control need to be disabled.
         */
@@ -293,7 +281,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
                termios->c_cflag &= ~CRTSCTS;
  
        if (termios->c_cflag & CRTSCTS)
-@@ -2074,59 +2065,59 @@ lpuart_set_termios(struct uart_port *port, struct ktermios *termios,
+@@ -2074,59 +2068,59 @@ lpuart_set_termios(struct uart_port *por
         * Need to update the Ring buffer length according to the selected
         * baud rate and restart Rx DMA path.
         *
@@ -374,7 +362,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
        if (old && sport->lpuart_dma_rx_use) {
                if (!lpuart_start_rx_dma(sport))
-@@ -2135,7 +2126,7 @@ lpuart_set_termios(struct uart_port *port, struct ktermios *termios,
+@@ -2135,7 +2129,7 @@ lpuart_set_termios(struct uart_port *por
                        sport->lpuart_dma_rx_use = false;
        }
  
@@ -383,7 +371,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  }
  
  static void __lpuart32_serial_setbrg(struct uart_port *port,
-@@ -2233,9 +2224,9 @@ lpuart32_set_termios(struct uart_port *port, struct ktermios *termios,
+@@ -2233,9 +2227,9 @@ lpuart32_set_termios(struct uart_port *p
        unsigned int  baud;
        unsigned int old_csize = old ? old->c_cflag & CSIZE : CS8;
  
@@ -396,7 +384,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
        sport->is_cs7 = false;
        /*
         * only support CS8 and CS7
-@@ -2269,7 +2260,7 @@ lpuart32_set_termios(struct uart_port *port, struct ktermios *termios,
+@@ -2269,7 +2263,7 @@ lpuart32_set_termios(struct uart_port *p
         * When auto RS-485 RTS mode is enabled,
         * hardware flow control need to be disabled.
         */
@@ -405,7 +393,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
                termios->c_cflag &= ~CRTSCTS;
  
        if (termios->c_cflag & CRTSCTS)
-@@ -2319,32 +2310,32 @@ lpuart32_set_termios(struct uart_port *port, struct ktermios *termios,
+@@ -2319,32 +2313,32 @@ lpuart32_set_termios(struct uart_port *p
         * Need to update the Ring buffer length according to the selected
         * baud rate and restart Rx DMA path.
         *
@@ -448,7 +436,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
        }
  
        /* update the per-port timeout */
-@@ -2356,22 +2347,22 @@ lpuart32_set_termios(struct uart_port *port, struct ktermios *termios,
+@@ -2356,22 +2350,22 @@ lpuart32_set_termios(struct uart_port *p
         * asserted.
         */
        if (!(old_ctrl & UARTCTRL_SBK)) {
@@ -478,7 +466,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
        if ((ctrl & (UARTCTRL_PE | UARTCTRL_M)) == UARTCTRL_PE)
                sport->is_cs7 = true;
-@@ -2383,7 +2374,7 @@ lpuart32_set_termios(struct uart_port *port, struct ktermios *termios,
+@@ -2383,7 +2377,7 @@ lpuart32_set_termios(struct uart_port *p
                        sport->lpuart_dma_rx_use = false;
        }
  
@@ -487,7 +475,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  }
  
  static const char *lpuart_type(struct uart_port *port)
-@@ -2821,7 +2812,7 @@ static int lpuart_global_reset(struct lpuart_port *sport)
+@@ -2821,7 +2815,7 @@ static int lpuart_global_reset(struct lp
  
        ret = clk_prepare_enable(sport->ipg_clk);
        if (ret) {
@@ -496,7 +484,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
                return ret;
        }
  
-@@ -2832,10 +2823,10 @@ static int lpuart_global_reset(struct lpuart_port *sport)
+@@ -2832,10 +2826,10 @@ static int lpuart_global_reset(struct lp
                 */
                ctrl = lpuart32_read(port, UARTCTRL);
                if (ctrl & UARTCTRL_TE) {
@@ -509,7 +497,7 @@ index 1afcfc40079d5..2971de64f6a3d 100644
                                         "timeout waiting for transmit engine to complete\n");
                                clk_disable_unprepare(sport->ipg_clk);
                                return 0;
-@@ -3187,7 +3178,7 @@ static void lpuart_console_fixup(struct lpuart_port *sport)
+@@ -3187,7 +3181,7 @@ static void lpuart_console_fixup(struct
         * in VLLS mode, or restore console setting here.
         */
        if (is_imx7ulp_lpuart(sport) && lpuart_uport_is_active(sport) &&
@@ -518,6 +506,3 @@ index 1afcfc40079d5..2971de64f6a3d 100644
  
                mutex_lock(&port->mutex);
                memset(&termios, 0, sizeof(struct ktermios));
--- 
-2.39.5
-