[<prev] [next>] [day] [month] [year] [list]
Message-ID: <4890202a-cb60-bcba-781d-4823f3e58b0a@users.sourceforge.net>
Date: Wed, 10 Jan 2018 15:45:41 +0100
From: SF Markus Elfring <elfring@...rs.sourceforge.net>
To: kernel-janitors@...r.kernel.org, Arnd Bergmann <arnd@...db.de>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: LKML <linux-kernel@...r.kernel.org>
Subject: [PATCH] spear13xx_pcie_gadget: Delete an error message for a failed
memory allocation in spear_pcie_gadget_probe()
From: Markus Elfring <elfring@...rs.sourceforge.net>
Date: Wed, 10 Jan 2018 15:35:14 +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 <elfring@...rs.sourceforge.net>
---
drivers/misc/spear13xx_pcie_gadget.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/misc/spear13xx_pcie_gadget.c b/drivers/misc/spear13xx_pcie_gadget.c
index ee120dcbb3e6..75d5ecb2961b 100644
--- a/drivers/misc/spear13xx_pcie_gadget.c
+++ b/drivers/misc/spear13xx_pcie_gadget.c
@@ -671,10 +671,8 @@ static int spear_pcie_gadget_probe(struct platform_device *pdev)
struct configfs_subsystem *subsys;
target = devm_kzalloc(&pdev->dev, sizeof(*target), GFP_KERNEL);
- if (!target) {
- dev_err(&pdev->dev, "out of memory\n");
+ if (!target)
return -ENOMEM;
- }
cg_item = &target->subsys.su_group.cg_item;
sprintf(cg_item->ci_namebuf, "pcie_gadget.%d", pdev->id);
--
2.15.1
Powered by blists - more mailing lists