From: Simon Wunderlich Date: Thu, 21 Nov 2013 17:19:53 +0000 (+0100) Subject: mac80211: don't leak next beacon when csa is aborted X-Git-Tag: v3.14-rc1~94^2~3^2^2~223 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1f3b8a2bdeccac8abe6817b7b70cea90c93ed3e4;p=platform%2Fkernel%2Flinux-exynos.git mac80211: don't leak next beacon when csa is aborted Signed-off-by: Simon Wunderlich Signed-off-by: Johannes Berg --- diff --git a/net/mac80211/cfg.c b/net/mac80211/cfg.c index a66f4f1eb860..754069cbb756 100644 --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c @@ -1080,6 +1080,9 @@ static int ieee80211_stop_ap(struct wiphy *wiphy, struct net_device *dev) /* abort any running channel switch */ sdata->vif.csa_active = false; + kfree(sdata->u.ap.next_beacon); + sdata->u.ap.next_beacon = NULL; + cancel_work_sync(&sdata->u.ap.request_smps_work); /* turn off carrier for this interface and dependent VLANs */