nexmon – Blame information for rev 1

Subversion Repositories:
Rev:
Rev Author Line No. Line
1 office 1 diff -ur madwifi-old/ath/if_ath.c patched_madwifi-old/ath/if_ath.c
2 --- madwifi-old/ath/if_ath.c 2006-03-22 21:31:58.814779008 +0100
3 +++ patched_madwifi-old/ath/if_ath.c 2006-03-22 21:35:10.049706880 +0100
4 @@ -1436,7 +1436,7 @@
5 rt = sc->sc_currates;
6 KASSERT(rt != NULL, ("no rate table, mode %u", sc->sc_curmode));
7 flags = HAL_TXDESC_INTREQ | HAL_TXDESC_CLRDMASK;
8 - try0 = ATH_TXMAXTRY;
9 + try0 = (ic->ic_opmode == IEEE80211_M_MONITOR) ? 1 : ATH_TXMAXTRY;
10 dot11Rate = 0;
11 ctsrate = 0;
12 ctsduration = 0;
13 @@ -1499,6 +1499,13 @@
14 if (index >= 0 && index < rt->rateCount) {
15 txrate = rt->info[index].rateCode;
16 }
17 + } else {
18 + if (ic->ic_opmode == IEEE80211_M_MONITOR) {
19 + int index = sc->sc_rixmap[ic->inject_rate / 500];
20 + if (index >= 0 && index < rt->rateCount) {
21 + txrate = rt->info[index].rateCode;
22 + }
23 + }
24 }
25  
26 wh = (struct ieee80211_frame *) skb->data;
27 diff -ur madwifi-old/ath/if_ath_pci.c patched_madwifi-old/ath/if_ath_pci.c
28 --- madwifi-old/ath/if_ath_pci.c 2006-03-22 21:31:58.799781288 +0100
29 +++ patched_madwifi-old/ath/if_ath_pci.c 2006-03-22 21:36:54.983754480 +0100
30 @@ -100,12 +100,16 @@
31 { 0xa727, 0x0013, PCI_ANY_ID, PCI_ANY_ID }, /* 3com */
32 { 0x10b7, 0x0013, PCI_ANY_ID, PCI_ANY_ID }, /* 3com 3CRDAG675 */
33 { 0x168c, 0x1014, PCI_ANY_ID, PCI_ANY_ID }, /* IBM minipci 5212 */
34 + { 0x168c, 0x101a, PCI_ANY_ID, PCI_ANY_ID }, /* some Griffin-Lite */
35 { 0x168c, 0x0015, PCI_ANY_ID, PCI_ANY_ID },
36 { 0x168c, 0x0016, PCI_ANY_ID, PCI_ANY_ID },
37 { 0x168c, 0x0017, PCI_ANY_ID, PCI_ANY_ID },
38 { 0x168c, 0x0018, PCI_ANY_ID, PCI_ANY_ID },
39 { 0x168c, 0x0019, PCI_ANY_ID, PCI_ANY_ID },
40 { 0x168c, 0x001a, PCI_ANY_ID, PCI_ANY_ID },
41 + { 0x168c, 0x001b, PCI_ANY_ID, PCI_ANY_ID },
42 + { 0x168c, 0x001c, PCI_ANY_ID, PCI_ANY_ID }, /* PCI Express 5424 */
43 + { 0x168c, 0x001d, PCI_ANY_ID, PCI_ANY_ID }, /* PCI Express ??? */
44 { 0 }
45 };
46  
47 diff -ur madwifi-old/net80211/ieee80211_crypto.c patched_madwifi-old/net80211/ieee80211_crypto.c
48 --- madwifi-old/net80211/ieee80211_crypto.c 2006-03-22 21:31:48.848294144 +0100
49 +++ patched_madwifi-old/net80211/ieee80211_crypto.c 2006-03-22 21:39:22.456335240 +0100
50 @@ -299,6 +299,11 @@
51  
52 oflags = key->wk_flags;
53 flags &= IEEE80211_KEY_COMMON;
54 +
55 + if (cipher == IEEE80211_CIPHER_WEP) {
56 + flags |= IEEE80211_KEY_SWCRYPT;
57 + }
58 +
59 /*
60 * If the hardware does not support the cipher then
61 * fallback to a host-based implementation.
62 diff -ur madwifi-old/net80211/ieee80211_var.h patched_madwifi-old/net80211/ieee80211_var.h
63 --- madwifi-old/net80211/ieee80211_var.h 2006-03-22 21:31:48.912284416 +0100
64 +++ patched_madwifi-old/net80211/ieee80211_var.h 2006-03-22 21:40:24.490904552 +0100
65 @@ -212,6 +212,8 @@
66 struct net_device *ic_wdsdev[IEEE80211_WDS_MAXNODES];
67 /* only wds traffic is allowed */
68 int ic_wdsonly;
69 +
70 + int inject_rate; /* injection rate in Monitor mode */
71 };
72  
73 #define IEEE80211_ADDR_EQ(a1,a2) (memcmp(a1,a2,IEEE80211_ADDR_LEN) == 0)
74 diff -ur madwifi-old/net80211/ieee80211_wireless.c patched_madwifi-old/net80211/ieee80211_wireless.c
75 --- madwifi-old/net80211/ieee80211_wireless.c 2006-03-22 21:31:48.880289280 +0100
76 +++ patched_madwifi-old/net80211/ieee80211_wireless.c 2006-03-22 21:47:46.026780896 +0100
77 @@ -476,6 +476,18 @@
78 struct ifreq ifr;
79 int rate;
80  
81 + if (ic->ic_opmode == IEEE80211_M_MONITOR) {
82 + rate = rrq->value / 1000;
83 + if (rate != 1000 && rate != 2000 && rate != 5500 &&
84 + rate != 11000 && rate != 6000 && rate != 9000 &&
85 + rate != 12000 && rate != 18000 && rate != 24000 &&
86 + rate != 36000 && rate != 48000 && rate != 54000 )
87 + return -EINVAL;
88 + printk(KERN_DEBUG "setting xmit rate to %d\n", rate);
89 + ic->inject_rate = rate;
90 + return 0;
91 + }
92 +
93 if (!ic->ic_media.ifm_cur)
94 return -EINVAL;
95 memset(&ifr, 0, sizeof(ifr));
96 @@ -502,6 +514,11 @@
97 struct ifmediareq imr;
98 int rate;
99  
100 + if (ic->ic_opmode == IEEE80211_M_MONITOR) {
101 + rrq->value = ic->inject_rate * 1000;
102 + return 0;
103 + }
104 +
105 memset(&imr, 0, sizeof(imr));
106 (*ic->ic_media.ifm_status)(ic->ic_dev, &imr);
107  
108 @@ -942,6 +959,7 @@
109 #if WIRELESS_EXT >= 15
110 case IW_MODE_MONITOR:
111 ifr.ifr_media |= IFM_IEEE80211_MONITOR;
112 + ic->inject_rate = 5500; /* default = 5.5M CCK */
113 break;
114 #endif
115 default: