#798128 needs restarting after suspend if modules unloaded

Package:
wpasupplicant
Source:
wpa
Description:
client support for WPA and WPA2 (IEEE 802.11i)
Submitter:
Ian Jackson
Date:
2015-09-05 23:06:06 UTC
Severity:
minor
#798128#5
Date:
2015-09-05 22:54:29 UTC
From:
To:
Since I upgraded my netbook to jessie, the wifi does not work after
suspend.

Testing different versions of relevant software reveals that:
 * vanilla jessie does not work
 * reverting kernel or firmware-iwlwifi to wheezy makes no difference
 * reverting wpasupplicant to the .deb from wheezy (1.0-3+deb7u2)
   fixes the problem

When it's in the broken state, I get messages like those you see
below, in daemon.log.  I can work around the bug (until the next
suspend) with `killall wpa_supplicant'.  Network-Manager then restarts
wpa_supplicant and the restarted instance works.

In case it's relevant: the machine is a Dell Latitude 2120, with an
Intel `Advanced-N 6235' (according to lspci).  The access point is a
TP-Link; but I have seen the same symptoms at work using the corporate
wifi (not sure what the AP is there).

Sep  5 23:41:18 zealot NetworkManager[3119]: <info> Activation (wlan1) Stage 2 of 5 (Device Configure) complete.
Sep  5 23:41:18 zealot NetworkManager[3119]: <info> Config: set interface ap_scan to 1
Sep  5 23:41:18 zealot wpa_supplicant[15527]: wlan1: SME: Trying to authenticate with 64:70:02:72:af:5b (SSID='relativity' freq=2442 MHz)
Sep  5 23:41:18 zealot NetworkManager[3119]: <info> (wlan1): supplicant interface state: inactive -> authenticating
Sep  5 23:41:23 zealot wpa_supplicant[15527]: wlan1: SME: Deauth request to the driver failed
Sep  5 23:41:23 zealot NetworkManager[3119]: <info> (wlan1): supplicant interface state: authenticating -> disconnected
Sep  5 23:41:23 zealot NetworkManager[3119]: <info> (wlan1): supplicant interface state: disconnected -> scanning
Sep  5 23:41:33 zealot wpa_supplicant[15527]: wlan1: SME: Trying to authenticate with 64:70:02:72:af:5b (SSID='relativity' freq=2442 MHz)
Sep  5 23:41:33 zealot NetworkManager[3119]: <info> (wlan1): supplicant interface state: scanning -> authenticating
Sep  5 23:41:38 zealot wpa_supplicant[15527]: wlan1: SME: Deauth request to the driver failed
Sep  5 23:41:38 zealot NetworkManager[3119]: <info> (wlan1): supplicant interface state: authenticating -> disconnected
Sep  5 23:41:38 zealot NetworkManager[3119]: <info> (wlan1): supplicant interface state: disconnected -> scanning

#798128#12
Date:
2015-09-05 23:03:57 UTC
From:
To:
I wrote:

I have since discovered, while debugging another problem, that I had
this in /etc/pm/config.d/local to work around problems with wheezy (or
perhaps squeeze):

  SUSPEND_MODULES='uhci-hcd ehci-hcd cdc_acm cdc_wdm dell_laptop dcdbas mac80211 cfg80211 tg3 broadcom libphy'

Commenting that line out makes everything work even with wheezy's
wpasupplicant.  Simply unloading and reloading these modules with
modprobe doesn't seem to reproduce the bug.

I still think there is probably a bug or a race in wpasupplicant but
it may prove difficult to track down.  If you would like to give me
instructions, I'm happy to try experiments.

Thanks,
Ian.