svn commit: r346004 - in stable: 11/sys/dev/usb/wlan 12/sys/dev/usb/wlan

Andriy Voskoboinyk avos at FreeBSD.org
Tue Sep 3 14:06:52 UTC 2019


Author: avos
Date: Sun Apr  7 13:04:25 2019
New Revision: 346004
URL: https://svnweb.freebsd.org/changeset/base/346004

Log:
  MFC r345753:
  run(4): do not clear PROTECTED bit if frame was not decrypted by NIC.
  
  Was tested with D-Link DWA-140 rev B3, STA / MONITOR modes.

Modified:
  stable/11/sys/dev/usb/wlan/if_run.c
Directory Properties:
  stable/11/   (props changed)

Changes in other areas also in this revision:
Modified:
  stable/12/sys/dev/usb/wlan/if_run.c
Directory Properties:
  stable/12/   (props changed)

Modified: stable/11/sys/dev/usb/wlan/if_run.c
==============================================================================
--- stable/11/sys/dev/usb/wlan/if_run.c	Sun Apr  7 12:57:38 2019	(r346003)
+++ stable/11/sys/dev/usb/wlan/if_run.c	Sun Apr  7 13:04:25 2019	(r346004)
@@ -2796,8 +2796,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