]> git.karo-electronics.de Git - linux-beck.git/commitdiff
brcm80211: fmac: initialize host interface drivers regardless result
authorArend van Spriel <arend@broadcom.com>
Fri, 2 Mar 2012 21:55:48 +0000 (22:55 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 5 Mar 2012 20:53:57 +0000 (15:53 -0500)
The module init function of brcmfmac calls init functions for SDIO and
USB doing driver registration. This patch removes terminating the module
init when a driver registration for one host interface fails.

Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/brcm80211/brcmfmac/bcmsdh_sdmmc.c
drivers/net/wireless/brcm80211/brcmfmac/dhd_bus.h
drivers/net/wireless/brcm80211/brcmfmac/dhd_linux.c
drivers/net/wireless/brcm80211/brcmfmac/usb.c

index 83ca3cc2cccb72f2017da288261e34c23600d76e..4688904908ec464b3b9895504e8566eb61d6c5e7 100644 (file)
@@ -604,7 +604,7 @@ void brcmf_sdio_exit(void)
        sdio_unregister_driver(&brcmf_sdmmc_driver);
 }
 
-int brcmf_sdio_init(void)
+void brcmf_sdio_init(void)
 {
        int ret;
 
@@ -614,6 +614,4 @@ int brcmf_sdio_init(void)
 
        if (ret)
                brcmf_dbg(ERROR, "sdio_register_driver failed: %d\n", ret);
-
-       return ret;
 }
index b7671b30692ff0e367c5708db8de8d5463aa4f60..366916494be402a90ffdc5654cc286f075bdc795 100644 (file)
@@ -108,11 +108,11 @@ extern int brcmf_add_if(struct device *dev, int ifidx,
 
 #ifdef CONFIG_BRCMFMAC_SDIO
 extern void brcmf_sdio_exit(void);
-extern int brcmf_sdio_init(void);
+extern void brcmf_sdio_init(void);
 #endif
 #ifdef CONFIG_BRCMFMAC_USB
 extern void brcmf_usb_exit(void);
-extern int brcmf_usb_init(void);
+extern void brcmf_usb_init(void);
 #endif
 
 #endif                         /* _BRCMF_BUS_H_ */
index c4da05817443b6532c6885ac699569262a75433c..e7345569e9de998f0d7e9b1a72032b4bcd4290d5 100644 (file)
@@ -1183,21 +1183,13 @@ exit:
 
 static int __init brcmfmac_init(void)
 {
-       int ret = 0;
-
 #ifdef CONFIG_BRCMFMAC_SDIO
-       ret = brcmf_sdio_init();
-       if (ret)
-               goto fail;
+       brcmf_sdio_init();
 #endif
 #ifdef CONFIG_BRCMFMAC_USB
-       ret = brcmf_usb_init();
-       if (ret)
-               goto fail;
+       brcmf_usb_init();
 #endif
-
-fail:
-       return ret;
+       return 0;
 }
 
 static void __exit brcmfmac_exit(void)
index a2a0c45201acd49e7cc9fd727c561392f4151647..82364223e81785e0023b0d56136dd2b170cac4eb 100644 (file)
@@ -1615,7 +1615,7 @@ void brcmf_usb_exit(void)
        g_image.len = 0;
 }
 
-int brcmf_usb_init(void)
+void brcmf_usb_init(void)
 {
-       return usb_register(&brcmf_usbdrvr);
+       usb_register(&brcmf_usbdrvr);
 }