DORMANTno replies

[PATCH] ISDN, hfcpci Fix uninitialized warning

From: Prarit Bhargava <hidden>
Date: 2013-09-13 12:28:25
Subsystem: the rest · Maintainer: Linus Torvalds

Fix uninitialized warning.  Use same fix as
drivers/media/pci/cx18/cx18-alsa-main.c

  CC [M]  drivers/isdn/hardware/mISDN/hfcpci.o
  drivers/isdn/hardware/mISDN/hfcpci.c: In function ‘hfcpci_softirq’:
  drivers/isdn/hardware/mISDN/hfcpci.c:2298:2: error: ignoring return
  value of ‘driver_for_each_device’, declared with attribute
  warn_unused_result [-Werror=unused-result]
    (void) driver_for_each_device(&hfc_driver.driver, NULL, arg,
		      ^

Signed-off-by: Prarit Bhargava <redacted>
Cc: dzickus@redhat.com
Cc: Karsten Keil <redacted>
---
 drivers/isdn/hardware/mISDN/hfcpci.c |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/isdn/hardware/mISDN/hfcpci.c b/drivers/isdn/hardware/mISDN/hfcpci.c
index 7f910c7..2373b44 100644
--- a/drivers/isdn/hardware/mISDN/hfcpci.c
+++ b/drivers/isdn/hardware/mISDN/hfcpci.c
@@ -2295,8 +2295,12 @@ _hfcpci_softirq(struct device *dev, void *arg)
 static void
 hfcpci_softirq(void *arg)
 {
-	(void) driver_for_each_device(&hfc_driver.driver, NULL, arg,
+	int ret;
+
+	ret = driver_for_each_device(&hfc_driver.driver, NULL, arg,
 				      _hfcpci_softirq);
+	if (unlikely(ret))
+		pr_warn("hfcpci_softirq: driver softirq failed\n");
 
 	/* if next event would be in the past ... */
 	if ((s32)(hfc_jiffies + tics - jiffies) <= 0)
-- 
1.7.9.3
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help