[PATCH 3/4] Set short_preamble_supported
Eugene Krasnikov
k.eugene.e at gmail.com
Wed Jul 17 13:47:32 EDT 2013
Check if HW supports short preamble or not.
Signed-off-by: Eugene Krasnikov <k.eugene.e at gmail.com>
---
smd.c | 5 ++++-
wcn36xx.h | 1 +
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/smd.c b/smd.c
index cd19bde..53c0736 100644
--- a/smd.c
+++ b/smd.c
@@ -90,7 +90,10 @@ static void wcn36xx_smd_set_sta_params(struct wcn36xx *wcn,
memcpy(&sta_params->bssid, vif->addr, ETH_ALEN);
sta_params->encrypt_type = wcn->encrypt_type;
- sta_params->short_preamble_supported = 0;
+ sta_params->short_preamble_supported =
+ !(WCN36XX_FLAGS(wcn) &
+ IEEE80211_HW_2GHZ_SHORT_PREAMBLE_INCAPABLE);
+
sta_params->rifs_mode = 0;
sta_params->rmf = 0;
sta_params->action = 0;
diff --git a/wcn36xx.h b/wcn36xx.h
index 2ac6baf..fa2f46b 100644
--- a/wcn36xx.h
+++ b/wcn36xx.h
@@ -83,6 +83,7 @@ enum wcn36xx_debug_mask {
#define WCN36XX_BAND(__wcn) (__wcn->hw->conf.chandef.chan->band)
#define WCN36XX_CENTER_FREQ(__wcn) (__wcn->hw->conf.chandef.chan->center_freq)
#define WCN36XX_LISTEN_INTERVAL(__wcn) (__wcn->hw->conf.listen_interval)
+#define WCN36XX_FLAGS(__wcn) (__wcn->hw->flags)
static inline void buff_to_be(u32 *buf, size_t len)
{
--
1.8.2.2
More information about the wcn36xx
mailing list