staging: r8188eu: remove HW_VAR_MEDIA_STATUS

Remove HW_VAR_MEDIA_STATUS from SetHwReg8188EU() and call
rtw_read8() and rtw_write8() directly.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20220130190321.7172-8-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Michael Straube
2022-01-30 20:03:16 +01:00
committed by Greg Kroah-Hartman
parent 39c2b86478
commit 0599a490f3
3 changed files with 5 additions and 11 deletions

View File

@@ -286,7 +286,11 @@ void Switch_DM_Func(struct adapter *padapter, u32 mode, u8 enable)
static void Set_NETYPE0_MSR(struct adapter *padapter, u8 type)
{
SetHwReg8188EU(padapter, HW_VAR_MEDIA_STATUS, (u8 *)(&type));
u8 val8;
val8 = rtw_read8(padapter, MSR) & 0x0c;
val8 |= type;
rtw_write8(padapter, MSR, val8);
}
void Set_MSR(struct adapter *padapter, u8 type)

View File

@@ -1068,15 +1068,6 @@ void SetHwReg8188EU(struct adapter *Adapter, u8 variable, u8 *val)
struct odm_dm_struct *podmpriv = &haldata->odmpriv;
switch (variable) {
case HW_VAR_MEDIA_STATUS:
{
u8 val8;
val8 = rtw_read8(Adapter, MSR) & 0x0c;
val8 |= *((u8 *)val);
rtw_write8(Adapter, MSR, val8);
}
break;
case HW_VAR_SET_OPMODE:
hw_var_set_opmode(Adapter, val);
break;

View File

@@ -9,7 +9,6 @@
#include "Hal8188EPhyCfg.h"
enum hw_variables {
HW_VAR_MEDIA_STATUS,
HW_VAR_SET_OPMODE,
HW_VAR_BSSID,
HW_VAR_INIT_RTS_RATE,