linux-serial.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] serial: 8250: 8250_omap: Fix possible array out of bounds access
@ 2020-11-11 11:26 Vignesh Raghavendra
  2020-11-11 11:26 ` [PATCH 2/2] serial: 8250: 8250_omap: Fix unused variable warning Vignesh Raghavendra
  0 siblings, 1 reply; 2+ messages in thread
From: Vignesh Raghavendra @ 2020-11-11 11:26 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Jiri Slaby, Vignesh Raghavendra, Naresh Kamboju, linux-serial,
	linux-kernel

k3_soc_devices array is missing a sentinel entry which may result in out
of bounds access as reported by kernel KASAN.

Fix this by adding a sentinel entry.

Fixes: 439c7183e5b9 ("serial: 8250: 8250_omap: Disable RX interrupt after DMA enable")
Reported-by: Naresh Kamboju <naresh.kamboju@linaro.org>
Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
---
 drivers/tty/serial/8250/8250_omap.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/tty/serial/8250/8250_omap.c b/drivers/tty/serial/8250/8250_omap.c
index 084e7bc51f0e..ab18ef035659 100644
--- a/drivers/tty/serial/8250/8250_omap.c
+++ b/drivers/tty/serial/8250/8250_omap.c
@@ -1199,6 +1199,7 @@ static int omap8250_no_handle_irq(struct uart_port *port)
 static const struct soc_device_attribute k3_soc_devices[] = {
 	{ .family = "AM65X",  },
 	{ .family = "J721E", .revision = "SR1.0" },
+	{ /* sentinel */ }
 };
 
 static struct omap8250_dma_params am654_dma = {
-- 
2.29.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-11-11 11:27 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-11 11:26 [PATCH 1/2] serial: 8250: 8250_omap: Fix possible array out of bounds access Vignesh Raghavendra
2020-11-11 11:26 ` [PATCH 2/2] serial: 8250: 8250_omap: Fix unused variable warning Vignesh Raghavendra

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).