PERFORCE change 87256 for review

Sam Leffler sam at FreeBSD.org
Sat Nov 26 06:33:06 GMT 2005


http://perforce.freebsd.org/chv.cgi?CH=87256

Change 87256 by sam at sam_ebb on 2005/11/26 06:32:13

	honor pwr sav state; cancel bg scan on xmit when in pwr save mode

Affected files ...

.. //depot/projects/wifi/sys/dev/ral/if_ral.c#13 edit

Differences ...

==== //depot/projects/wifi/sys/dev/ral/if_ral.c#13 (text+ko) ====

@@ -2093,6 +2093,26 @@
 				m_freem(m0);
 				continue;
 			}
+			if ((ni->ni_flags & IEEE80211_NODE_PWR_MGT) &&
+			    (m0->m_flags & M_PWR_SAV) == 0) {
+				/*
+				 * Station in power save mode; pass the frame
+				 * to the 802.11 layer and continue.  We'll get
+				 * the frame back when the time is right.
+				 */
+				ieee80211_pwrsave(ni, m0);
+				/*
+				 * If we're in power save mode 'cuz of a bg
+				 * scan cancel it so the traffic can flow.
+				 * The packet we just queued will automatically
+				 * get sent when we drop out of power save.
+				 * XXX locking
+				 */
+				if (ic->ic_flags & IEEE80211_F_SCAN)
+					ieee80211_cancel_scan(ic);
+				ieee80211_free_node(ni);
+				continue;
+			}
 			BPF_MTAP(ifp, m0);
 
 			m0 = ieee80211_encap(ic, m0, ni);


More information about the p4-projects mailing list