mirror of
https://github.com/nxp-imx/linux-imx.git
synced 2025-07-18 23:29:57 +02:00
pinctrl: single: fix missing error code in pcs_probe()
[ Upstream commitcacd8cf79d
] If pinctrl_enable() fails in pcs_probe(), it should return the error code. Fixes:8f773bfbdd
("pinctrl: single: fix possible memory leak when pinctrl_enable() fails") Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Link: https://lore.kernel.org/20240819024625.154441-1-yangyingliang@huaweicloud.com Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
8b7df76356
commit
b6edb3fd96
|
@ -1918,7 +1918,8 @@ static int pcs_probe(struct platform_device *pdev)
|
|||
|
||||
dev_info(pcs->dev, "%i pins, size %u\n", pcs->desc.npins, pcs->size);
|
||||
|
||||
if (pinctrl_enable(pcs->pctl))
|
||||
ret = pinctrl_enable(pcs->pctl);
|
||||
if (ret)
|
||||
goto free;
|
||||
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue
Block a user