Skip to contentSkip to conversation

char: hw_random: delete redundant printing of return value

PATCH In review Wang Qing 2 participants 2 messages Mar 13, 2021 – Mar 19, 2021

Subsystems (3)
lore
Share & tools
lore

Wang Qing

author
#0 lore raw

PATCH 1/1 char: hw_random: delete redundant printing of return value

platform_get_irq() has already checked and printed the return value, the printing here is nothing special, it is not necessary at all.

---
 drivers/char/hw_random/cctrng.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/char/hw_random/cctrng.c +1 -3
index 7a293f2..1e551e3
@@ -527,10 +527,8 @@ static int cctrng_probe(struct platform_device *pdev)
 
 	/* Then IRQ */
 	irq = platform_get_irq(pdev, 0);
-	if (irq < 0) {
-		dev_err(dev, "Failed getting IRQ resource\n");
+	if (irq < 0)
 		return irq;
-	}
 
 	/* parse sampling rate from device tree */
 	rc = cc_trng_parse_sampling_ratio(drvdata);
Signature · 1 line
2.7.4
maintainer
#1 lore raw
Quoted 7 lines · Wang Qing

platform_get_irq() has already checked and printed the return value, the printing here is nothing special, it is not necessary at all.

---
 drivers/char/hw_random/cctrng.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Patch applied. Thanks.

Signature · 3 lines
Email: Herbert Xu <[email protected]>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt