qcacmn: Add vendor attributes for TWT nudge request

TWT nudge is a combination of suspend and resume in a single request.
Add TWT nudge operation and QCA vendor attributes to support
the TWT nudge request.

Change-Id: Iddc4cb6722e88ad9dd65933091bdaa468718f2cf
CRs-fixed: 2822267
此提交包含在:
Paul Zhang
2020-11-19 10:58:18 +08:00
提交者 snandini
父節點 16550e216e
當前提交 6e6b928fc5

查看文件

@@ -8275,6 +8275,12 @@ enum qca_wlan_vendor_attr_wifi_test_config {
* @QCA_WLAN_TWT_RESUME: Resume the TWT session. Required parameters are
* configured through QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS. Refers the enum
* qca_wlan_vendor_attr_twt_resume. Valid only after the TWT session is setup.
*
* @QCA_WLAN_TWT_NUDGE: Suspend and resume the TWT session. TWT nudge is a
* combination of suspend and resume in a single request. Required parameters
* are configured through QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS. Refers the
* enum qca_wlan_vendor_attr_twt_nudge. Valid only after the TWT session is
* setup.
*/
enum qca_wlan_twt_operation {
QCA_WLAN_TWT_SET = 0,
@@ -8282,6 +8288,7 @@ enum qca_wlan_twt_operation {
QCA_WLAN_TWT_TERMINATE = 2,
QCA_WLAN_TWT_SUSPEND = 3,
QCA_WLAN_TWT_RESUME = 4,
QCA_WLAN_TWT_NUDGE = 5,
};
/* enum qca_wlan_vendor_attr_config_twt: Defines attributes used by
@@ -8409,6 +8416,7 @@ enum qca_wlan_vendor_attr_config_twt {
* 2. TWT TERMINATE Response
* 3. TWT SUSPEND Response
* 4. TWT RESUME Response
* 5. TWT NUDGE Response
*
* @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_RESP_TYPE: Required (u8)
* This field is applicable for TWT response only.
@@ -8575,6 +8583,44 @@ enum qca_wlan_vendor_twt_setup_req_type {
QCA_WLAN_VENDOR_TWT_SETUP_DEMAND = 3,
};
/**
* enum qca_wlan_vendor_attr_twt_nudge - Represents attributes for
* TWT (Target Wake Time) nudge request. TWT nudge is a combination of suspend
* and resume in a single request. These attributes are sent as part of
* %QCA_NL80211_VENDOR_SUBCMD_CONFIG_TWT.
*
* @QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_FLOW_ID: Required (u8)
* Flow ID is the unique identifier for each TWT session. This attribute
* represents the respective TWT session to suspend and resume.
*
* @QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_WAKE_TIME: Required (u32)
* This attribute is used as the SP offset which is the offset from
* TSF after which the wake happens. The units are in microseconds.
*
* @QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_NEXT_TWT_SIZE: Required (u32)
* This attribute represents the next TWT subfield size.
* Value 0 represents 0 bits, 1 represents 32 bits, 2 for 48 bits,
* and 4 for 64 bits.
*
* @QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_MAC_ADDR: 6-byte MAC address
* Represents the MAC address of the peer to which TWT Suspend and Resume is
* being sent. This is used in AP mode to represent the respective
* client and is a required parameter. In STA mode, this is an optional
* parameter.
*/
enum qca_wlan_vendor_attr_twt_nudge {
QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_INVALID = 0,
QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_FLOW_ID = 1,
QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_WAKE_TIME = 2,
QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_NEXT_TWT_SIZE = 3,
QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_MAC_ADDR = 4,
/* keep last */
QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_AFTER_LAST,
QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_MAX =
QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_AFTER_LAST - 1,
};
/**
* enum qca_wlan_vendor_twt_setup_resp_type - Represents the response type by
* the TWT responder