ath10k: add hw rate definitions
authorMichal Kazior <michal.kazior@tieto.com>
Mon, 30 Mar 2015 06:51:55 +0000 (09:51 +0300)
committerKalle Valo <kvalo@qca.qualcomm.com>
Mon, 30 Mar 2015 12:09:15 +0000 (15:09 +0300)
Prepare defines for future use.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
drivers/net/wireless/ath/ath10k/htt.h
drivers/net/wireless/ath/ath10k/hw.h
drivers/net/wireless/ath/ath10k/rx_desc.h

index 95df742fc827a33f396a2ca2f8aafb382422e0db..ef64f301a9e880ac6ffb8c547816b4ce67846b7f 100644 (file)
@@ -25,6 +25,7 @@
 #include <net/mac80211.h>
 
 #include "htc.h"
+#include "hw.h"
 #include "rx_desc.h"
 #include "hw.h"
 
index 316c1a52d1ec196c01ef524db0d0e13aaba1fc8c..25421597363780cf9e75dbccc6b9e654afb2b2e6 100644 (file)
@@ -202,6 +202,27 @@ struct ath10k_pktlog_hdr {
        u8 payload[0];
 } __packed;
 
+enum ath10k_hw_rate_ofdm {
+       ATH10K_HW_RATE_OFDM_48M = 0,
+       ATH10K_HW_RATE_OFDM_24M,
+       ATH10K_HW_RATE_OFDM_12M,
+       ATH10K_HW_RATE_OFDM_6M,
+       ATH10K_HW_RATE_OFDM_54M,
+       ATH10K_HW_RATE_OFDM_36M,
+       ATH10K_HW_RATE_OFDM_18M,
+       ATH10K_HW_RATE_OFDM_9M,
+};
+
+enum ath10k_hw_rate_cck {
+       ATH10K_HW_RATE_CCK_LP_11M = 0,
+       ATH10K_HW_RATE_CCK_LP_5_5M,
+       ATH10K_HW_RATE_CCK_LP_2M,
+       ATH10K_HW_RATE_CCK_LP_1M,
+       ATH10K_HW_RATE_CCK_SP_11M,
+       ATH10K_HW_RATE_CCK_SP_5_5M,
+       ATH10K_HW_RATE_CCK_SP_2M,
+};
+
 /* Target specific defines for MAIN firmware */
 #define TARGET_NUM_VDEVS                       8
 #define TARGET_NUM_PEER_AST                    2
index e9cc7787bf5fd61c788c91212d080e78cde9fcc5..492b5a5af434ddb67e01fa9c0d4638eb84f3d66e 100644 (file)
@@ -661,6 +661,28 @@ struct rx_msdu_end {
 #define RX_PPDU_START_INFO5_SERVICE_MASK 0x0000ffff
 #define RX_PPDU_START_INFO5_SERVICE_LSB  0
 
+/* No idea what this flag means. It seems to be always set in rate. */
+#define RX_PPDU_START_RATE_FLAG BIT(3)
+
+enum rx_ppdu_start_rate {
+       RX_PPDU_START_RATE_OFDM_48M = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_OFDM_48M,
+       RX_PPDU_START_RATE_OFDM_24M = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_OFDM_24M,
+       RX_PPDU_START_RATE_OFDM_12M = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_OFDM_12M,
+       RX_PPDU_START_RATE_OFDM_6M  = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_OFDM_6M,
+       RX_PPDU_START_RATE_OFDM_54M = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_OFDM_54M,
+       RX_PPDU_START_RATE_OFDM_36M = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_OFDM_36M,
+       RX_PPDU_START_RATE_OFDM_18M = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_OFDM_18M,
+       RX_PPDU_START_RATE_OFDM_9M  = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_OFDM_9M,
+
+       RX_PPDU_START_RATE_CCK_LP_11M  = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_CCK_LP_11M,
+       RX_PPDU_START_RATE_CCK_LP_5_5M = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_CCK_LP_5_5M,
+       RX_PPDU_START_RATE_CCK_LP_2M   = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_CCK_LP_2M,
+       RX_PPDU_START_RATE_CCK_LP_1M   = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_CCK_LP_1M,
+       RX_PPDU_START_RATE_CCK_SP_11M  = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_CCK_SP_11M,
+       RX_PPDU_START_RATE_CCK_SP_5_5M = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_CCK_SP_5_5M,
+       RX_PPDU_START_RATE_CCK_SP_2M   = RX_PPDU_START_RATE_FLAG | ATH10K_HW_RATE_CCK_SP_2M,
+};
+
 struct rx_ppdu_start {
        struct {
                u8 pri20_mhz;