pinctrl: mvebu: Delete an error message for a failed memory allocation in mvebu_pinctrl_probe()
Subsystems (4)
PATCH 1/1 pinctrl: mvebu: Delete an error message for a failed memory allocation in mvebu_pinctrl_probe()
From: Markus Elfring <[email protected]>
Date: Tue, 19 Dec 2017 22:30:36 +0100
Omit an extra message for a memory allocation failure in this function.
This issue was detected by using the Coccinelle software.
Signed-off-by Markus Elfring <[email protected]>
--- drivers/pinctrl/mvebu/pinctrl-mvebu.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/pinctrl/mvebu/pinctrl-mvebu.c +2 -3
@@ -636,10 +636,9 @@ int mvebu_pinctrl_probe(struct platform_device *pdev)*/ size = pctl->num_groups *sizeof (*pctl->groups) + noname *8 ; p =devm_kzalloc (&pdev->dev, size,GFP_KERNEL ); -if (!p) { -dev_err (&pdev->dev,"failed to alloc group data\n" ); +if (!p)return -ENOMEM ; - } + pctl->groups = p; noname_buf = p + pctl->num_groups *sizeof (*pctl->groups);
Signature · 1 line
2.15.1
Quoted 8 lines · SF Markus Elfring
From: Markus Elfring <[email protected]>
Date: Tue, 19 Dec 2017 22:30:36 +0100Omit an extra message for a memory allocation failure in this function.
This issue was detected by using the Coccinelle software.
Signed-off-by Markus Elfring <[email protected]>
Patch applied.
Yours,
Linus Walleij