Commit e827aeed authored by Jakub Sitnicki's avatar Jakub Sitnicki Committed by Greg Kroah-Hartman

staging: rtl8188eu: remove ICtype from struct HAL_VERSION

IC type on RTL8188EU is always 8188E.  Remove it and all the macros that
check it.
Signed-off-by: default avatarJakub Sitnicki <jsitnicki@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 3738408c
...@@ -31,18 +31,7 @@ void dump_chip_info(struct HAL_VERSION chip_vers) ...@@ -31,18 +31,7 @@ void dump_chip_info(struct HAL_VERSION chip_vers)
uint cnt = 0; uint cnt = 0;
char buf[128]; char buf[128];
if (IS_81XXC(chip_vers)) { cnt += sprintf((buf+cnt), "Chip Version Info: CHIP_8188E_");
cnt += sprintf((buf+cnt), "Chip Version Info: %s_",
IS_92C_SERIAL(chip_vers) ?
"CHIP_8192C" : "CHIP_8188C");
} else if (IS_92D(chip_vers)) {
cnt += sprintf((buf+cnt), "Chip Version Info: CHIP_8192D_");
} else if (IS_8723_SERIES(chip_vers)) {
cnt += sprintf((buf+cnt), "Chip Version Info: CHIP_8723A_");
} else if (IS_8188E(chip_vers)) {
cnt += sprintf((buf+cnt), "Chip Version Info: CHIP_8188E_");
}
cnt += sprintf((buf+cnt), "%s_", IS_NORMAL_CHIP(chip_vers) ? cnt += sprintf((buf+cnt), "%s_", IS_NORMAL_CHIP(chip_vers) ?
"Normal_Chip" : "Test_Chip"); "Normal_Chip" : "Test_Chip");
cnt += sprintf((buf+cnt), "%s_", IS_CHIP_VENDOR_TSMC(chip_vers) ? cnt += sprintf((buf+cnt), "%s_", IS_CHIP_VENDOR_TSMC(chip_vers) ?
......
...@@ -137,7 +137,6 @@ static struct HAL_VERSION ReadChipVersion8188E(struct adapter *padapter) ...@@ -137,7 +137,6 @@ static struct HAL_VERSION ReadChipVersion8188E(struct adapter *padapter)
pHalData = GET_HAL_DATA(padapter); pHalData = GET_HAL_DATA(padapter);
value32 = usb_read32(padapter, REG_SYS_CFG); value32 = usb_read32(padapter, REG_SYS_CFG);
ChipVersion.ICType = CHIP_8188E;
ChipVersion.ChipType = ((value32 & RTL_ID) ? TEST_CHIP : NORMAL_CHIP); ChipVersion.ChipType = ((value32 & RTL_ID) ? TEST_CHIP : NORMAL_CHIP);
ChipVersion.RFType = RF_TYPE_1T1R; ChipVersion.RFType = RF_TYPE_1T1R;
......
...@@ -1703,7 +1703,7 @@ static void SetHwReg8188EU(struct adapter *Adapter, u8 variable, u8 *val) ...@@ -1703,7 +1703,7 @@ static void SetHwReg8188EU(struct adapter *Adapter, u8 variable, u8 *val)
/* Forece leave RF low power mode for 1T1R to prevent conficting setting in Fw power */ /* Forece leave RF low power mode for 1T1R to prevent conficting setting in Fw power */
/* saving sequence. 2010.06.07. Added by tynli. Suggested by SD3 yschang. */ /* saving sequence. 2010.06.07. Added by tynli. Suggested by SD3 yschang. */
if ((psmode != PS_MODE_ACTIVE) && (!IS_92C_SERIAL(haldata->VersionID))) if (psmode != PS_MODE_ACTIVE)
ODM_RF_Saving(podmpriv, true); ODM_RF_Saving(podmpriv, true);
rtl8188e_set_FwPwrMode_cmd(Adapter, psmode); rtl8188e_set_FwPwrMode_cmd(Adapter, psmode);
} }
......
...@@ -20,20 +20,6 @@ ...@@ -20,20 +20,6 @@
#ifndef __HAL_VERSION_DEF_H__ #ifndef __HAL_VERSION_DEF_H__
#define __HAL_VERSION_DEF_H__ #define __HAL_VERSION_DEF_H__
enum HAL_IC_TYPE {
CHIP_8192S = 0,
CHIP_8188C = 1,
CHIP_8192C = 2,
CHIP_8192D = 3,
CHIP_8723A = 4,
CHIP_8188E = 5,
CHIP_8881A = 6,
CHIP_8812A = 7,
CHIP_8821A = 8,
CHIP_8723B = 9,
CHIP_8192E = 10,
};
enum HAL_CHIP_TYPE { enum HAL_CHIP_TYPE {
TEST_CHIP = 0, TEST_CHIP = 0,
NORMAL_CHIP = 1, NORMAL_CHIP = 1,
...@@ -67,7 +53,6 @@ enum HAL_RF_TYPE { ...@@ -67,7 +53,6 @@ enum HAL_RF_TYPE {
}; };
struct HAL_VERSION { struct HAL_VERSION {
enum HAL_IC_TYPE ICType;
enum HAL_CHIP_TYPE ChipType; enum HAL_CHIP_TYPE ChipType;
enum HAL_CUT_VERSION CUTVersion; enum HAL_CUT_VERSION CUTVersion;
enum HAL_VENDOR VendorType; enum HAL_VENDOR VendorType;
...@@ -76,7 +61,6 @@ struct HAL_VERSION { ...@@ -76,7 +61,6 @@ struct HAL_VERSION {
}; };
/* Get element */ /* Get element */
#define GET_CVID_IC_TYPE(version) (((version).ICType))
#define GET_CVID_CHIP_TYPE(version) (((version).ChipType)) #define GET_CVID_CHIP_TYPE(version) (((version).ChipType))
#define GET_CVID_RF_TYPE(version) (((version).RFType)) #define GET_CVID_RF_TYPE(version) (((version).RFType))
#define GET_CVID_MANUFACTUER(version) (((version).VendorType)) #define GET_CVID_MANUFACTUER(version) (((version).VendorType))
...@@ -86,17 +70,6 @@ struct HAL_VERSION { ...@@ -86,17 +70,6 @@ struct HAL_VERSION {
/* Common Macro. -- */ /* Common Macro. -- */
/* HAL_VERSION VersionID */ /* HAL_VERSION VersionID */
/* HAL_IC_TYPE_E */
#define IS_81XXC(version) \
(((GET_CVID_IC_TYPE(version) == CHIP_8192C) || \
(GET_CVID_IC_TYPE(version) == CHIP_8188C)) ? true : false)
#define IS_8723_SERIES(version) \
((GET_CVID_IC_TYPE(version) == CHIP_8723A) ? true : false)
#define IS_92D(version) \
((GET_CVID_IC_TYPE(version) == CHIP_8192D) ? true : false)
#define IS_8188E(version) \
((GET_CVID_IC_TYPE(version) == CHIP_8188E) ? true : false)
/* HAL_CHIP_TYPE_E */ /* HAL_CHIP_TYPE_E */
#define IS_TEST_CHIP(version) \ #define IS_TEST_CHIP(version) \
((GET_CVID_CHIP_TYPE(version) == TEST_CHIP) ? true : false) ((GET_CVID_CHIP_TYPE(version) == TEST_CHIP) ? true : false)
...@@ -130,38 +103,4 @@ struct HAL_VERSION { ...@@ -130,38 +103,4 @@ struct HAL_VERSION {
#define IS_2T2R(version) \ #define IS_2T2R(version) \
((GET_CVID_RF_TYPE(version) == RF_TYPE_2T2R) ? true : false) ((GET_CVID_RF_TYPE(version) == RF_TYPE_2T2R) ? true : false)
/* Chip version Macro. -- */
#define IS_81XXC_TEST_CHIP(version) \
((IS_81XXC(version) && (!IS_NORMAL_CHIP(version))) ? true : false)
#define IS_92C_SERIAL(version) \
((IS_81XXC(version) && IS_2T2R(version)) ? true : false)
#define IS_81xxC_VENDOR_UMC_A_CUT(version) \
(IS_81XXC(version) ? (IS_CHIP_VENDOR_UMC(version) ? \
(IS_A_CUT(version) ? true : false) : false) : false)
#define IS_81xxC_VENDOR_UMC_B_CUT(version) \
(IS_81XXC(version) ? (IS_CHIP_VENDOR_UMC(version) ? \
(IS_B_CUT(version) ? true : false) : false) : false)
#define IS_81xxC_VENDOR_UMC_C_CUT(version) \
(IS_81XXC(version) ? (IS_CHIP_VENDOR_UMC(version) ? \
(IS_C_CUT(version) ? true : false) : false) : false)
#define IS_NORMAL_CHIP92D(version) \
((IS_92D(version)) ? \
((GET_CVID_CHIP_TYPE(version) == NORMAL_CHIP) ? true : false) : false)
#define IS_92D_SINGLEPHY(version) \
((IS_92D(version)) ? (IS_2T2R(version) ? true : false) : false)
#define IS_92D_C_CUT(version) \
((IS_92D(version)) ? (IS_C_CUT(version) ? true : false) : false)
#define IS_92D_D_CUT(version) \
((IS_92D(version)) ? (IS_D_CUT(version) ? true : false) : false)
#define IS_92D_E_CUT(version) \
((IS_92D(version)) ? (IS_E_CUT(version) ? true : false) : false)
#define IS_8723A_A_CUT(version) \
((IS_8723_SERIES(version)) ? (IS_A_CUT(version) ? true : false) : false)
#define IS_8723A_B_CUT(version) \
((IS_8723_SERIES(version)) ? (IS_B_CUT(version) ? true : false) : false)
#endif #endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment