Support promiscuous mode for an AP too(!).

This commit is contained in:
mycroft 2004-07-22 18:52:44 +00:00
parent 7f3933adae
commit ff96f8f444
1 changed files with 4 additions and 5 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: ath.c,v 1.27 2004/05/31 11:39:39 dyoung Exp $ */
/* $NetBSD: ath.c,v 1.28 2004/07/22 18:52:44 mycroft Exp $ */
/*-
* Copyright (c) 2002-2004 Sam Leffler, Errno Consulting
@ -41,7 +41,7 @@
__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.54 2004/04/05 04:42:42 sam Exp $");
#endif
#ifdef __NetBSD__
__KERNEL_RCSID(0, "$NetBSD: ath.c,v 1.27 2004/05/31 11:39:39 dyoung Exp $");
__KERNEL_RCSID(0, "$NetBSD: ath.c,v 1.28 2004/07/22 18:52:44 mycroft Exp $");
#endif
/*
@ -1462,13 +1462,12 @@ ath_calcrxfilter(struct ath_softc *sc)
| HAL_RX_FILTER_UCAST | HAL_RX_FILTER_BCAST | HAL_RX_FILTER_MCAST;
if (ic->ic_opmode != IEEE80211_M_STA)
rfilt |= HAL_RX_FILTER_PROBEREQ;
if (ic->ic_opmode != IEEE80211_M_HOSTAP &&
(ifp->if_flags & IFF_PROMISC))
rfilt |= HAL_RX_FILTER_PROM;
if (ic->ic_opmode == IEEE80211_M_STA ||
ic->ic_opmode == IEEE80211_M_IBSS ||
ic->ic_state == IEEE80211_S_SCAN)
rfilt |= HAL_RX_FILTER_BEACON;
if (ifp->if_flags & IFF_PROMISC)
rfilt |= HAL_RX_FILTER_PROM;
return rfilt;
}