diff options
author | Johannes Berg <johannes.berg@intel.com> | 2013-06-03 11:25:34 -0400 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2013-06-03 12:43:34 -0400 |
commit | 964dc9e2c3aaccacacd40640964a58544fb5769a (patch) | |
tree | 3457e7dfc23df7d2477b57d346886031cb7361d9 /drivers/net/wireless/ath/ath6kl | |
parent | e05ecccdf752122a439b03c3190458d2c8f0bac6 (diff) |
cfg80211: take WoWLAN support information out of wiphy struct
There's no need to take up the space for devices that don't
support WoWLAN, and most drivers can even make the support
data static const (except where it's modified at runtime.)
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath6kl')
-rw-r--r-- | drivers/net/wireless/ath/ath6kl/cfg80211.c | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/drivers/net/wireless/ath/ath6kl/cfg80211.c b/drivers/net/wireless/ath/ath6kl/cfg80211.c index 5c9736a94e54..f7995b2b12a4 100644 --- a/drivers/net/wireless/ath/ath6kl/cfg80211.c +++ b/drivers/net/wireless/ath/ath6kl/cfg80211.c | |||
@@ -3679,6 +3679,20 @@ err: | |||
3679 | return NULL; | 3679 | return NULL; |
3680 | } | 3680 | } |
3681 | 3681 | ||
3682 | #ifdef CONFIG_PM | ||
3683 | static const struct wiphy_wowlan_support ath6kl_wowlan_support = { | ||
3684 | .flags = WIPHY_WOWLAN_MAGIC_PKT | | ||
3685 | WIPHY_WOWLAN_DISCONNECT | | ||
3686 | WIPHY_WOWLAN_GTK_REKEY_FAILURE | | ||
3687 | WIPHY_WOWLAN_SUPPORTS_GTK_REKEY | | ||
3688 | WIPHY_WOWLAN_EAP_IDENTITY_REQ | | ||
3689 | WIPHY_WOWLAN_4WAY_HANDSHAKE, | ||
3690 | .n_patterns = WOW_MAX_FILTERS_PER_LIST, | ||
3691 | .pattern_min_len = 1, | ||
3692 | .pattern_max_len = WOW_PATTERN_SIZE, | ||
3693 | }; | ||
3694 | #endif | ||
3695 | |||
3682 | int ath6kl_cfg80211_init(struct ath6kl *ar) | 3696 | int ath6kl_cfg80211_init(struct ath6kl *ar) |
3683 | { | 3697 | { |
3684 | struct wiphy *wiphy = ar->wiphy; | 3698 | struct wiphy *wiphy = ar->wiphy; |
@@ -3772,15 +3786,7 @@ int ath6kl_cfg80211_init(struct ath6kl *ar) | |||
3772 | wiphy->n_cipher_suites = ARRAY_SIZE(cipher_suites); | 3786 | wiphy->n_cipher_suites = ARRAY_SIZE(cipher_suites); |
3773 | 3787 | ||
3774 | #ifdef CONFIG_PM | 3788 | #ifdef CONFIG_PM |
3775 | wiphy->wowlan.flags = WIPHY_WOWLAN_MAGIC_PKT | | 3789 | wiphy->wowlan = &ath6kl_wowlan_support; |
3776 | WIPHY_WOWLAN_DISCONNECT | | ||
3777 | WIPHY_WOWLAN_GTK_REKEY_FAILURE | | ||
3778 | WIPHY_WOWLAN_SUPPORTS_GTK_REKEY | | ||
3779 | WIPHY_WOWLAN_EAP_IDENTITY_REQ | | ||
3780 | WIPHY_WOWLAN_4WAY_HANDSHAKE; | ||
3781 | wiphy->wowlan.n_patterns = WOW_MAX_FILTERS_PER_LIST; | ||
3782 | wiphy->wowlan.pattern_min_len = 1; | ||
3783 | wiphy->wowlan.pattern_max_len = WOW_PATTERN_SIZE; | ||
3784 | #endif | 3790 | #endif |
3785 | 3791 | ||
3786 | wiphy->max_sched_scan_ssids = MAX_PROBED_SSIDS; | 3792 | wiphy->max_sched_scan_ssids = MAX_PROBED_SSIDS; |