]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/net/wireless/ath/ath9k/hif_usb.c
ath9k_htc: reboot firmware if it was loaded
[karo-tx-linux.git] / drivers / net / wireless / ath / ath9k / hif_usb.c
index 2469db5a5bb1d638c8b3f5fcb74611d59fe89576..5205a3625e849f3f6d3d775bb7b4b8f866aebca4 100644 (file)
@@ -1295,7 +1295,9 @@ static void ath9k_hif_usb_disconnect(struct usb_interface *interface)
 
        usb_set_intfdata(interface, NULL);
 
-       if (!unplugged && (hif_dev->flags & HIF_USB_START))
+       /* If firmware was loaded we should drop it
+        * go back to first stage bootloader. */
+       if (!unplugged && (hif_dev->flags & HIF_USB_READY))
                ath9k_hif_usb_reboot(udev);
 
        kfree(hif_dev);