Browse Source

mac80211: add ldpc and stbc support to minstrel_ht

SVN-Revision: 20975
Felix Fietkau 16 years ago
parent
commit
2f366cb4bd
1 changed files with 12 additions and 2 deletions
  1. 12 2
      package/mac80211/patches/530-minstrel_ht.patch

+ 12 - 2
package/mac80211/patches/530-minstrel_ht.patch

@@ -68,7 +68,7 @@
  
  
 --- /dev/null
 --- /dev/null
 +++ b/net/mac80211/rc80211_minstrel_ht.c
 +++ b/net/mac80211/rc80211_minstrel_ht.c
-@@ -0,0 +1,815 @@
+@@ -0,0 +1,822 @@
 +/*
 +/*
 + * Copyright (C) 2010 Felix Fietkau <[email protected]>
 + * Copyright (C) 2010 Felix Fietkau <[email protected]>
 + *
 + *
@@ -660,6 +660,7 @@
 +	if (!msp->is_ht)
 +	if (!msp->is_ht)
 +		return mac80211_minstrel.get_rate(priv, sta, &msp->legacy, txrc);
 +		return mac80211_minstrel.get_rate(priv, sta, &msp->legacy, txrc);
 +
 +
++	info->flags |= mi->tx_flags;
 +	sample_idx = minstrel_get_sample_rate(mp, mi);
 +	sample_idx = minstrel_get_sample_rate(mp, mi);
 +	if (sample_idx >= 0) {
 +	if (sample_idx >= 0) {
 +		minstrel_ht_set_rate(mp, mi, &ar[0], sample_idx,
 +		minstrel_ht_set_rate(mp, mi, &ar[0], sample_idx,
@@ -733,6 +734,12 @@
 +	}
 +	}
 +	mi->sample_tries = 4;
 +	mi->sample_tries = 4;
 +
 +
++	if (sta_cap & IEEE80211_HT_CAP_TX_STBC)
++		mi->tx_flags |= IEEE80211_TX_CTL_STBC;
++
++	if (sta_cap & IEEE80211_HT_CAP_LDPC_CODING)
++		mi->tx_flags |= IEEE80211_TX_CTL_LDPC;
++
 +	if (oper_chan_type != NL80211_CHAN_HT40MINUS &&
 +	if (oper_chan_type != NL80211_CHAN_HT40MINUS &&
 +	    oper_chan_type != NL80211_CHAN_HT40PLUS)
 +	    oper_chan_type != NL80211_CHAN_HT40PLUS)
 +		sta_cap &= ~IEEE80211_HT_CAP_SUP_WIDTH_20_40;
 +		sta_cap &= ~IEEE80211_HT_CAP_SUP_WIDTH_20_40;
@@ -886,7 +893,7 @@
 +}
 +}
 --- /dev/null
 --- /dev/null
 +++ b/net/mac80211/rc80211_minstrel_ht.h
 +++ b/net/mac80211/rc80211_minstrel_ht.h
-@@ -0,0 +1,125 @@
+@@ -0,0 +1,128 @@
 +/*
 +/*
 + * Copyright (C) 2010 Felix Fietkau <[email protected]>
 + * Copyright (C) 2010 Felix Fietkau <[email protected]>
 + *
 + *
@@ -983,6 +990,9 @@
 +	unsigned int total_packets;
 +	unsigned int total_packets;
 +	unsigned int sample_packets;
 +	unsigned int sample_packets;
 +
 +
++	/* tx flags to add for frames for this sta */
++	u32 tx_flags;
++
 +	u8 sample_wait;
 +	u8 sample_wait;
 +	u8 sample_tries;
 +	u8 sample_tries;
 +	u8 sample_count;
 +	u8 sample_count;