Message ID | iwlwifi.20201129151117.70e3f540af9a.Idb157cfb560397421c184cbf54450d90f03bf7ec@changeid |
---|---|
State | New |
Headers | show |
Series | iwlwifi: updates intended for v5.11 2020-11-29 | expand |
On Sun, 2020-11-29 at 15:14 +0200, Luca Coelho wrote: > From: Emmanuel Grumbach <emmanuel.grumbach@intel.com> > > When we suspend, we can't really remember our BSS table. > Purge all the data. > Export this function to allow driver to purge the BSS table > in case they feel the need to. > iwlwifi will need to do that. > > Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> > Signed-off-by: Luca Coelho <luciano.coelho@intel.com> > --- This is obviously out of place and we already have an implementation for this upstream. Johannes dropped it. Sorry for the trouble. :( -- Luca.
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h index 661edfc8722e..67335a6a1816 100644 --- a/include/net/cfg80211.h +++ b/include/net/cfg80211.h @@ -8026,4 +8026,10 @@ void cfg80211_update_owe_info_event(struct net_device *netdev, */ void cfg80211_bss_flush(struct wiphy *wiphy); +/** + * cfg80211_bss_flush - resets all the scan entries + * @wiphy: the wiphy + */ +void cfg80211_bss_flush(struct wiphy *wiphy); + #endif /* __NET_CFG80211_H */ diff --git a/net/wireless/sysfs.c b/net/wireless/sysfs.c index 3ac1f48195d2..b670f0d78621 100644 --- a/net/wireless/sysfs.c +++ b/net/wireless/sysfs.c @@ -5,6 +5,7 @@ * * Copyright 2005-2006 Jiri Benc <jbenc@suse.cz> * Copyright 2006 Johannes Berg <johannes@sipsolutions.net> + * Copyright (C) 2020 Intel Corporation */ #include <linux/device.h> @@ -107,6 +108,7 @@ static int wiphy_suspend(struct device *dev) if (rdev->wiphy.registered) { if (!rdev->wiphy.wowlan_config) { cfg80211_leave_all(rdev); + cfg80211_bss_flush(&rdev->wiphy); cfg80211_process_rdev_events(rdev); } if (rdev->ops->suspend)