From: Peter Hurley Date: Wed, 5 Nov 2014 17:26:32 +0000 (-0500) Subject: serial: 8250_em: Remove out-of-memory message X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=86b20dfe9821060f880f6fa4881d51cabce78166;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git serial: 8250_em: Remove out-of-memory message devm_kzalloc() already warns if allocation fails; remove duplicate message. Signed-off-by: Peter Hurley Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/tty/serial/8250/8250_em.c b/drivers/tty/serial/8250/8250_em.c index 56c87232b6a0..478599d82506 100644 --- a/drivers/tty/serial/8250/8250_em.c +++ b/drivers/tty/serial/8250/8250_em.c @@ -102,10 +102,8 @@ static int serial8250_em_probe(struct platform_device *pdev) } priv = devm_kzalloc(&pdev->dev, sizeof(*priv), GFP_KERNEL); - if (!priv) { - dev_err(&pdev->dev, "unable to allocate private data\n"); + if (!priv) return -ENOMEM; - } priv->sclk = devm_clk_get(&pdev->dev, "sclk"); if (IS_ERR(priv->sclk)) {