From: Emmanuel Grumbach Date: Mon, 24 Jun 2013 12:44:03 +0000 (+0300) Subject: iwlwifi: mvm: unregister leds when registration failed X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=b7327d89ae694a89f9934d428bde520b77b3131c;p=openwrt%2Fstaging%2Fblogic.git iwlwifi: mvm: unregister leds when registration failed This was missing and prevented any further attempts to load the module. Signed-off-by: Emmanuel Grumbach Signed-off-by: Johannes Berg --- diff --git a/drivers/net/wireless/iwlwifi/mvm/mac80211.c b/drivers/net/wireless/iwlwifi/mvm/mac80211.c index e08683b20531..cab2f0c61ec7 100644 --- a/drivers/net/wireless/iwlwifi/mvm/mac80211.c +++ b/drivers/net/wireless/iwlwifi/mvm/mac80211.c @@ -257,7 +257,11 @@ int iwl_mvm_mac_setup_register(struct iwl_mvm *mvm) if (ret) return ret; - return ieee80211_register_hw(mvm->hw); + ret = ieee80211_register_hw(mvm->hw); + if (ret) + iwl_mvm_leds_exit(mvm); + + return ret; } static void iwl_mvm_mac_tx(struct ieee80211_hw *hw,