Commit 009af5fd authored by Guenter Roeck's avatar Guenter Roeck Committed by Dmitry Torokhov

Input: at32psif - drop unnecessary error messages and other changes

Error messages after memory allocation failures are unnecessary and
can be dropped, given that they are emitted as dev_dbg() so nobody except
person actively debugging the driver would see them.

Also replace jump to return 'goto l; ... l: return e;' with 'return e;'
Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
parent 2057e159
...@@ -159,13 +159,12 @@ static int psif_open(struct serio *io) ...@@ -159,13 +159,12 @@ static int psif_open(struct serio *io)
retval = clk_enable(psif->pclk); retval = clk_enable(psif->pclk);
if (retval) if (retval)
goto out; return retval;
psif_writel(psif, CR, PSIF_BIT(CR_TXEN) | PSIF_BIT(CR_RXEN)); psif_writel(psif, CR, PSIF_BIT(CR_TXEN) | PSIF_BIT(CR_RXEN));
psif_writel(psif, IER, PSIF_BIT(RXRDY)); psif_writel(psif, IER, PSIF_BIT(RXRDY));
psif->open = true; psif->open = true;
out:
return retval; return retval;
} }
...@@ -210,16 +209,12 @@ static int __init psif_probe(struct platform_device *pdev) ...@@ -210,16 +209,12 @@ static int __init psif_probe(struct platform_device *pdev)
int ret; int ret;
psif = kzalloc(sizeof(struct psif), GFP_KERNEL); psif = kzalloc(sizeof(struct psif), GFP_KERNEL);
if (!psif) { if (!psif)
dev_dbg(&pdev->dev, "out of memory\n"); return -ENOMEM;
ret = -ENOMEM;
goto out;
}
psif->pdev = pdev; psif->pdev = pdev;
io = kzalloc(sizeof(struct serio), GFP_KERNEL); io = kzalloc(sizeof(struct serio), GFP_KERNEL);
if (!io) { if (!io) {
dev_dbg(&pdev->dev, "out of memory\n");
ret = -ENOMEM; ret = -ENOMEM;
goto out_free_psif; goto out_free_psif;
} }
...@@ -297,7 +292,6 @@ static int __init psif_probe(struct platform_device *pdev) ...@@ -297,7 +292,6 @@ static int __init psif_probe(struct platform_device *pdev)
kfree(io); kfree(io);
out_free_psif: out_free_psif:
kfree(psif); kfree(psif);
out:
return ret; return ret;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment