svn commit: r345753 - head/sys/dev/usb/wlan
Andriy Voskoboinyk
avos at FreeBSD.org
Tue Sep 3 14:06:18 UTC 2019
Author: avos
Date: Sun Mar 31 13:41:20 2019
New Revision: 345753
URL: https://svnweb.freebsd.org/changeset/base/345753
Log:
run(4): do not clear PROTECTED bit if frame was not decrypted by NIC.
Tested with D-Link DWA-140 rev B3, STA / MONITOR modes.
MFC after: 1 week
Modified:
head/sys/dev/usb/wlan/if_run.c
Modified: head/sys/dev/usb/wlan/if_run.c
==============================================================================
--- head/sys/dev/usb/wlan/if_run.c Sun Mar 31 11:31:01 2019 (r345752)
+++ head/sys/dev/usb/wlan/if_run.c Sun Mar 31 13:41:20 2019 (r345753)
@@ -2865,8 +2865,8 @@ run_rx_frame(struct run_softc *sc, struct mbuf *m, uin
wh = mtod(m, struct ieee80211_frame *);
- /* XXX wrong for monitor mode */
- if (wh->i_fc[1] & IEEE80211_FC1_PROTECTED) {
+ if ((wh->i_fc[1] & IEEE80211_FC1_PROTECTED) != 0 &&
+ (flags & RT2860_RX_DEC) != 0) {
wh->i_fc[1] &= ~IEEE80211_FC1_PROTECTED;
m->m_flags |= M_WEP;
}
More information about the svn-src-all
mailing list