staging: brcm80211: flatten wlc_phy_shared_detach()
authorHenry Ptasinski <henryp@broadcom.com>
Wed, 29 Jun 2011 23:46:54 +0000 (16:46 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 5 Jul 2011 16:57:13 +0000 (09:57 -0700)
wlc_phy_shared_detach() is an unnecessary level of indirection to just
call kfree(), so replace the function with kfree().

Signed-off-by: Henry Ptasinski <henryp@broadcom.com>
Reviewed-by: Roland Vossen <rvossen@broadcom.com>
Reviewed-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/brcm80211/brcmsmac/bmac.c
drivers/staging/brcm80211/brcmsmac/phy/phy_cmn.c
drivers/staging/brcm80211/brcmsmac/phy/phy_hal.h

index 90d1b327f029763c5bdec94ab83bfac9edb149aa..f44f581068a4453aee24d9fa3cc19bf52a6e60eb 100644 (file)
@@ -982,7 +982,7 @@ int brcms_b_detach(struct brcms_c_info *wlc)
        }
 
        /* Free shared phy state */
-       wlc_phy_shared_detach(wlc_hw->phy_sh);
+       kfree(wlc_hw->phy_sh);
 
        wlc_phy_shim_detach(wlc_hw->physhim);
 
index a15c14581304ba2a63fa5a20d70cb454b018e50f..b527e5f0fac06d7d257ad7108dd76309293fb3c0 100644 (file)
@@ -506,13 +506,6 @@ shared_phy_t *wlc_phy_shared_attach(shared_phy_params_t *shp)
        return sh;
 }
 
-void wlc_phy_shared_detach(shared_phy_t *phy_sh)
-{
-       if (phy_sh) {
-               kfree(phy_sh);
-       }
-}
-
 wlc_phy_t *wlc_phy_attach(shared_phy_t *sh, void *regs, int bandtype,
                          char *vars, struct wiphy *wiphy)
 {
index 3c125c3f476f40235237619dfd17a74fb62602e8..0ea337be846b626dc6ad5ddd223bde0f46cd84ba 100644 (file)
@@ -177,7 +177,6 @@ struct shared_phy_params {
 
 
 extern shared_phy_t *wlc_phy_shared_attach(shared_phy_params_t *shp);
-extern void wlc_phy_shared_detach(shared_phy_t *phy_sh);
 extern wlc_phy_t *wlc_phy_attach(shared_phy_t *sh, void *regs, int bandtype,
                                 char *vars, struct wiphy *wiphy);
 extern void wlc_phy_detach(wlc_phy_t *ppi);