linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3] cfg80211: Allow different beacon interval if driver supports
@ 2016-07-22  9:42 Purushottam Kushwaha
  2016-08-01 10:02 ` Johannes Berg
  0 siblings, 1 reply; 2+ messages in thread
From: Purushottam Kushwaha @ 2016-07-22  9:42 UTC (permalink / raw)
  To: johannes
  Cc: linux-wireless, jouni, usdutt, ganeshk, mkalikot, amarnath,
	pkushwah

Driver may allow support for different beacon interval on virtual interfaces.
Allow if such support is advertised by driver. This adds new ext_feature as
NL80211_EXT_FEATURE_DIFF_BEACON_INTERVAL.

Signed-off-by: Purushottam Kushwaha <pkushwah@qti.qualcomm.com>
---
 include/uapi/linux/nl80211.h | 3 +++
 net/wireless/util.c          | 4 ++++
 2 files changed, 7 insertions(+)

diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index 2206941..a910d0e 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -4551,6 +4551,8 @@ enum nl80211_feature_flags {
  *	(if available).
  * @NL80211_EXT_FEATURE_SET_SCAN_DWELL: This driver supports configuration of
  *	channel dwell time.
+ * @NL80211_EXT_FEATURE_DIFF_BEACON_INTERVAL: This driver supports different
+ *	beacon interval on virtual interfaces.
  *
  * @NUM_NL80211_EXT_FEATURES: number of extended features.
  * @MAX_NL80211_EXT_FEATURES: highest extended feature index.
@@ -4562,6 +4564,7 @@ enum nl80211_ext_feature_index {
 	NL80211_EXT_FEATURE_SCAN_START_TIME,
 	NL80211_EXT_FEATURE_BSS_PARENT_TSF,
 	NL80211_EXT_FEATURE_SET_SCAN_DWELL,
+	NL80211_EXT_FEATURE_DIFF_BEACON_INTERVAL,
 
 	/* add new features before the definition below */
 	NUM_NL80211_EXT_FEATURES,
diff --git a/net/wireless/util.c b/net/wireless/util.c
index 2443ee3..65eeb23 100644
--- a/net/wireless/util.c
+++ b/net/wireless/util.c
@@ -1560,6 +1560,10 @@ int cfg80211_validate_beacon_int(struct cfg80211_registered_device *rdev,
 	if (!beacon_int)
 		return -EINVAL;
 
+	if (wiphy_ext_feature_isset(&rdev->wiphy,
+				    NL80211_EXT_FEATURE_DIFF_BEACON_INTERVAL))
+		return 0;
+
 	list_for_each_entry(wdev, &rdev->wiphy.wdev_list, list) {
 		if (!wdev->beacon_interval)
 			continue;
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH v3] cfg80211: Allow different beacon interval if driver supports
  2016-07-22  9:42 [PATCH v3] cfg80211: Allow different beacon interval if driver supports Purushottam Kushwaha
@ 2016-08-01 10:02 ` Johannes Berg
  0 siblings, 0 replies; 2+ messages in thread
From: Johannes Berg @ 2016-08-01 10:02 UTC (permalink / raw)
  To: Purushottam Kushwaha
  Cc: linux-wireless, jouni, usdutt, ganeshk, mkalikot, amarnath

On Fri, 2016-07-22 at 15:12 +0530, Purushottam Kushwaha wrote:
> Driver may allow support for different beacon interval on virtual
> interfaces.
> Allow if such support is advertised by driver. This adds new
> ext_feature as
> NL80211_EXT_FEATURE_DIFF_BEACON_INTERVAL.
> 
My earlier comment regarding interface combinations still stands.

johannes

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-08-01 10:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-22  9:42 [PATCH v3] cfg80211: Allow different beacon interval if driver supports Purushottam Kushwaha
2016-08-01 10:02 ` 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).