diff options
author | Jouni Malinen <jouni.malinen@atheros.com> | 2009-12-23 07:15:41 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-12-28 16:55:02 -0500 |
commit | 9588bbd5529461a3dacd435bf239c84c3508f569 (patch) | |
tree | dd00011714bdefdef1f818ac7caf53682253a515 /include/linux/nl80211.h | |
parent | b203ffc3a447eb8d9e6120b783ddee081b143061 (diff) |
cfg80211: add remain-on-channel command
Add new commands for requesting the driver to remain awake
on a specified channel for the specified amount of time
(and another command to cancel such an operation). This
can be used to implement userspace-controlled off-channel
operations, like Public Action frame exchange on another
channel than the operation channel.
The off-channel operation should behave similarly to scan,
i.e. the local station (if associated) moves into power
save mode to request the AP to buffer frames for it and
then moves to the other channel to allow the off-channel
operation to be completed. The duration parameter can be
used to request enough time to receive a response from
the target station.
Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com>
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'include/linux/nl80211.h')
-rw-r--r-- | include/linux/nl80211.h | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/include/linux/nl80211.h b/include/linux/nl80211.h index da8ea2e19273..2bfbe88837ef 100644 --- a/include/linux/nl80211.h +++ b/include/linux/nl80211.h | |||
@@ -270,6 +270,31 @@ | |||
270 | * @NL80211_CMD_SET_WIPHY_NETNS: Set a wiphy's netns. Note that all devices | 270 | * @NL80211_CMD_SET_WIPHY_NETNS: Set a wiphy's netns. Note that all devices |
271 | * associated with this wiphy must be down and will follow. | 271 | * associated with this wiphy must be down and will follow. |
272 | * | 272 | * |
273 | * @NL80211_CMD_REMAIN_ON_CHANNEL: Request to remain awake on the specified | ||
274 | * channel for the specified amount of time. This can be used to do | ||
275 | * off-channel operations like transmit a Public Action frame and wait for | ||
276 | * a response while being associated to an AP on another channel. | ||
277 | * %NL80211_ATTR_WIPHY or %NL80211_ATTR_IFINDEX is used to specify which | ||
278 | * radio is used. %NL80211_ATTR_WIPHY_FREQ is used to specify the | ||
279 | * frequency for the operation and %NL80211_ATTR_WIPHY_CHANNEL_TYPE may be | ||
280 | * optionally used to specify additional channel parameters. | ||
281 | * %NL80211_ATTR_DURATION is used to specify the duration in milliseconds | ||
282 | * to remain on the channel. This command is also used as an event to | ||
283 | * notify when the requested duration starts (it may take a while for the | ||
284 | * driver to schedule this time due to other concurrent needs for the | ||
285 | * radio). | ||
286 | * When called, this operation returns a cookie (%NL80211_ATTR_COOKIE) | ||
287 | * that will be included with any events pertaining to this request; | ||
288 | * the cookie is also used to cancel the request. | ||
289 | * @NL80211_CMD_CANCEL_REMAIN_ON_CHANNEL: This command can be used to cancel a | ||
290 | * pending remain-on-channel duration if the desired operation has been | ||
291 | * completed prior to expiration of the originally requested duration. | ||
292 | * %NL80211_ATTR_WIPHY or %NL80211_ATTR_IFINDEX is used to specify the | ||
293 | * radio. The %NL80211_ATTR_COOKIE attribute must be given as well to | ||
294 | * uniquely identify the request. | ||
295 | * This command is also used as an event to notify when a requested | ||
296 | * remain-on-channel duration has expired. | ||
297 | * | ||
273 | * @NL80211_CMD_MAX: highest used command number | 298 | * @NL80211_CMD_MAX: highest used command number |
274 | * @__NL80211_CMD_AFTER_LAST: internal use | 299 | * @__NL80211_CMD_AFTER_LAST: internal use |
275 | */ | 300 | */ |
@@ -353,6 +378,9 @@ enum nl80211_commands { | |||
353 | NL80211_CMD_DEL_PMKSA, | 378 | NL80211_CMD_DEL_PMKSA, |
354 | NL80211_CMD_FLUSH_PMKSA, | 379 | NL80211_CMD_FLUSH_PMKSA, |
355 | 380 | ||
381 | NL80211_CMD_REMAIN_ON_CHANNEL, | ||
382 | NL80211_CMD_CANCEL_REMAIN_ON_CHANNEL, | ||
383 | |||
356 | /* add new commands above here */ | 384 | /* add new commands above here */ |
357 | 385 | ||
358 | /* used to define NL80211_CMD_MAX below */ | 386 | /* used to define NL80211_CMD_MAX below */ |
@@ -606,6 +634,10 @@ enum nl80211_commands { | |||
606 | * @NL80211_ATTR_MAX_NUM_PMKIDS: maximum number of PMKIDs a firmware can | 634 | * @NL80211_ATTR_MAX_NUM_PMKIDS: maximum number of PMKIDs a firmware can |
607 | * cache, a wiphy attribute. | 635 | * cache, a wiphy attribute. |
608 | * | 636 | * |
637 | * @NL80211_ATTR_DURATION: Duration of an operation in milliseconds, u32. | ||
638 | * | ||
639 | * @NL80211_ATTR_COOKIE: Generic 64-bit cookie to identify objects. | ||
640 | * | ||
609 | * @NL80211_ATTR_MAX: highest attribute number currently defined | 641 | * @NL80211_ATTR_MAX: highest attribute number currently defined |
610 | * @__NL80211_ATTR_AFTER_LAST: internal use | 642 | * @__NL80211_ATTR_AFTER_LAST: internal use |
611 | */ | 643 | */ |
@@ -743,6 +775,10 @@ enum nl80211_attrs { | |||
743 | NL80211_ATTR_PMKID, | 775 | NL80211_ATTR_PMKID, |
744 | NL80211_ATTR_MAX_NUM_PMKIDS, | 776 | NL80211_ATTR_MAX_NUM_PMKIDS, |
745 | 777 | ||
778 | NL80211_ATTR_DURATION, | ||
779 | |||
780 | NL80211_ATTR_COOKIE, | ||
781 | |||
746 | /* add attributes here, update the policy in nl80211.c */ | 782 | /* add attributes here, update the policy in nl80211.c */ |
747 | 783 | ||
748 | __NL80211_ATTR_AFTER_LAST, | 784 | __NL80211_ATTR_AFTER_LAST, |