Commit 9f4bc8cf authored by Larry Finger's avatar Larry Finger Committed by Greg Kroah-Hartman

staging: r8712u: Fix regression introduced by commit a5ee6529

In commit a5ee6529 "staging: r8712u: Interface-state not fully tracked",
the private boolean "bup" was set false when the interface was brought down,
as that seemed appropriate. This change has not caused any problems when
using NetworkManager or manual control of the device; however, when wicd
control is used, there is a locking problem in wpa_supplicant, as shown in
https://bugzilla.kernel.org/show_bug.cgi?id=42818.

This fix reverts the only code change in commit a5ee6529. My
analysis is that "bup" is badly named. In its present form, it
seems to indicate the up/down state of the device, but its usage
is more consistent with an initialized/uninitialized state. That
problem will be addressed in a later patch.

Note: Commit 8c213fa, which introdued asynchronous firmware loading
for this driver, exposed this bug to a greater extent. That bug
is addressed in the next patch in this series.

This bug is also responsible for the bug in
https://bugzilla.kernel.org/show_bug.cgi?id=42815. and this bug is
also part of the problems discussed at https://bugs.archlinux.org/task/27996#comment89950.
Tested-by: default avatarAlberto Lago Ballesteros <saniukeokusainaya@gmail.com>
Tested-by: default avatarAdrian <agib@gmx.de>
Signed-off-by: default avatarLarry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org> [3.2+]
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 625aeb3a
...@@ -475,8 +475,6 @@ static int netdev_close(struct net_device *pnetdev) ...@@ -475,8 +475,6 @@ static int netdev_close(struct net_device *pnetdev)
r8712_free_assoc_resources(padapter); r8712_free_assoc_resources(padapter);
/*s2-4.*/ /*s2-4.*/
r8712_free_network_queue(padapter); r8712_free_network_queue(padapter);
/* The interface is no longer Up: */
padapter->bup = false;
release_firmware(padapter->fw); release_firmware(padapter->fw);
/* never exit with a firmware callback pending */ /* never exit with a firmware callback pending */
wait_for_completion(&padapter->rtl8712_fw_ready); wait_for_completion(&padapter->rtl8712_fw_ready);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment