tty: serial: mpc52xx_uart: move static declarations up.
PATCH 1/1 tty: serial: mpc52xx_uart: move static declarations up.
Avoid a compilation error so that they're not used before being declared.
Fixes 4d105880666a ("tty: serial: mpc52xx_uart: add bounds check for psc_num array index")
Reported-by kernel test robot <[email protected]>
Signed-off-by Rosen Penev <[email protected]>
--- drivers/tty/serial/mpc52xx_uart.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/tty/serial/mpc52xx_uart.c +3 -3
@@ -634,6 +634,9 @@ static void __exit mpc512x_psc_fifoc_uninit(void) } } +static struct clk *psc_mclk_clk[MPC52xx_PSC_MAXNUM]; +static struct clk *psc_ipg_clk[MPC52xx_PSC_MAXNUM]; +/* 512x specific interrupt handler. The caller holds the port lock */ static irqreturn_t mpc512x_psc_handle_irq (struct uart_port *port) {
@@ -654,9 +657,6 @@ static irqreturn_t mpc512x_psc_handle_irq(struct uart_port *port)return IRQ_NONE ; } -static struct clk *psc_mclk_clk[MPC52xx_PSC_MAXNUM]; -static struct clk *psc_ipg_clk[MPC52xx_PSC_MAXNUM]; -/* called from within the .request_port() callback (allocation) */ static int mpc512x_psc_alloc_clock (struct uart_port *port) {
Signature · 1 line
2.55.0
[email protected]
AI reviewSashiko has reviewed this patch and found no issues. It looks great!
Quoted 7 lines
Avoid a compilation error so that they're not used before being declared.
Fixes 4d105880666a ("tty: serial: mpc52xx_uart: add bounds check for psc_num array index")Reported-by kernel test robot <[email protected]>Signed-off-by Rosen Penev <[email protected]>
Sashiko has reviewed this patch and found no issues. It looks great!
Signature · 1 line
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=1