linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] brcmfmac: check result of USB firmware request
@ 2015-05-07 12:13 Rafał Miłecki
  2015-05-08  9:30 ` Arend van Spriel
  2015-05-09 13:59 ` Kalle Valo
  0 siblings, 2 replies; 4+ messages in thread
From: Rafał Miłecki @ 2015-05-07 12:13 UTC (permalink / raw)
  To: Kalle Valo, linux-wireless
  Cc: Brett Rudley, Arend van Spriel, Franky (Zhenhui) Lin,
	Hante Meuleman, brcm80211-dev-list, Rafał Miłecki

This prevents silence failures with driver waiting (infinitely) for a
callback.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
---
I don't really have any opinion if this should go for next or as a fix.
---
 drivers/net/wireless/brcm80211/brcmfmac/usb.c | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/brcm80211/brcmfmac/usb.c b/drivers/net/wireless/brcm80211/brcmfmac/usb.c
index 5df6aa7..daba86d 100644
--- a/drivers/net/wireless/brcm80211/brcmfmac/usb.c
+++ b/drivers/net/wireless/brcm80211/brcmfmac/usb.c
@@ -1270,8 +1270,13 @@ static int brcmf_usb_probe_cb(struct brcmf_usbdev_info *devinfo)
 	bus->chiprev = bus_pub->chiprev;
 
 	/* request firmware here */
-	brcmf_fw_get_firmwares(dev, 0, brcmf_usb_get_fwname(devinfo), NULL,
-			       brcmf_usb_probe_phase2);
+	ret = brcmf_fw_get_firmwares(dev, 0, brcmf_usb_get_fwname(devinfo),
+				     NULL, brcmf_usb_probe_phase2);
+	if (ret) {
+		brcmf_err("firmware request failed: %d\n", ret);
+		goto fail;
+	}
+
 	return 0;
 
 fail:
-- 
1.8.4.5


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

end of thread, other threads:[~2015-05-09 14:02 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-07 12:13 [PATCH] brcmfmac: check result of USB firmware request Rafał Miłecki
2015-05-08  9:30 ` Arend van Spriel
2015-05-09 13:59 ` Kalle Valo
2015-05-09 14:02   ` Kalle Valo

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).