Search Linux Wireless

Re: [ath9k-devel] [PATCH 1/2] ath9k_htc: add STBC TX support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am 04.05.2013 19:50, schrieb Adrian Chadd:
I've just reviewed it myself:

* oan->stbc is enabled only if the hardware itself supports STBC; so
it's an extra sanity check in case the firmware is told to enable STBC
in the WMI capflag field.

all STBC parts are not compiled for AR9271. Currently firmware will do sanity check on htc_7010.fw and always return 1, and wont do any check on htc_9271.fw (this part is just not compiled).

* is oan->htinfo used anywhere that may involve STBC?

hmm...oan->htinfo?

* .. we should check whether ath9k_htc ever set the STBC flags on
AR9271, or we'd end up confusing the hardware.

no, never. there are legion guardians ;) last on is on preparing tx descriptor.

* .. I don't think that is important though, as we weren't _doing_ STBC, right?

correct, currently STBC is not working on linux ath9k_htc

* Why are the ATH_RC_* flags used in newassoc_11n? This comes from the
WMI WMI_RC_STATE_CHANGE_CMDID capflag field; where are _those_
defined?

they are in target_firmware/wlan/if_athrate.h
and well, there are a bit more problems thin them.
See attachment :) Attached patch can go on top of my merge request for firmware. So, i will probably need to make Patch_v5 for ath9k_htc... since.

Felix,
In addition to that, using the WLAN_RC_* flags is wrong, you need to use
the ATH_RC_* flags,...
After some firmware cleaning i will need to use WLAN_RC_* flags :)
WLAN_RC_* have same values like ATH_RC_*...

Grr, so many things to tidy up.

--
Regards,
Oleksij
diff --git a/target_firmware/wlan/ratectrl11n.h b/target_firmware/wlan/ratectrl11n.h
index 64d0197..00fd156 100755
--- a/target_firmware/wlan/ratectrl11n.h
+++ b/target_firmware/wlan/ratectrl11n.h
@@ -156,20 +156,6 @@ typedef struct {
 } RATE_TABLE_11N;
 
 /*
- *  Update the SIB's rate control information
- *
- *  This should be called when the supported rates change
- *  (e.g. SME operation, wireless mode change)
- *
- *  It will determine which rates are valid for use.
- */
-void rcSibUpdate_11n(struct ath_softc_tgt *,
-		     struct ath_node_target *,
-		     A_UINT32 capflag, 
-		     A_BOOL keepState,
-		     struct ieee80211_rate *rs);
-
-/*
  * Determines and returns the new Tx rate index.
  */ 
 void rcRateFind_11n(struct ath_softc_tgt *sc,
diff --git a/target_firmware/wlan/ratectrl_11n_ln.c b/target_firmware/wlan/ratectrl_11n_ln.c
index 52c1fc7..e64b254 100755
--- a/target_firmware/wlan/ratectrl_11n_ln.c
+++ b/target_firmware/wlan/ratectrl_11n_ln.c
@@ -429,19 +429,7 @@ rcSibUpdate_ht(struct ath_softc_tgt *sc, struct ath_node_target *an,
 	rcSortValidRates(pRateTable, pRc);
 }
 
-void 
-rcSibUpdate_11n(struct ath_softc_tgt *sc, struct ath_node_target *pSib, 
-		A_UINT32 capflag, A_BOOL keepState, struct ieee80211_rate  *pRateSet)
-{
-	rcSibUpdate_ht(sc, 
-		       pSib, 
-		       ((capflag & ATH_RC_DS_FLAG)   ? WLAN_RC_DS_FLAG  : 0) |
-		       ((capflag & ATH_RC_HT40_SGI_FLAG)  ? WLAN_RC_HT40_SGI_FLAG : 0) | 
-		       ((capflag & ATH_RC_HT_FLAG)   ? WLAN_RC_HT_FLAG  : 0) |
-		       ((capflag & ATH_RC_CW40_FLAG) ? WLAN_RC_40_FLAG  : 0),
-		       keepState,
-		       pRateSet);
-}
+
 
 /*
  * Return the median of three numbers
@@ -1212,17 +1200,11 @@ ath_rate_newassoc_11n(struct ath_softc_tgt *sc, struct ath_node_target *an, int
 	if (isnew) {
 		struct atheros_node *oan = ATH_NODE_ATHEROS(an);
 
-		oan->htcap = ((capflag & ATH_RC_DS_FLAG) ? WLAN_RC_DS_FLAG : 0) |
-			((capflag & ATH_RC_HT40_SGI_FLAG) ? WLAN_RC_HT40_SGI_FLAG : 0) | 
-			((capflag & ATH_RC_HT_FLAG)  ? WLAN_RC_HT_FLAG : 0) |
-			((capflag & ATH_RC_CW40_FLAG) ? WLAN_RC_40_FLAG : 0) |
-			((capflag & ATH_RC_WEP_TKIP_FLAG) ? WLAN_RC_WEP_TKIP_FLAG : 0);    
-    
 #ifdef MAGPIE_MERLIN
 		/* Only MERLIN can send STBC */
 		oan->stbc = (capflag & ATH_RC_RX_STBC_FLAG) ? 1 : 0;
 #endif
-		rcSibUpdate_11n(sc, an, oan->htcap, 0, rs);
+		rcSibUpdate_ht(sc, an, capflag, 0, rs);
 	}
 }
 

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux