* [PATCH 1/2] mac80211: allow to support AP_LINK_PS when the set_tim is still needed
@ 2016-09-15 13:30 Luca Coelho
2016-09-15 13:30 ` [PATCH 2/2] mac80211_hwsim: statically initialize hwsim_radios list Luca Coelho
2016-09-16 12:50 ` [PATCH 1/2] mac80211: allow to support AP_LINK_PS when the set_tim is still needed Johannes Berg
0 siblings, 2 replies; 3+ messages in thread
From: Luca Coelho @ 2016-09-15 13:30 UTC (permalink / raw)
To: johannes; +Cc: linux-wireless, Emmanuel Grumbach, Luca Coelho
From: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
In 46fa38e84b656f80edf83d21144221b0cad18d61, Johannes
allowed to use mac80211's code for handling stations
that go to PS or send PS-Poll / uAPSD trigger frames
for devices that enable RSS.
This means that mac80211 doesn't look at frames anymore
but rather relies on a notification that will come from
the device when a PS transition occurs or when a
PS-Poll / trigger frame is detected by the firmware.
iwlwifi will need this capability but still needs mac80211
to take care of the TIM IE. Today, if a driver sets
AP_LINK_PS, mac80211 will not update the TIM IE.
Change mac80211 to look at the set_tim driver callback
rather than AP_LINK_PS to decide if the driver handles
the TIM IE internally or not.
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
---
net/mac80211/sta_info.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/mac80211/sta_info.c b/net/mac80211/sta_info.c
index 5e70fa5..1b1b28f 100644
--- a/net/mac80211/sta_info.c
+++ b/net/mac80211/sta_info.c
@@ -690,7 +690,7 @@ static void __sta_info_recalc_tim(struct sta_info *sta, bool ignore_pending)
}
/* No need to do anything if the driver does all */
- if (ieee80211_hw_check(&local->hw, AP_LINK_PS))
+ if (!local->ops->set_tim)
return;
if (sta->dead)
--
2.9.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 2/2] mac80211_hwsim: statically initialize hwsim_radios list
2016-09-15 13:30 [PATCH 1/2] mac80211: allow to support AP_LINK_PS when the set_tim is still needed Luca Coelho
@ 2016-09-15 13:30 ` Luca Coelho
2016-09-16 12:50 ` [PATCH 1/2] mac80211: allow to support AP_LINK_PS when the set_tim is still needed Johannes Berg
1 sibling, 0 replies; 3+ messages in thread
From: Luca Coelho @ 2016-09-15 13:30 UTC (permalink / raw)
To: johannes; +Cc: linux-wireless, Johannes Berg
From: Johannes Berg <johannes.berg@intel.com>
There's no need to initialize at runtime, when the static
declaration macro can just be used instead, so do that.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
drivers/net/wireless/mac80211_hwsim.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c
index 8c35ac8..431f13b 100644
--- a/drivers/net/wireless/mac80211_hwsim.c
+++ b/drivers/net/wireless/mac80211_hwsim.c
@@ -487,7 +487,7 @@ static const struct ieee80211_iface_combination hwsim_if_comb_p2p_dev[] = {
};
static spinlock_t hwsim_radio_lock;
-static struct list_head hwsim_radios;
+static LIST_HEAD(hwsim_radios);
static int hwsim_radio_idx;
static struct platform_driver mac80211_hwsim_driver = {
@@ -3376,7 +3376,6 @@ static int __init init_mac80211_hwsim(void)
mac80211_hwsim_unassign_vif_chanctx;
spin_lock_init(&hwsim_radio_lock);
- INIT_LIST_HEAD(&hwsim_radios);
err = register_pernet_device(&hwsim_net_ops);
if (err)
--
2.9.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/2] mac80211: allow to support AP_LINK_PS when the set_tim is still needed
2016-09-15 13:30 [PATCH 1/2] mac80211: allow to support AP_LINK_PS when the set_tim is still needed Luca Coelho
2016-09-15 13:30 ` [PATCH 2/2] mac80211_hwsim: statically initialize hwsim_radios list Luca Coelho
@ 2016-09-16 12:50 ` Johannes Berg
1 sibling, 0 replies; 3+ messages in thread
From: Johannes Berg @ 2016-09-16 12:50 UTC (permalink / raw)
To: Luca Coelho; +Cc: linux-wireless, Emmanuel Grumbach, Luca Coelho
Both applied.
johannes
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-09-16 12:50 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-09-15 13:30 [PATCH 1/2] mac80211: allow to support AP_LINK_PS when the set_tim is still needed Luca Coelho
2016-09-15 13:30 ` [PATCH 2/2] mac80211_hwsim: statically initialize hwsim_radios list Luca Coelho
2016-09-16 12:50 ` [PATCH 1/2] mac80211: allow to support AP_LINK_PS when the set_tim is still needed Johannes Berg
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).