History

nl80211: add an attribute to allow delaying the first scheduled scan cycle

The userspace may want to delay the the first scheduled scan or net-detect cycle. Add an optional attribute to the scheduled scan configuration to pass the delay to be (optionally) used by the driver.

Luciano Coelho committed 11 years ago

Commit 9c748931 parent db82d8a3 files · +24 −6Browse files

Showing the changes to include/uapi/linux (1 of 3 files). Show all

Unified · Split

include/uapi/linux/nl80211.h+14−6
@@ -324,7 +324,9 @@ · 323 unmodified lines
324 * if passed, define which channels should be scanned; if not324 * if passed, define which channels should be scanned; if not
325 * passed, all channels allowed for the current regulatory domain325 * passed, all channels allowed for the current regulatory domain
326 * are used. Extra IEs can also be passed from the userspace by326 * are used. Extra IEs can also be passed from the userspace by
327 * using the %NL80211_ATTR_IE attribute.327 * using the %NL80211_ATTR_IE attribute. The first cycle of the
328 * scheduled scan can be delayed by %NL80211_ATTR_SCHED_SCAN_DELAY
329 * is supplied.
328 * @NL80211_CMD_STOP_SCHED_SCAN: stop a scheduled scan. Returns -ENOENT if330 * @NL80211_CMD_STOP_SCHED_SCAN: stop a scheduled scan. Returns -ENOENT if
329 * scheduled scan is not running. The caller may assume that as soon331 * scheduled scan is not running. The caller may assume that as soon
330 * as the call returns, it is safe to start a new scheduled scan again.332 * as the call returns, it is safe to start a new scheduled scan again.
@@ -1735,6 +1737,9 @@ enum nl80211_commands { · 1404 unmodified lines
1735 * should be contained in the result as the sum of the respective counters1737 * should be contained in the result as the sum of the respective counters
1736 * over all channels.1738 * over all channels.
1737 *1739 *
1740 * @NL80211_ATTR_SCHED_SCAN_DELAY: delay before a scheduled scan (or a
1741 * WoWLAN net-detect scan) is started, u32 in seconds.
1742 *
1738 * @NUM_NL80211_ATTR: total number of nl80211_attrs available1743 * @NUM_NL80211_ATTR: total number of nl80211_attrs available
1739 * @NL80211_ATTR_MAX: highest attribute number currently defined1744 * @NL80211_ATTR_MAX: highest attribute number currently defined
1740 * @__NL80211_ATTR_AFTER_LAST: internal use1745 * @__NL80211_ATTR_AFTER_LAST: internal use
@@ -2100,6 +2105,8 @@ enum nl80211_attrs { · 359 unmodified lines
2100 2105
2101 NL80211_ATTR_NETNS_FD,2106 NL80211_ATTR_NETNS_FD,
2102 2107
2108 NL80211_ATTR_SCHED_SCAN_DELAY,
2109
2103 /* add attributes here, update the policy in nl80211.c */2110 /* add attributes here, update the policy in nl80211.c */
2104 2111
2105 __NL80211_ATTR_AFTER_LAST,2112 __NL80211_ATTR_AFTER_LAST,
@@ -3743,11 +3750,12 @@ struct nl80211_pattern_support { · 1637 unmodified lines
3743 * @NL80211_WOWLAN_TRIG_NET_DETECT: wake up when a configured network3750 * @NL80211_WOWLAN_TRIG_NET_DETECT: wake up when a configured network
3744 * is detected. This is a nested attribute that contains the3751 * is detected. This is a nested attribute that contains the
3745 * same attributes used with @NL80211_CMD_START_SCHED_SCAN. It3752 * same attributes used with @NL80211_CMD_START_SCHED_SCAN. It
3746 * specifies how the scan is performed (e.g. the interval and the3753 * specifies how the scan is performed (e.g. the interval, the
3747 * channels to scan) as well as the scan results that will3754 * channels to scan and the initial delay) as well as the scan
3748 * trigger a wake (i.e. the matchsets). This attribute is also3755 * results that will trigger a wake (i.e. the matchsets). This
3749 * sent in a response to @NL80211_CMD_GET_WIPHY, indicating the3756 * attribute is also sent in a response to
3750 * number of match sets supported by the driver (u32).3757 * @NL80211_CMD_GET_WIPHY, indicating the number of match sets
3758 * supported by the driver (u32).
3751 * @NL80211_WOWLAN_TRIG_NET_DETECT_RESULTS: nested attribute3759 * @NL80211_WOWLAN_TRIG_NET_DETECT_RESULTS: nested attribute
3752 * containing an array with information about what triggered the3760 * containing an array with information about what triggered the
3753 * wake up. If no elements are present in the array, it means3761 * wake up. If no elements are present in the array, it means