Skip to contentSkip to conversation

RTL8192CU: Increase max APFM_ONMAC polling count

PATCH In review Andy Spencer 2 participants 2 messages May 2, 2014 – May 6, 2014 Networking drivers (wireless)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 RTL8192CU: Increase max APFM_ONMAC polling count

With certain hardware combinations the poll interval is exceeded before initialization completes.

Tested on a MacBookPro10,1 using a Sabrent USB-A11N USB adapter.

---
I was unable to reproduce this issue using other hardware combinations. I thought it might be a USB3 issue but another laptop with USB3 worked without the patch.

With my hardware the polling count reaches around 230 before initialization completes.

 drivers/net/wireless/rtlwifi/rtl8192cu/hw.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/wireless/rtlwifi/rtl8192cu/hw.c +1 -1
@@ -511,7 +511,7 @@ static int _rtl92cu_init_power_on(struct ieee80211_hw *hw)
 			pr_info("MAC auto ON okay!\n");
 			break;
 		}
-		if (pollingCount++ > 100) {
+		if (pollingCount++ > 1000) {
 			RT_TRACE(rtlpriv, COMP_INIT, DBG_EMERG,
 				 "Failed to polling REG_APS_FSMCO[APFM_ONMAC] done!\n");
 			return -ENODEV;
Acked-by on v1 1/1
#1 lore raw
Quoted 5 lines · Andy Spencer

With certain hardware combinations the poll interval is exceeded before initialization completes.

Tested on a MacBookPro10,1 using a Sabrent USB-A11N USB adapter.

Quoted 8 lines

---
I was unable to reproduce this issue using other hardware combinations. I thought it might be a USB3 issue but another laptop with USB3 worked without the patch.

With my hardware the polling count reaches around 230 before initialization completes.

If the adapter initializes quickly, this change causes no problem. I have not seen this kind of problem, but some hardware is obviously different.

Larry

Quoted 20 lines
  drivers/net/wireless/rtlwifi/rtl8192cu/hw.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/wireless/rtlwifi/rtl8192cu/hw.c +1 -2
@@ -511,7 +511,7 @@ static int _rtl92cu_init_power_on(struct ieee80211_hw *hw)
  			pr_info("MAC auto ON okay!\n");
  			break;
  		}
-		if (pollingCount++ > 100) {
+		if (pollingCount++ > 1000) {
  			RT_TRACE(rtlpriv, COMP_INIT, DBG_EMERG,
  				 "Failed to polling REG_APS_FSMCO[APFM_ONMAC] done!\n");
  			return -ENODEV;
--

To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html