acrn-kernel/drivers/pinctrl/sunplus
Wells Lu 73f8ce7f96 pinctrl:sunplus: Add check for kmalloc
Fix Smatch static checker warning:
potential null dereference 'configs'. (kmalloc returns null)

Changes in v2:
1. Add free allocated memory before returned -ENOMEM.
2. Add call of_node_put() before returned -ENOMEM.

Fixes: aa74c44be1 ("pinctrl: Add driver for Sunplus SP7021")
Signed-off-by: Wells Lu <wellslutw@gmail.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/1685277277-12209-1-git-send-email-wellslutw@gmail.com
[Rebased on the patch from Lu Hongfei]
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2023-06-09 09:31:18 +02:00
..
Kconfig
Makefile
sppctl.c pinctrl:sunplus: Add check for kmalloc 2023-06-09 09:31:18 +02:00
sppctl.h
sppctl_sp7021.c