staging: rtl8723au: We love wrappers!
authorJes Sorensen <Jes.Sorensen@redhat.com>
Fri, 16 May 2014 08:04:06 +0000 (10:04 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 16 May 2014 18:34:24 +0000 (11:34 -0700)
Get rid of pointless wrapper around a simple kfree()

Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8723au/hal/hal_intf.c
drivers/staging/rtl8723au/hal/rtl8723a_hal_init.c
drivers/staging/rtl8723au/include/hal_intf.h
drivers/staging/rtl8723au/os_dep/os_intfs.c

index b462fc53aa92b940ba1aa95ba552139eec3db7ae..ad8c430657d133798eb6081dbd5f8a64190a4341 100644 (file)
@@ -28,11 +28,6 @@ void rtw_hal_chip_configure23a(struct rtw_adapter *padapter)
                padapter->HalFunc.intf_chip_configure(padapter);
 }
 
-void   rtw_hal_free_data23a(struct rtw_adapter *padapter)
-{
-       if (padapter->HalFunc.free_hal_data)
-               padapter->HalFunc.free_hal_data(padapter);
-}
 void   rtw_hal_sw_led_init23a(struct rtw_adapter *padapter)
 {
        if (padapter->HalFunc.InitSwLeds)
index b2e2734f26c43f13b075617b355d4c0f7388c98e..8764172faaa4f3f7429990535b9bfebe57c39301 100644 (file)
@@ -427,14 +427,6 @@ void rtl8723a_InitializeFirmwareVars(struct rtw_adapter *padapter)
        pHalData->LastHMEBoxNum = 0;
 }
 
-static void rtl8723a_free_hal_data(struct rtw_adapter *padapter)
-{
-
-       kfree(padapter->HalData);
-       padapter->HalData = NULL;
-
-}
-
 /*  */
 /*                             Efuse related code */
 /*  */
@@ -1714,8 +1706,6 @@ exit:
 
 void rtl8723a_set_hal_ops(struct hal_ops *pHalFunc)
 {
-       pHalFunc->free_hal_data = &rtl8723a_free_hal_data;
-
        pHalFunc->set_bwmode_handler = &PHY_SetBWMode23a8723A;
        pHalFunc->set_channel_handler = &PHY_SwChnl8723A;
 
index f56d7578b74ef0662f8b084e568745769049441c..5009c7d73b6510698ba86e41174216f43aeb4892 100644 (file)
@@ -65,8 +65,6 @@ struct hal_ops {
        u32 (*hal_init)(struct rtw_adapter *padapter);
        u32 (*hal_deinit)(struct rtw_adapter *padapter);
 
-       void (*free_hal_data)(struct rtw_adapter *padapter);
-
        s32 (*init_xmit_priv)(struct rtw_adapter *padapter);
 
        s32 (*init_recv_priv)(struct rtw_adapter *padapter);
@@ -173,8 +171,6 @@ void rtw_hal_def_value_init23a(struct rtw_adapter *padapter);
 int pm_netdev_open23a(struct net_device *pnetdev, u8 bnormal);
 int rtw_resume_process23a(struct rtw_adapter *padapter);
 
-void   rtw_hal_free_data23a(struct rtw_adapter *padapter);
-
 void rtw_hal_sw_led_init23a(struct rtw_adapter *padapter);
 void rtw_hal_sw_led_deinit23a(struct rtw_adapter *padapter);
 
index 38ad4ab45206cc08f094659860d1b2949b6dc39f..3a455d111a33cbeb0385aa1d933bedb7fee56970 100644 (file)
@@ -584,7 +584,8 @@ u8 rtw_free_drv_sw23a(struct rtw_adapter *padapter)
 
        rtw_free_pwrctrl_priv(padapter);
 
-       rtw_hal_free_data23a(padapter);
+       kfree(padapter->HalData);
+       padapter->HalData = NULL;
 
        RT_TRACE(_module_os_intfs_c_, _drv_info_, ("<== rtw_free_drv_sw23a\n"));