summaryrefslogtreecommitdiffstats
path: root/drivers/leds/leds-da903x.c
diff options
context:
space:
mode:
authorXiubo Li <Li.Xiubo@freescale.com>2014-05-07 20:25:52 -0700
committerBryan Wu <cooloney@gmail.com>2014-05-08 14:28:08 +0800
commit0c9a03b68511daf078256367e7a98d7ff3b7dfcb (patch)
tree0edd16dbb3a39f6ff8726a76bfb1dfa3d324d536 /drivers/leds/leds-da903x.c
parent24c9301ffd21356bcd865a5155a501e5059c4c6f (diff)
downloadlinux-0c9a03b68511daf078256367e7a98d7ff3b7dfcb.tar.gz
linux-0c9a03b68511daf078256367e7a98d7ff3b7dfcb.tar.bz2
linux-0c9a03b68511daf078256367e7a98d7ff3b7dfcb.zip
leds: Remove duplicated OOM message for individual driver
The OOM message of individual driver is unnecessary, and this is duplicate the memory subsystem generic OOM message. Signed-off-by: Xiubo Li <Li.Xiubo@freescale.com> Signed-off-by: Bryan Wu <cooloney@gmail.com>
Diffstat (limited to 'drivers/leds/leds-da903x.c')
-rw-r--r--drivers/leds/leds-da903x.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/leds/leds-da903x.c b/drivers/leds/leds-da903x.c
index 35dffb100388..54b8b5216b8b 100644
--- a/drivers/leds/leds-da903x.c
+++ b/drivers/leds/leds-da903x.c
@@ -108,10 +108,8 @@ static int da903x_led_probe(struct platform_device *pdev)
}
led = devm_kzalloc(&pdev->dev, sizeof(struct da903x_led), GFP_KERNEL);
- if (led == NULL) {
- dev_err(&pdev->dev, "failed to alloc memory for LED%d\n", id);
+ if (!led)
return -ENOMEM;
- }
led->cdev.name = pdata->name;
led->cdev.default_trigger = pdata->default_trigger;