From: Guenter Roeck Date: Wed, 18 Jan 2017 19:21:24 +0000 (-0800) Subject: Input: atmel-wm97xx - drop unnecessary error messages X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5d20b927fa17d016e633857c756788516078b94e;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git Input: atmel-wm97xx - drop unnecessary error messages Error messages after memory allocation failures are unnecessary and can be dropped, especially give that they were emitted as dev_dbg() so noone except person actively debugging the driver would see them. Signed-off-by: Guenter Roeck Signed-off-by: Dmitry Torokhov --- diff --git a/drivers/input/touchscreen/atmel-wm97xx.c b/drivers/input/touchscreen/atmel-wm97xx.c index 7ec0421c0dd8..8cf0b2be2df4 100644 --- a/drivers/input/touchscreen/atmel-wm97xx.c +++ b/drivers/input/touchscreen/atmel-wm97xx.c @@ -339,10 +339,8 @@ static int __init atmel_wm97xx_probe(struct platform_device *pdev) int ret; atmel_wm97xx = kzalloc(sizeof(struct atmel_wm97xx), GFP_KERNEL); - if (!atmel_wm97xx) { - dev_dbg(&pdev->dev, "out of memory\n"); + if (!atmel_wm97xx) return -ENOMEM; - } atmel_wm97xx->wm = wm; atmel_wm97xx->regs = (void *)ATMEL_WM97XX_AC97C_IOMEM;