serial: 8250: dw: Fix NULL pointer dereference
Subsystems (3)
PATCH 1/1 serial: 8250: dw: Fix NULL pointer dereference
dw8250_platform_data is only used on DT platforms for now.
Fixes 4a218b277fdb ("serial: 8250: dw: Create a generic platform data structure")
Signed-off-by Heikki Krogerus <[email protected]>
---
Hi,
I'm sorry, I have to resend this (to you guys).
I left out the mailing lists.
Br,
--- drivers/tty/serial/8250/8250_dw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/tty/serial/8250/8250_dw.c +1 -1
@@ -433,9 +433,9 @@ static void dw8250_prepare_rx_dma(struct uart_8250_port *p)static void dw8250_quirks (struct uart_port *p,struct dw8250_data *data) {struct device_node *np = p->dev->of_node; -unsigned int quirks = data->pdata->quirks;if (np) { +unsigned int quirks = data->pdata->quirks;int id;/* get index of serial line, if found in DT aliases */
Signature · 1 line
2.35.1
Quoted 1 line · Heikki Krogerus
dw8250_platform_datais only used on DT platforms for now.
Ah, good catch, Heikki!
Reviewed-by Andy Shevchenko <[email protected]>
Thanks
Quoted 31 lines
Fixes 4a218b277fdb ("serial: 8250: dw: Create a generic platform data structure")Signed-off-by Heikki Krogerus <[email protected]>---
Hi,I'm sorry, I have to resend this (to you guys).
I left out the mailing lists.Br,
--- drivers/tty/serial/8250/8250_dw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/tty/serial/8250/8250_dw.c +1
-1@@ -433,9 +433,9 @@ static void dw8250_prepare_rx_dma(struct uart_8250_port *p)static void dw8250_quirks (struct uart_port *p,struct dw8250_data *data) {struct device_node *np = p->dev->of_node; -unsigned int quirks = data->pdata->quirks;if (np) { +unsigned int quirks = data->pdata->quirks;int id;/* get index of serial line, if found in DT aliases */ Signature · 1 line
2.35.1
Signature · 2 lines
With Best Regards, Andy Shevchenko