serial: 8250_em: Remove out-of-memory message
authorPeter Hurley <peter@hurleysoftware.com>
Wed, 5 Nov 2014 17:26:32 +0000 (12:26 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 6 Nov 2014 04:18:30 +0000 (20:18 -0800)
devm_kzalloc() already warns if allocation fails; remove duplicate
message.

Signed-off-by: Peter Hurley <peter@hurleysoftware.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/8250/8250_em.c

index 56c87232b6a0eadac0d02e6eb7a10997b4abd1c5..478599d825061febb88d309f03f2c2bdcfbe9ed1 100644 (file)
@@ -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)) {