diff options
author | Larry Finger <Larry.Finger@lwfinger.net> | 2012-09-11 12:11:13 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2012-09-12 14:15:31 -0400 |
commit | 022e1d0680c7b4366017393417b8758be5abcee8 (patch) | |
tree | 0cd5fad1292472b385a62448d3abffc6d9266a17 /drivers/net | |
parent | 4abd044af91057f7ea661a0f10c00a9673beef6b (diff) |
rtlwifi: rtl8192ce: Log message that B_CUT device may not work
There are a number of problems that occur for the latest version
of the Realtek RTL8188CE device with the in-kernel driver. These
include selection of the wrong firmware, and system lockup. A full
fix is known, but is too invasive for inclusion in stable. This patch
fixes the problem with loading the wrong firmware, and logs a message
that the device may not work for kernels 3.6 and older.
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org>
Cc: Anisse Astier <anisse@astier.eu>
Cc: Li Chaoming <chaoming_li@realsil.com.cn>
Tested-by: Anisse Astier <anisse@astier.eu>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/wireless/rtlwifi/rtl8192ce/def.h | 1 | ||||
-rw-r--r-- | drivers/net/wireless/rtlwifi/rtl8192ce/hw.c | 12 | ||||
-rw-r--r-- | drivers/net/wireless/rtlwifi/rtl8192ce/sw.c | 6 |
3 files changed, 15 insertions, 4 deletions
diff --git a/drivers/net/wireless/rtlwifi/rtl8192ce/def.h b/drivers/net/wireless/rtlwifi/rtl8192ce/def.h index 04c3aef8a4f6..2925094b2d91 100644 --- a/drivers/net/wireless/rtlwifi/rtl8192ce/def.h +++ b/drivers/net/wireless/rtlwifi/rtl8192ce/def.h | |||
@@ -117,6 +117,7 @@ | |||
117 | 117 | ||
118 | #define CHIP_VER_B BIT(4) | 118 | #define CHIP_VER_B BIT(4) |
119 | #define CHIP_92C_BITMASK BIT(0) | 119 | #define CHIP_92C_BITMASK BIT(0) |
120 | #define CHIP_UNKNOWN BIT(7) | ||
120 | #define CHIP_92C_1T2R 0x03 | 121 | #define CHIP_92C_1T2R 0x03 |
121 | #define CHIP_92C 0x01 | 122 | #define CHIP_92C 0x01 |
122 | #define CHIP_88C 0x00 | 123 | #define CHIP_88C 0x00 |
diff --git a/drivers/net/wireless/rtlwifi/rtl8192ce/hw.c b/drivers/net/wireless/rtlwifi/rtl8192ce/hw.c index bd0da7ef290b..dd4bb0950a57 100644 --- a/drivers/net/wireless/rtlwifi/rtl8192ce/hw.c +++ b/drivers/net/wireless/rtlwifi/rtl8192ce/hw.c | |||
@@ -994,8 +994,16 @@ static enum version_8192c _rtl92ce_read_chip_version(struct ieee80211_hw *hw) | |||
994 | version = (value32 & TYPE_ID) ? VERSION_A_CHIP_92C : | 994 | version = (value32 & TYPE_ID) ? VERSION_A_CHIP_92C : |
995 | VERSION_A_CHIP_88C; | 995 | VERSION_A_CHIP_88C; |
996 | } else { | 996 | } else { |
997 | version = (value32 & TYPE_ID) ? VERSION_B_CHIP_92C : | 997 | version = (enum version_8192c) (CHIP_VER_B | |
998 | VERSION_B_CHIP_88C; | 998 | ((value32 & TYPE_ID) ? CHIP_92C_BITMASK : 0) | |
999 | ((value32 & VENDOR_ID) ? CHIP_VENDOR_UMC : 0)); | ||
1000 | if ((!IS_CHIP_VENDOR_UMC(version)) && (value32 & | ||
1001 | CHIP_VER_RTL_MASK)) { | ||
1002 | version = (enum version_8192c)(version | | ||
1003 | ((((value32 & CHIP_VER_RTL_MASK) == BIT(12)) | ||
1004 | ? CHIP_VENDOR_UMC_B_CUT : CHIP_UNKNOWN) | | ||
1005 | CHIP_VENDOR_UMC)); | ||
1006 | } | ||
999 | } | 1007 | } |
1000 | 1008 | ||
1001 | switch (version) { | 1009 | switch (version) { |
diff --git a/drivers/net/wireless/rtlwifi/rtl8192ce/sw.c b/drivers/net/wireless/rtlwifi/rtl8192ce/sw.c index 3aa927f8b9b9..7d8f96405f42 100644 --- a/drivers/net/wireless/rtlwifi/rtl8192ce/sw.c +++ b/drivers/net/wireless/rtlwifi/rtl8192ce/sw.c | |||
@@ -162,10 +162,12 @@ int rtl92c_init_sw_vars(struct ieee80211_hw *hw) | |||
162 | 162 | ||
163 | /* request fw */ | 163 | /* request fw */ |
164 | if (IS_VENDOR_UMC_A_CUT(rtlhal->version) && | 164 | if (IS_VENDOR_UMC_A_CUT(rtlhal->version) && |
165 | !IS_92C_SERIAL(rtlhal->version)) | 165 | !IS_92C_SERIAL(rtlhal->version)) { |
166 | rtlpriv->cfg->fw_name = "rtlwifi/rtl8192cfwU.bin"; | 166 | rtlpriv->cfg->fw_name = "rtlwifi/rtl8192cfwU.bin"; |
167 | else if (IS_81xxC_VENDOR_UMC_B_CUT(rtlhal->version)) | 167 | } else if (IS_81xxC_VENDOR_UMC_B_CUT(rtlhal->version)) { |
168 | rtlpriv->cfg->fw_name = "rtlwifi/rtl8192cfwU_B.bin"; | 168 | rtlpriv->cfg->fw_name = "rtlwifi/rtl8192cfwU_B.bin"; |
169 | pr_info("****** This B_CUT device may not work with kernels 3.6 and earlier\n"); | ||
170 | } | ||
169 | 171 | ||
170 | rtlpriv->max_fw_size = 0x4000; | 172 | rtlpriv->max_fw_size = 0x4000; |
171 | pr_info("Using firmware %s\n", rtlpriv->cfg->fw_name); | 173 | pr_info("Using firmware %s\n", rtlpriv->cfg->fw_name); |