sst-linux/drivers/net/arcnet
Henry Martin be8a0decd0 arcnet: Add NULL check in com20020pci_probe()
[ Upstream commit fda8c491db2a90ff3e6fbbae58e495b4ddddeca3 ]

devm_kasprintf() returns NULL when memory allocation fails. Currently,
com20020pci_probe() does not check for this case, which results in a
NULL pointer dereference.

Add NULL check after devm_kasprintf() to prevent this issue and ensure
no resources are left allocated.

Fixes: 6b17a597fc2f ("arcnet: restoring support for multiple Sohard Arcnet cards")
Signed-off-by: Henry Martin <bsdhenrymartin@gmail.com>
Link: https://patch.msgid.link/20250402135036.44697-1-bsdhenrymartin@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-04-10 14:33:41 +02:00
..
arc-rawmode.c
arc-rimi.c
arcdevice.h
arcnet.c
capmode.c
com90io.c
com90xx.c
com9026.h
com20020_cs.c
com20020-isa.c
com20020-pci.c
com20020.c
com20020.h
Kconfig
Makefile
rfc1051.c
rfc1201.c