Skip to content

Commit

Permalink
iwlwifi: clear STATUS_SCAN_HW when PAN_PARAMS fails
Browse files Browse the repository at this point in the history
The STATUS_SCAN_HW is set before calling iwlagn_set_pan_params
(used as an input to calculate slot time allocation). The bit needs
to be cleared in case sending the command fails.

Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Ilan Peer <ilan.peer@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
  • Loading branch information
Ilan Peer authored and Johannes Berg committed Jun 6, 2012
1 parent 53e1116 commit 76a3aa8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion drivers/net/wireless/iwlwifi/iwl-scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -966,8 +966,10 @@ static int iwlagn_request_scan(struct iwl_priv *priv, struct ieee80211_vif *vif)
set_bit(STATUS_SCAN_HW, &priv->status);

ret = iwlagn_set_pan_params(priv);
if (ret)
if (ret) {
clear_bit(STATUS_SCAN_HW, &priv->status);
return ret;
}

ret = iwl_dvm_send_cmd(priv, &cmd);
if (ret) {
Expand Down

0 comments on commit 76a3aa8

Please sign in to comment.