diff options
author | Markus Elfring <elfring@users.sourceforge.net> | 2018-03-08 09:15:51 -0500 |
---|---|---|
committer | Lee Jones <lee.jones@linaro.org> | 2018-05-16 04:21:48 -0400 |
commit | a2e87fee55c2024c7d9ad7c26614300effd48d4c (patch) | |
tree | d25fe7c89cfe89ac6ec4b7e52152c5c8a68f865a | |
parent | 8349aeb6a766ad188cfa019385a0539662b04e56 (diff) |
mfd: ti_am335x_tscadc: Delete an error message for a failed memory allocation in ti_tscadc_probe()
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@users.sourceforge.net>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
-rw-r--r-- | drivers/mfd/ti_am335x_tscadc.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/mfd/ti_am335x_tscadc.c b/drivers/mfd/ti_am335x_tscadc.c index 3cd958a31f36..47012c0899cd 100644 --- a/drivers/mfd/ti_am335x_tscadc.c +++ b/drivers/mfd/ti_am335x_tscadc.c | |||
@@ -169,10 +169,9 @@ static int ti_tscadc_probe(struct platform_device *pdev) | |||
169 | 169 | ||
170 | /* Allocate memory for device */ | 170 | /* Allocate memory for device */ |
171 | tscadc = devm_kzalloc(&pdev->dev, sizeof(*tscadc), GFP_KERNEL); | 171 | tscadc = devm_kzalloc(&pdev->dev, sizeof(*tscadc), GFP_KERNEL); |
172 | if (!tscadc) { | 172 | if (!tscadc) |
173 | dev_err(&pdev->dev, "failed to allocate memory.\n"); | ||
174 | return -ENOMEM; | 173 | return -ENOMEM; |
175 | } | 174 | |
176 | tscadc->dev = &pdev->dev; | 175 | tscadc->dev = &pdev->dev; |
177 | 176 | ||
178 | err = platform_get_irq(pdev, 0); | 177 | err = platform_get_irq(pdev, 0); |