aboutsummaryrefslogtreecommitdiffstats
path: root/net/wireless
diff options
context:
space:
mode:
authorArend van Spriel <arend@broadcom.com>2016-02-15 08:35:53 -0500
committerJohannes Berg <johannes.berg@intel.com>2016-02-23 04:41:24 -0500
commitb86071528f3261ab592fad5b9b1a02aea3dcabf3 (patch)
tree574a5f4de1d30e812a467e2ec0157ae183b0af1f /net/wireless
parent5e950a78bf5b18ded277a27aed0bcdbe7c1b868a (diff)
cfg80211: stop critical protocol session upon disconnect event
When user-space has started a critical protocol session and a disconnect event occurs, the rdev::crit_prot_nlportid remains set. This caused a subsequent NL80211_CMD_CRIT_PROTO_START to fail (-EBUSY). Fix this by clearing the rdev attribute and call .crit_proto_stop() callback upon disconnect event. Reviewed-by: Hante Meuleman <meuleman@broadcom.com> Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com> Signed-off-by: Arend van Spriel <arend@broadcom.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless')
-rw-r--r--net/wireless/sme.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/net/wireless/sme.c b/net/wireless/sme.c
index 8020b5b094d4..d49ed7666d4c 100644
--- a/net/wireless/sme.c
+++ b/net/wireless/sme.c
@@ -917,6 +917,12 @@ void __cfg80211_disconnected(struct net_device *dev, const u8 *ie,
917 917
918 nl80211_send_disconnected(rdev, dev, reason, ie, ie_len, from_ap); 918 nl80211_send_disconnected(rdev, dev, reason, ie, ie_len, from_ap);
919 919
920 /* stop critical protocol if supported */
921 if (rdev->ops->crit_proto_stop && rdev->crit_proto_nlportid) {
922 rdev->crit_proto_nlportid = 0;
923 rdev_crit_proto_stop(rdev, wdev);
924 }
925
920 /* 926 /*
921 * Delete all the keys ... pairwise keys can't really 927 * Delete all the keys ... pairwise keys can't really
922 * exist any more anyway, but default keys might. 928 * exist any more anyway, but default keys might.