ath9k_htc: reboot firmware if it was loaded
authorOleksij Rempel <linux@rempel-privat.de>
Fri, 19 Jul 2013 18:16:18 +0000 (20:16 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 12 Aug 2013 01:35:22 +0000 (18:35 -0700)
commite59f8a9d54603dcadbee294849988d1876d4bd38
treeeb99e4cf7c1444c9e6f65151f11c95711617a9b4
parent6edab054ac50f1c248eacf4d750dcbf5ff4f00b6
ath9k_htc: reboot firmware if it was loaded

commit 4928bd2ef8ece262f4f314630219999a91eaa440 upstream.

Currently ath9k_htc will reboot firmware only if interface was
ever started. Which lead to the problem in case where interface
was never started but module need to be reloaded.

This patch will partially fix bug "ath9k_htc: Target is unresponsive"
https://github.com/qca/open-ath9k-htc-firmware/issues/1

Reproduction case:
- plug adapter
- make sure nothing will touch it. Stop Networkmanager or blacklist mac address of this adapter.
- rmmod ath9k_htc; sleep 1; modprobe ath9k_htc

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/wireless/ath/ath9k/hif_usb.c