From: Markus Elfring Date: Sat, 10 Feb 2018 20:09:08 +0000 (+0100) Subject: gpio: timberdale: Delete an error message X-Git-Tag: v4.17-rc1~121^2~65 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=587ca5ed56679f7697919b90eeb0ea8a87d55368;p=thirdparty%2Fkernel%2Flinux.git gpio: timberdale: Delete an error message 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 Signed-off-by: Linus Walleij --- diff --git a/drivers/gpio/gpio-timberdale.c b/drivers/gpio/gpio-timberdale.c index 181f86ce00cd4..ff155e4372103 100644 --- a/drivers/gpio/gpio-timberdale.c +++ b/drivers/gpio/gpio-timberdale.c @@ -239,10 +239,9 @@ static int timbgpio_probe(struct platform_device *pdev) } tgpio = devm_kzalloc(dev, sizeof(struct timbgpio), GFP_KERNEL); - if (!tgpio) { - dev_err(dev, "Memory alloc failed\n"); + if (!tgpio) return -EINVAL; - } + tgpio->irq_base = pdata->irq_base; spin_lock_init(&tgpio->lock);