mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-09-03 12:50:13 +03:00
mac80211/ath9k: fix duration calculation for short-guard-interval frames (thanks to Duy Nguyen for pointing this out)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@20114 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
df65c7217b
commit
1c152af974
@ -100,7 +100,7 @@
|
|||||||
+/* Transmission time for a packet containing (syms) symbols */
|
+/* Transmission time for a packet containing (syms) symbols */
|
||||||
+#define MCS_SYMBOL_TIME(sgi, syms) \
|
+#define MCS_SYMBOL_TIME(sgi, syms) \
|
||||||
+ (sgi ? \
|
+ (sgi ? \
|
||||||
+ ((syms) * 18 + 4) / 5 : /* syms * 3.6 us */ \
|
+ ((syms) * 18 + 4) / 6 : /* syms * 3.6 us */ \
|
||||||
+ (syms) << 2 /* syms * 4 us */ \
|
+ (syms) << 2 /* syms * 4 us */ \
|
||||||
+ )
|
+ )
|
||||||
+
|
+
|
||||||
|
@ -0,0 +1,14 @@
|
|||||||
|
--- a/drivers/net/wireless/ath/ath9k/xmit.c
|
||||||
|
+++ b/drivers/net/wireless/ath/ath9k/xmit.c
|
||||||
|
@@ -27,9 +27,9 @@
|
||||||
|
#define HT_STF 4
|
||||||
|
#define HT_LTF(_ns) (4 * (_ns))
|
||||||
|
#define SYMBOL_TIME(_ns) ((_ns) << 2) /* ns * 4 us */
|
||||||
|
-#define SYMBOL_TIME_HALFGI(_ns) (((_ns) * 18 + 4) / 5) /* ns * 3.6 us */
|
||||||
|
+#define SYMBOL_TIME_HALFGI(_ns) (((_ns) * 18 + 4) / 6) /* ns * 3.6 us */
|
||||||
|
#define NUM_SYMBOLS_PER_USEC(_usec) (_usec >> 2)
|
||||||
|
-#define NUM_SYMBOLS_PER_USEC_HALFGI(_usec) (((_usec*5)-4)/18)
|
||||||
|
+#define NUM_SYMBOLS_PER_USEC_HALFGI(_usec) (((_usec*6)-4)/18)
|
||||||
|
|
||||||
|
#define OFDM_SIFS_TIME 16
|
||||||
|
|
Loading…
Reference in New Issue
Block a user