Skip to content

Commit

Permalink
ath6kl: Check sme state before delivering disconnect event to cfg80211
Browse files Browse the repository at this point in the history
 In some random cases, the firmware is sending two disconnect event to
 the host. In the current model, both diconnect events are passed to
 cfg80211 without checking local sme state machine, which is screwing
 cfg80211 layer state.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
  • Loading branch information
Raja Mani authored and Kalle Valo committed Aug 31, 2011
1 parent f91db9b commit 0e5cc8e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/wireless/ath/ath6kl/cfg80211.c
Original file line number Diff line number Diff line change
Expand Up @@ -643,7 +643,7 @@ void ath6kl_cfg80211_disconnect_event(struct ath6kl *ar, u8 reason,
NULL, 0,
WLAN_STATUS_UNSPECIFIED_FAILURE,
GFP_KERNEL);
} else {
} else if (ar->sme_state == SME_CONNECTED) {
cfg80211_disconnected(ar->net_dev, reason,
NULL, 0, GFP_KERNEL);
}
Expand Down

0 comments on commit 0e5cc8e

Please sign in to comment.