Commit 24303ee7 authored by Markus Elfring's avatar Markus Elfring Committed by Lee Jones

mfd: sm501: Delete error message for a failed memory allocation in two places

Omit an extra message for a memory allocation failure in these functions.

This issue was detected by using the Coccinelle software.
Signed-off-by: default avatarMarkus Elfring <elfring@users.sourceforge.net>
Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
parent d0011174
...@@ -1385,7 +1385,6 @@ static int sm501_plat_probe(struct platform_device *dev) ...@@ -1385,7 +1385,6 @@ static int sm501_plat_probe(struct platform_device *dev)
sm = kzalloc(sizeof(struct sm501_devdata), GFP_KERNEL); sm = kzalloc(sizeof(struct sm501_devdata), GFP_KERNEL);
if (sm == NULL) { if (sm == NULL) {
dev_err(&dev->dev, "no memory for device data\n");
ret = -ENOMEM; ret = -ENOMEM;
goto err1; goto err1;
} }
...@@ -1575,7 +1574,6 @@ static int sm501_pci_probe(struct pci_dev *dev, ...@@ -1575,7 +1574,6 @@ static int sm501_pci_probe(struct pci_dev *dev,
sm = kzalloc(sizeof(struct sm501_devdata), GFP_KERNEL); sm = kzalloc(sizeof(struct sm501_devdata), GFP_KERNEL);
if (sm == NULL) { if (sm == NULL) {
dev_err(&dev->dev, "no memory for device data\n");
err = -ENOMEM; err = -ENOMEM;
goto err1; goto err1;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment