Gentoo Archives: gentoo-commits

From: "Peter Volkov (pva)" <pva@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-wireless/madwifi-ng/files: madwifi-ng-injection-r3925.patch
Date: Wed, 03 Jun 2009 12:17:27
Message-Id: E1MBpPG-0000v8-T7@stork.gentoo.org
1 pva 09/06/03 12:17:22
2
3 Added: madwifi-ng-injection-r3925.patch
4 Log:
5 Added missed injection patch, bug #272372, thank Pierre-Yves AILLET for report.
6 (Portage version: 2.2_rc33/cvs/Linux i686)
7
8 Revision Changes Path
9 1.1 net-wireless/madwifi-ng/files/madwifi-ng-injection-r3925.patch
10
11 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-wireless/madwifi-ng/files/madwifi-ng-injection-r3925.patch?rev=1.1&view=markup
12 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-wireless/madwifi-ng/files/madwifi-ng-injection-r3925.patch?rev=1.1&content-type=text/plain
13
14 Index: madwifi-ng-injection-r3925.patch
15 ===================================================================
16 === modified file 'ath/if_ath.c'
17 --- ath/if_ath.c 2009-06-03 07:46:17 +0000
18 +++ ath/if_ath.c 2009-06-03 07:53:24 +0000
19 @@ -2359,6 +2359,7 @@
20 ath_tx_startraw(struct net_device *dev, struct ath_buf *bf, struct sk_buff *skb)
21 {
22 struct ath_softc *sc = netdev_priv(dev);
23 + struct ieee80211com *ic = &sc->sc_ic;
24 struct ath_hal *ah = sc->sc_ah;
25 struct ieee80211_phy_params *ph = (struct ieee80211_phy_params *) (skb->cb + sizeof(struct ieee80211_cb));
26 const HAL_RATE_TABLE *rt;
27 @@ -2375,7 +2376,8 @@
28 struct ieee80211_frame *wh;
29
30 wh = (struct ieee80211_frame *) skb->data;
31 - try0 = ph->try0;
32 + //try0 = ph->try0;
33 + try0 = (ic->ic_opmode == IEEE80211_M_MONITOR) ? 1 : ph->try0;
34 rt = sc->sc_currates;
35 txrate = dot11_to_ratecode(sc, rt, ph->rate0);
36 power = ph->power > 60 ? 60 : ph->power;
37 @@ -2404,7 +2406,8 @@
38 KASSERT(rt != NULL, ("no rate table, mode %u", sc->sc_curmode));
39
40
41 - if (IEEE80211_IS_MULTICAST(wh->i_addr1)) {
42 + if (IEEE80211_IS_MULTICAST(wh->i_addr1) || ((ic->ic_opmode ==
43 + IEEE80211_M_MONITOR) && (skb->data[1]&3) != 0x01) ) {
44 flags |= HAL_TXDESC_NOACK; /* no ack on broad/multicast */
45 sc->sc_stats.ast_tx_noack++;
46 try0 = 1;