All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] staging: most: dim2: remove redundant dev_err() calls
@ 2026-10-18 10:42 Melih Emik
  2026-10-18 10:45 ` Dan Carpenter
  0 siblings, 1 reply; 4+ messages in thread
From: Melih Emik @ 2026-10-18 10:42 UTC (permalink / raw)
  To: parthiban.veerasooran, christian.gromm, gregkh
  Cc: linux-staging, linux-kernel

Since commit 55b48e23f5c4 ("genirq/devres: Add error handling in
devm_request_*_irq()"), devm_request_threaded_irq() and
devm_request_irq() automatically log detailed failure diagnostics
including device name, IRQ number, handlers, and the error code via
dev_err_probe().

Consequently, driver-specific dev_err() calls immediately following
these requests produce duplicate error messages on failure and are
redundant. Remove the redundant dev_err() calls in dim2_probe().

Tested:
- Compiled with W=1 on x86_64 with zero warnings.
- Verified with lockdep and debug mutexes enabled
  (CONFIG_PROVE_LOCKING=y, CONFIG_DEBUG_MUTEXES=y).
- Boot-tested full bzImage in QEMU with initcall_debug, confirming
  successful driver registration (dim2_driver_init returned 0) and
  zero lockdep/kernel warnings.
- Verified with scripts/checkpatch.pl (0 errors, 0 warnings).

Signed-off-by: Melih Emik <melihemik@noirlang.tr>
---
 drivers/staging/most/dim2/dim2.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/drivers/staging/most/dim2/dim2.c b/drivers/staging/most/dim2/dim2.c
index 0e2512d16632..d57e20d399c7 100644
--- a/drivers/staging/most/dim2/dim2.c
+++ b/drivers/staging/most/dim2/dim2.c
@@ -818,10 +818,8 @@ static int dim2_probe(struct platform_device *pdev)
 
 	ret = devm_request_threaded_irq(&pdev->dev, irq, dim2_ahb_isr,
 					dim2_task_irq, 0, "dim2_ahb0_int", dev);
-	if (ret) {
-		dev_err(&pdev->dev, "failed to request ahb0_int irq %d\n", irq);
+	if (ret)
 		goto err_shutdown_dim;
-	}
 
 	irq = platform_get_irq(pdev, MLB_INT_IDX);
 	if (irq < 0) {
@@ -831,10 +829,8 @@ static int dim2_probe(struct platform_device *pdev)
 
 	ret = devm_request_irq(&pdev->dev, irq, dim2_mlb_isr, 0,
 			       "dim2_mlb_int", dev);
-	if (ret) {
-		dev_err(&pdev->dev, "failed to request mlb_int irq %d\n", irq);
+	if (ret)
 		goto err_shutdown_dim;
-	}
 
 	init_waitqueue_head(&dev->netinfo_waitq);
 	dev->deliver_netinfo = 0;
-- 
2.56.0



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

end of thread, other threads:[~2026-10-18 11:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-18 10:42 [PATCH] staging: most: dim2: remove redundant dev_err() calls Melih Emik
2026-10-18 10:45 ` Dan Carpenter
2026-10-18 11:00   ` Melih Emik
2026-10-18 11:06     ` Dan Carpenter

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.