[PATCH] serial: 8250_ni: use kzalloc_obj() for allocation
From: Pete Connor
Date: Mon Feb 16 2026 - 22:29:53 EST
Replace kzalloc() with the preferred kzalloc_obj() helper
to address a checkpatch warning.
Signed-off-by: Pete Connor <pete.connor@xxxxxxxxxxxxxx>
---
drivers/tty/serial/8250/8250_ni.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/tty/serial/8250/8250_ni.c b/drivers/tty/serial/8250/8250_ni.c
index cb5b42b3609c..3f3dac694e20 100644
--- a/drivers/tty/serial/8250/8250_ni.c
+++ b/drivers/tty/serial/8250/8250_ni.c
@@ -285,7 +285,7 @@ static int ni16550_probe(struct platform_device *pdev)
bool rs232_property;
int ret;
- uart = kzalloc(sizeof(*uart), GFP_KERNEL);
+ uart = kzalloc_obj(*uart, GFP_KERNEL);
if (!uart)
return -ENOMEM;
--
2.47.3