linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] i2c: uniphier: Remove superfluous error message in uniphier_i2c_probe()
@ 2020-05-03 12:08 Aishwarya Ramakrishnan
  2020-05-03 13:29 ` Wolfram Sang
  2020-05-04 11:44 ` [PATCH] i2c: drivers: Remove superfluous error message Aishwarya Ramakrishnan
  0 siblings, 2 replies; 8+ messages in thread
From: Aishwarya Ramakrishnan @ 2020-05-03 12:08 UTC (permalink / raw)
  To: Masahiro Yamada, linux-i2c, linux-arm-kernel, linux-kernel; +Cc: aishwaryarj100

The function platform_get_irq can log an error by itself.
This omit a redundant message for exception handling in the
calling function.

Suggested by Coccinelle.

Signed-off-by: Aishwarya Ramakrishnan <aishwaryarj100@gmail.com>
---
 drivers/i2c/busses/i2c-uniphier.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/i2c/busses/i2c-uniphier.c b/drivers/i2c/busses/i2c-uniphier.c
index 668b1fa2b0ef..ee00a44bf4c7 100644
--- a/drivers/i2c/busses/i2c-uniphier.c
+++ b/drivers/i2c/busses/i2c-uniphier.c
@@ -324,10 +324,8 @@ static int uniphier_i2c_probe(struct platform_device *pdev)
 		return PTR_ERR(priv->membase);
 
 	irq = platform_get_irq(pdev, 0);
-	if (irq < 0) {
-		dev_err(dev, "failed to get IRQ number\n");
+	if (irq < 0)
 		return irq;
-	}
 
 	if (of_property_read_u32(dev->of_node, "clock-frequency", &bus_speed))
 		bus_speed = I2C_MAX_STANDARD_MODE_FREQ;
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-05-05 14:13 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-03 12:08 [PATCH] i2c: uniphier: Remove superfluous error message in uniphier_i2c_probe() Aishwarya Ramakrishnan
2020-05-03 13:29 ` Wolfram Sang
2020-05-04  0:15   ` Masahiro Yamada
2020-05-04 11:44 ` [PATCH] i2c: drivers: Remove superfluous error message Aishwarya Ramakrishnan
2020-05-04 12:42   ` Andy Shevchenko
2020-05-04 12:44     ` Andy Shevchenko
2020-05-04 14:30   ` Masahiro Yamada
2020-05-05 14:13   ` Wolfram Sang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).