Patchwork [3.5.y.z,extended,stable] Patch "mac80211: don't send null data packet when not associated" has been added to staging queue

mail settings
Submitter Herton Ronaldo Krzesinski
Date Dec. 7, 2012, 4:04 p.m.
Message ID <>
Download mbox | patch
Permalink /patch/204544/
State New
Headers show


Herton Ronaldo Krzesinski - Dec. 7, 2012, 4:04 p.m.
This is a note to let you know that I have just added a patch titled

    mac80211: don't send null data packet when not associated

to the linux-3.5.y-queue branch of the 3.5.y.z extended stable tree 
which can be found at:;a=shortlog;h=refs/heads/linux-3.5.y-queue

If you, or anyone else, feels it should not be added to this tree, please 
reply to this email.

For more information about the 3.5.y.z tree, see



From 8f6e2ef15b1a9e55ef9796272e4015bcbd2d0f3a Mon Sep 17 00:00:00 2001
From: Johannes Berg <>
Date: Thu, 8 Nov 2012 14:06:28 +0100
Subject: [PATCH] mac80211: don't send null data packet when not associated

commit 20f544eea03db4b498942558b882d463ce575c3e upstream.

On resume or firmware recovery, mac80211 sends a null
data packet to see if the AP is still around and hasn't
disconnected us. However, it always does this even if
it wasn't even connected before, leading to a warning
in the new channel context code. Fix this by checking
that it's associated.

Reviewed-by: Emmanuel Grumbach <>
Signed-off-by: Johannes Berg <>
Signed-off-by: Herton Ronaldo Krzesinski <>
 net/mac80211/util.c |    2 ++
 1 file changed, 2 insertions(+)



diff --git a/net/mac80211/util.c b/net/mac80211/util.c
index 9ff0a85..4d83d11 100644
--- a/net/mac80211/util.c
+++ b/net/mac80211/util.c
@@ -1400,6 +1400,8 @@  int ieee80211_reconfig(struct ieee80211_local *local)
 		list_for_each_entry(sdata, &local->interfaces, list) {
 			if (sdata->vif.type != NL80211_IFTYPE_STATION)
+			if (!sdata->u.mgd.associated)
+				continue;

 			ieee80211_send_nullfunc(local, sdata, 0);