Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 7 Apr 2019 13:04:26 +0000 (UTC)
From:      Andriy Voskoboinyk <avos@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   svn commit: r346004 - in stable: 11/sys/dev/usb/wlan 12/sys/dev/usb/wlan
Message-ID:  <201904071304.x37D4QmL026903@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
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;
 	}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201904071304.x37D4QmL026903>