pinctrl: sunplus: Add check for kmalloc
authorWells Lu <wellslutw@gmail.com>
Sun, 28 May 2023 12:34:37 +0000 (20:34 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 19 Jul 2023 14:21:35 +0000 (16:21 +0200)
commit019d4fd93a5ad51648c3cd1fcff41d214224b39a
tree122b173875b7329dab0d76650568d21209997945
parentbc796f65cdc870113418a37daf1f91cd303722e3
pinctrl: sunplus: Add check for kmalloc

[ Upstream commit a5961bed5429cf1134d7f539b4ed60317012f84d ]

Fix Smatch static checker warning:
potential null dereference 'configs'. (kmalloc returns null)

Fixes: aa74c44be19c ("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
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/pinctrl/sunplus/sppctl.c