Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 102887
Collapse All | Expand All

(-)../madwifi-cvs-20050814/ath/if_ath.c (-1 / +8 lines)
Lines 1435-1441 Link Here
1435
	rt = sc->sc_currates;
1435
	rt = sc->sc_currates;
1436
	KASSERT(rt != NULL, ("no rate table, mode %u", sc->sc_curmode));
1436
	KASSERT(rt != NULL, ("no rate table, mode %u", sc->sc_curmode));
1437
	flags = HAL_TXDESC_INTREQ | HAL_TXDESC_CLRDMASK;
1437
	flags = HAL_TXDESC_INTREQ | HAL_TXDESC_CLRDMASK;
1438
	try0 = ATH_TXMAXTRY;
1438
	try0 = (ic->ic_opmode == IEEE80211_M_MONITOR) ? 1 : ATH_TXMAXTRY;
1439
	dot11Rate = 0;
1439
	dot11Rate = 0;
1440
	ctsrate = 0;
1440
	ctsrate = 0;
1441
	ctsduration = 0;
1441
	ctsduration = 0;
Lines 1500-1505 Link Here
1500
		}
1500
		}
1501
	}
1501
	}
1502
1502
1503
	if (dot11Rate == 0 && ic->ic_opmode == IEEE80211_M_MONITOR) {
1504
		int index = sc->sc_rixmap[ic->inject_rate / 500];
1505
		if (index >= 0 && index < rt->rateCount) {
1506
			txrate = rt->info[index].rateCode;
1507
		}
1508
	}
1509
1503
	wh = (struct ieee80211_frame *) skb->data;
1510
	wh = (struct ieee80211_frame *) skb->data;
1504
	pktlen = skb->len + IEEE80211_CRC_LEN;
1511
	pktlen = skb->len + IEEE80211_CRC_LEN;
1505
	hdrlen = sizeof(struct ieee80211_frame);
1512
	hdrlen = sizeof(struct ieee80211_frame);
(-)../madwifi-cvs-20050814/Makefile.inc (-1 / +1 lines)
Lines 174-180 Link Here
174
#
174
#
175
#ATH_RATE=$(shell find ath_rate/ -maxdepth 1 ! -name CVS ! -name ath_rate/ -type d)
175
#ATH_RATE=$(shell find ath_rate/ -maxdepth 1 ! -name CVS ! -name ath_rate/ -type d)
176
ifeq ($(ATH_RATE),)
176
ifeq ($(ATH_RATE),)
177
ATH_RATE=ath_rate/sample
177
ATH_RATE=ath_rate/onoe
178
endif
178
endif
179
179
180
INCS=	-include ${obj}/${DEPTH}/include/compat.h -I${obj}/${DEPTH}/include
180
INCS=	-include ${obj}/${DEPTH}/include/compat.h -I${obj}/${DEPTH}/include
(-)../madwifi-cvs-20050814/net80211/ieee80211_crypto.c (+4 lines)
Lines 299-304 Link Here
299
299
300
	oflags = key->wk_flags;
300
	oflags = key->wk_flags;
301
	flags &= IEEE80211_KEY_COMMON;
301
	flags &= IEEE80211_KEY_COMMON;
302
303
	if (cipher == IEEE80211_CIPHER_WEP)
304
		flags |= IEEE80211_KEY_SWCRYPT;
305
302
	/*
306
	/*
303
	 * If the hardware does not support the cipher then
307
	 * If the hardware does not support the cipher then
304
	 * fallback to a host-based implementation.
308
	 * fallback to a host-based implementation.
(-)../madwifi-cvs-20050814/net80211/ieee80211_var.h (+2 lines)
Lines 207-212 Link Here
207
207
208
	struct timer_list	ic_radar_reanimate;	/* reanimation timer after stopping all channels after redar detection */
208
	struct timer_list	ic_radar_reanimate;	/* reanimation timer after stopping all channels after redar detection */
209
	u_int32_t ic_channelList[IEEE80211_CHAN_MAX];
209
	u_int32_t ic_channelList[IEEE80211_CHAN_MAX];
210
211
	int inject_rate;        /* injection rate in Monitor mode */
210
};
212
};
211
213
212
#define	IEEE80211_ADDR_EQ(a1,a2)	(memcmp(a1,a2,IEEE80211_ADDR_LEN) == 0)
214
#define	IEEE80211_ADDR_EQ(a1,a2)	(memcmp(a1,a2,IEEE80211_ADDR_LEN) == 0)
(-)../madwifi-cvs-20050814/net80211/ieee80211_wireless.c (+18 lines)
Lines 476-481 Link Here
476
	struct ifreq ifr;
476
	struct ifreq ifr;
477
	int rate;
477
	int rate;
478
478
479
	if (ic->ic_opmode == IEEE80211_M_MONITOR) {
480
		rate = rrq->value / 1000;
481
		if (rate !=  1000 && rate !=  2000 && rate !=  5500 &&
482
		    rate != 11000 && rate !=  6000 && rate !=  9000 &&
483
		    rate != 12000 && rate != 18000 && rate != 24000 &&
484
		    rate != 36000 && rate != 48000 && rate != 54000 )
485
		    return -EINVAL;
486
		printk(KERN_DEBUG "setting xmit rate to %d\n", rate);
487
		ic->inject_rate = rate;
488
		return 0;
489
	}
490
479
	if (!ic->ic_media.ifm_cur)
491
	if (!ic->ic_media.ifm_cur)
480
		return -EINVAL;
492
		return -EINVAL;
481
	memset(&ifr, 0, sizeof(ifr));
493
	memset(&ifr, 0, sizeof(ifr));
Lines 502-507 Link Here
502
	struct ifmediareq imr;
514
	struct ifmediareq imr;
503
	int rate;
515
	int rate;
504
516
517
	if (ic->ic_opmode == IEEE80211_M_MONITOR) {
518
		rrq->value = ic->inject_rate * 1000;
519
		return 0;
520
	}
521
505
	memset(&imr, 0, sizeof(imr));
522
	memset(&imr, 0, sizeof(imr));
506
	(*ic->ic_media.ifm_status)(ic->ic_dev, &imr);
523
	(*ic->ic_media.ifm_status)(ic->ic_dev, &imr);
507
524
Lines 942-947 Link Here
942
#if WIRELESS_EXT >= 15
959
#if WIRELESS_EXT >= 15
943
	case IW_MODE_MONITOR:
960
	case IW_MODE_MONITOR:
944
		ifr.ifr_media |= IFM_IEEE80211_MONITOR;
961
		ifr.ifr_media |= IFM_IEEE80211_MONITOR;
962
		ic->inject_rate = 5500; /* default = 5.5M CCK */
945
		break;
963
		break;
946
#endif
964
#endif
947
	default:
965
	default:

Return to bug 102887