Package: broadcom-sta-dkms
Version: 6.30.223.271-4

Current behaviour:
Upon system resume, NetworkManager will try to reconnect to the configured
network but prompts for the network's password. Even if the password is
inputted, it will fail to connect. This happens frquently when the system
has been suspended for some hours.

Expected behaviour:
Upon system resume, NetworkManger should reconnect to the configured network,
in use before suspending the system, without user intervention.

I am using te debian Linux kernel 4.7 package, and it also happened with 4.6
> uname -a
Linux mini 4.7.0-1-amd64 #1 SMP Debian 4.7.8-1 (2016-10-19) x86_64 GNU/Linux

When this issue happens a warning is printed to the kernel log.

[  147.523041] ------------[ cut here ]------------
[  147.523066] WARNING: CPU: 1 PID: 3725 at
/build/linux-hw0LPm/linux-4.7.8/net/wireless/sme.c:726
__cfg80211_connect_result+0x3b6/0x420 [cfg80211]
[  147.523067] Modules linked in: cpufreq_conservative
cpufreq_powersave cpufreq_userspace cpufreq_stats bnep nls_ascii btusb
nls_cp437 btrtl btbcm btintel bluetooth vfat fat iTCO_wdt
iTCO_vendor_support wl(POE) cfg80211 intel_rapl x86_pkg_temp_thermal
intel_powerclamp coretemp kvm_intel rfkill kvm irqbypass applesmc
crct10dif_pclmul input_polldev crc32_pclmul thunderbolt
ghash_clmulni_intel snd_hda_codec_hdmi sg pcspkr snd_hda_codec_cirrus
snd_hda_codec_generic snd_hda_intel snd_hda_codec snd_hda_core
snd_hwdep snd_pcm efi_pstore evdev mei_me snd_timer snd shpchp mei
lpc_ich mfd_core soundcore i2c_i801 tpm_tis tpm efivars ftdi_sio
usbserial loop ecryptfs cbc sunrpc hmac encrypted_keys parport_pc
ppdev lp parport efivarfs ip_tables x_tables autofs4 ext4 ecb crc16
jbd2 crc32c_generic mbcache hid_generic
[  147.523111]  hid_appleir usbhid hid sd_mod crc32c_intel aesni_intel
ahci libahci aes_x86_64 glue_helper lrw gf128mul ablk_helper libata
cryptd scsi_mod i915 xhci_pci xhci_hcd i2c_algo_bit drm_kms_helper
sdhci_pci tg3 usbcore sdhci ptp mmc_core pps_core usb_common libphy
drm fjes video button
[  147.523132] CPU: 1 PID: 3725 Comm: kworker/u16:39 Tainted: P
   OE   4.7.0-1-amd64 #1 Debian 4.7.8-1
[  147.523134] Hardware name: Apple Inc.
Macmini7,1/Mac-35C5E08120C7EEAF, BIOS MM71.88Z.0220.B00.1409291751
09/29/2014
[  147.523146] Workqueue: cfg80211 cfg80211_event_work [cfg80211]
[  147.523148]  0000000000000286 00000000df488c73 ffffffffa891a245
0000000000000000
[  147.523151]  0000000000000000 ffffffffa867a03e ffff88026441a400
ffff880086d67da8
[  147.523153]  0000000000000000 0000000000000000 ffff880261b89000
ffff8800889d0018
[  147.523156] Call Trace:
[  147.523160]  [<ffffffffa891a245>] ? dump_stack+0x5c/0x77
[  147.523164]  [<ffffffffa867a03e>] ? __warn+0xbe/0xe0
[  147.523177]  [<ffffffffc09868b6>] ?
__cfg80211_connect_result+0x3b6/0x420 [cfg80211]
[  147.523204]  [<ffffffffc03a33ab>] ?
i915_gem_object_ggtt_unpin_view+0x2b/0xa0 [i915]
[  147.523215]  [<ffffffffc095e5ad>] ?
cfg80211_process_wdev_events+0x11d/0x190 [cfg80211]
[  147.523227]  [<ffffffffc095e652>] ?
cfg80211_process_rdev_events+0x32/0x70 [cfg80211]
[  147.523237]  [<ffffffffc095901a>] ? cfg80211_event_work+0x1a/0x20 [cfg80211]
[  147.523239]  [<ffffffffa8692900>] ? process_one_work+0x160/0x410
[  147.523241]  [<ffffffffa8692bfd>] ? worker_thread+0x4d/0x480
[  147.523243]  [<ffffffffa8692bb0>] ? process_one_work+0x410/0x410
[  147.523246]  [<ffffffffa8698a1d>] ? kthread+0xcd/0xf0
[  147.523248]  [<ffffffffa8bdc4ef>] ? ret_from_fork+0x1f/0x40
[  147.523250]  [<ffffffffa8698950>] ? kthread_create_on_node+0x190/0x190
[  147.523252] ---[ end trace 691fdb2f0f364a42 ]---


