diff options
author | Michael Straube <straube.linux@gmail.com> | 2022-03-31 15:05:22 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2022-04-04 07:33:48 +0200 |
commit | d8a130d1349759b693367b1b70901d0a7603d188 (patch) | |
tree | 7fc4064e2b1db13b68231360a549fabd781e5906 | |
parent | 61f514799bea3b127d3125b4da5807a1dca4f24b (diff) | |
download | linux-d8a130d1349759b693367b1b70901d0a7603d188.tar.bz2 |
staging: r8188eu: remove GetHwReg8188EU()
The only call to GetHwReg8188EU() that is left over from previous
cleanups sets a variable that is immediately overwritten. This call
is useless and we can finally remove the GetHwReg8188EU() function.
This is part of the ongoing effort to get rid of the unwanted hal
layer.
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220331130522.6648-6-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/r8188eu/hal/usb_halinit.c | 15 | ||||
-rw-r--r-- | drivers/staging/r8188eu/include/hal_intf.h | 1 | ||||
-rw-r--r-- | drivers/staging/r8188eu/os_dep/ioctl_linux.c | 4 |
3 files changed, 1 insertions, 19 deletions
diff --git a/drivers/staging/r8188eu/hal/usb_halinit.c b/drivers/staging/r8188eu/hal/usb_halinit.c index 37c56690b13a..6b4b0b0c4f53 100644 --- a/drivers/staging/r8188eu/hal/usb_halinit.c +++ b/drivers/staging/r8188eu/hal/usb_halinit.c @@ -1283,21 +1283,6 @@ void SetHwReg8188EU(struct adapter *Adapter, u8 variable, u8 *val) } -void GetHwReg8188EU(struct adapter *Adapter, u8 variable, u8 *val) -{ - struct hal_data_8188e *haldata = &Adapter->haldata; - struct odm_dm_struct *podmpriv = &haldata->odmpriv; - - switch (variable) { - case HW_VAR_DM_FLAG: - val[0] = podmpriv->SupportAbility; - break; - default: - break; - } - -} - /* Query setting of specified variable. */ void GetHalDefVar8188EUsb(struct adapter *Adapter, enum hal_def_variable eVariable, void *pValue) { diff --git a/drivers/staging/r8188eu/include/hal_intf.h b/drivers/staging/r8188eu/include/hal_intf.h index 0033a0aca27b..9b465001975c 100644 --- a/drivers/staging/r8188eu/include/hal_intf.h +++ b/drivers/staging/r8188eu/include/hal_intf.h @@ -66,7 +66,6 @@ void GetHalDefVar8188EUsb(struct adapter *Adapter, enum hal_def_variable eVariab unsigned int rtl8188eu_inirp_init(struct adapter *Adapter); void SetHwReg8188EU(struct adapter *Adapter, u8 variable, u8 *val); -void GetHwReg8188EU(struct adapter *Adapter, u8 variable, u8 *val); uint rtw_hal_init(struct adapter *padapter); uint rtw_hal_deinit(struct adapter *padapter); diff --git a/drivers/staging/r8188eu/os_dep/ioctl_linux.c b/drivers/staging/r8188eu/os_dep/ioctl_linux.c index 7df213856d66..6383b399ae40 100644 --- a/drivers/staging/r8188eu/os_dep/ioctl_linux.c +++ b/drivers/staging/r8188eu/os_dep/ioctl_linux.c @@ -3620,9 +3620,7 @@ static int rtw_dbg_port(struct net_device *dev, break; case 0x06: { - u32 ODMFlag; - GetHwReg8188EU(padapter, HW_VAR_DM_FLAG, (u8 *)(&ODMFlag)); - ODMFlag = (u32)(0x0f & arg); + u32 ODMFlag = (u32)(0x0f & arg); SetHwReg8188EU(padapter, HW_VAR_DM_FLAG, (u8 *)(&ODMFlag)); } break; |