Message ID | 20200416140529.20036-1-tangbin@cmss.chinamobile.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | i2c:imx-lpi2c: Omit superfluous error message in lpi2c_imx_probe() | expand |
On Thu, Apr 16, 2020 at 10:05:29PM +0800, Tang Bin wrote: > In the function lpi2c_imx_probe(), when get irq failed, the function > platform_get_irq() logs an error message, so remove redundant message > here. > > Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com> Please make only one patch for all the drivers in the i2c subsystem.
diff --git a/drivers/i2c/busses/i2c-imx-lpi2c.c b/drivers/i2c/busses/i2c-imx-lpi2c.c index c92b56485..ee16e7e22 100644 --- a/drivers/i2c/busses/i2c-imx-lpi2c.c +++ b/drivers/i2c/busses/i2c-imx-lpi2c.c @@ -557,10 +557,8 @@ static int lpi2c_imx_probe(struct platform_device *pdev) return PTR_ERR(lpi2c_imx->base); irq = platform_get_irq(pdev, 0); - if (irq < 0) { - dev_err(&pdev->dev, "can't get irq number\n"); + if (irq < 0) return irq; - } lpi2c_imx->adapter.owner = THIS_MODULE; lpi2c_imx->adapter.algo = &lpi2c_imx_algo;
In the function lpi2c_imx_probe(), when get irq failed, the function platform_get_irq() logs an error message, so remove redundant message here. Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com> --- drivers/i2c/busses/i2c-imx-lpi2c.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)