When NetworkManager prompts for the password and I press 'Cancel' it will try
to connect to a different configured network, printing the following warning.

[  160.310417] ------------[ cut here ]------------
[  160.310463] WARNING: CPU: 2 PID: 1940 at
/build/linux-hw0LPm/linux-4.7.8/net/wireless/sme.c:878
wl_notify_roaming_status+0xb6/0x130 [wl]
[  160.310464] Modules linked in: cpufreq_conservative
cpufreq_powersave cpufreq_userspace cpufreq_stats bnep nls_ascii btusb
nls_cp437 btrtl btbcm btintel bluetooth vfat fat iTCO_wdt
iTCO_vendor_support wl(POE) cfg80211 intel_rapl x86_pkg_temp_thermal
intel_powerclamp coretemp kvm_intel rfkill kvm irqbypass applesmc
crct10dif_pclmul input_polldev crc32_pclmul thunderbolt
ghash_clmulni_intel snd_hda_codec_hdmi sg pcspkr snd_hda_codec_cirrus
snd_hda_codec_generic snd_hda_intel snd_hda_codec snd_hda_core
snd_hwdep snd_pcm efi_pstore evdev mei_me snd_timer snd shpchp mei
lpc_ich mfd_core soundcore i2c_i801 tpm_tis tpm efivars ftdi_sio
usbserial loop ecryptfs cbc sunrpc hmac encrypted_keys parport_pc
ppdev lp parport efivarfs ip_tables x_tables autofs4 ext4 ecb crc16
jbd2 crc32c_generic mbcache hid_generic
[  160.310497]  hid_appleir usbhid hid sd_mod crc32c_intel aesni_intel
ahci libahci aes_x86_64 glue_helper lrw gf128mul ablk_helper libata
cryptd scsi_mod i915 xhci_pci xhci_hcd i2c_algo_bit drm_kms_helper
sdhci_pci tg3 usbcore sdhci ptp mmc_core pps_core usb_common libphy
drm fjes video button
[  160.310513] CPU: 2 PID: 1940 Comm: wl_event_handle Tainted: P
 W  OE   4.7.0-1-amd64 #1 Debian 4.7.8-1
[  160.310515] Hardware name: Apple Inc.
Macmini7,1/Mac-35C5E08120C7EEAF, BIOS MM71.88Z.0220.B00.1409291751
09/29/2014
[  160.310516]  0000000000000286 00000000dc5a1a29 ffffffffa891a245
0000000000000000
[  160.310518]  0000000000000000 ffffffffa867a03e ffff88026126d720
ffff88023eb3fd14
[  160.310520]  ffff88026126df3a ffff880261b89000 ffff88026126db18
ffff88026f2d6d80
[  160.310521] Call Trace:
[  160.310526]  [<ffffffffa891a245>] ? dump_stack+0x5c/0x77
[  160.310530]  [<ffffffffa867a03e>] ? __warn+0xbe/0xe0
[  160.310556]  [<ffffffffc0b989d6>] ? wl_notify_roaming_status+0xb6/0x130 [wl]
[  160.310579]  [<ffffffffc0b980a8>] ? wl_event_handler+0x58/0x1a0 [wl]
[  160.310605]  [<ffffffffc0b98050>] ? wl_notify_scan_status+0x310/0x310 [wl]
[  160.310608]  [<ffffffffa8698a1d>] ? kthread+0xcd/0xf0
[  160.310610]  [<ffffffffa8bdc4ef>] ? ret_from_fork+0x1f/0x40
[  160.310612]  [<ffffffffa8698950>] ? kthread_create_on_node+0x190/0x190
[  160.310614] ---[ end trace 691fdb2f0f364a43 ]---


Attached is a proposal patch with the solution, which I have tested
satisfactorily for a week.

--
Luis Ortega Pérez de Villar
--- a/amd64/src/wl/sys/wl_cfg80211_hybrid.c
+++ b/amd64/src/wl/sys/wl_cfg80211_hybrid.c
@@ -2021,13 +2021,6 @@
 		mgmt->u.beacon.capab_info, &bi->BSSID));
 
 	signal = notif_bss_info->rssi * 100;
-	cbss = cfg80211_inform_bss_frame(wiphy, channel, mgmt,
-	    le16_to_cpu(notif_bss_info->frame_len), signal, GFP_KERNEL);
-	if (unlikely(!cbss)) {
-		WL_ERR(("cfg80211_inform_bss_frame error\n"));
-		kfree(notif_bss_info);
-		return -EINVAL;
-	}
 
 	notify_ie = (u8 *)bi + le16_to_cpu(bi->ie_offset);
 	notify_ielen = le32_to_cpu(bi->ie_length);

Reply via email to