]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
mac80211: properly flush delayed scan work on interface removal
authorJohannes Berg <johannes@sipsolutions.net>
Tue, 21 Oct 2014 18:56:42 +0000 (20:56 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 21 Nov 2014 17:23:10 +0000 (09:23 -0800)
commit17aa0867363317a05c50fc20408e33cc02af8bef
tree1a289a659e8f7fcddf99282a32f0c0e6b565fb15
parente9bc3ea125989e71add4969d6cbbb835935c3ff6
mac80211: properly flush delayed scan work on interface removal

commit 46238845bd609a5c0fbe076e1b82b4c5b33360b2 upstream.

When an interface is deleted, an ongoing hardware scan is canceled and
the driver must abort the scan, at the very least reporting completion
while the interface is removed.

However, if it scheduled the work that might only run after everything
is said and done, which leads to cfg80211 warning that the scan isn't
reported as finished yet; this is no fault of the driver, it already
did, but mac80211 hasn't processed it.

To fix this situation, flush the delayed work when the interface being
removed is the one that was executing the scan.

Reported-by: Sujith Manoharan <sujith@msujith.org>
Tested-by: Sujith Manoharan <sujith@msujith.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/mac80211/iface.c