![]() |
|
|||
0001 /* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */ 0002 /* 0003 * Copyright (C) 2012-2014, 2018 Intel Corporation 0004 * Copyright (C) 2013-2015 Intel Mobile Communications GmbH 0005 * Copyright (C) 2016-2017 Intel Deutschland GmbH 0006 */ 0007 #ifndef __iwl_fw_api_tdls_h__ 0008 #define __iwl_fw_api_tdls_h__ 0009 0010 #include "fw/api/tx.h" 0011 #include "fw/api/phy-ctxt.h" 0012 0013 #define IWL_MVM_TDLS_STA_COUNT 4 0014 0015 /* Type of TDLS request */ 0016 enum iwl_tdls_channel_switch_type { 0017 TDLS_SEND_CHAN_SW_REQ = 0, 0018 TDLS_SEND_CHAN_SW_RESP_AND_MOVE_CH, 0019 TDLS_MOVE_CH, 0020 }; /* TDLS_STA_CHANNEL_SWITCH_CMD_TYPE_API_E_VER_1 */ 0021 0022 /** 0023 * struct iwl_tdls_channel_switch_timing - Switch timing in TDLS channel-switch 0024 * @frame_timestamp: GP2 timestamp of channel-switch request/response packet 0025 * received from peer 0026 * @max_offchan_duration: What amount of microseconds out of a DTIM is given 0027 * to the TDLS off-channel communication. For instance if the DTIM is 0028 * 200TU and the TDLS peer is to be given 25% of the time, the value 0029 * given will be 50TU, or 50 * 1024 if translated into microseconds. 0030 * @switch_time: switch time the peer sent in its channel switch timing IE 0031 * @switch_timeout: switch timeout the peer sent in its channel switch timing IE 0032 */ 0033 struct iwl_tdls_channel_switch_timing { 0034 __le32 frame_timestamp; /* GP2 time of peer packet Rx */ 0035 __le32 max_offchan_duration; /* given in micro-seconds */ 0036 __le32 switch_time; /* given in micro-seconds */ 0037 __le32 switch_timeout; /* given in micro-seconds */ 0038 } __packed; /* TDLS_STA_CHANNEL_SWITCH_TIMING_DATA_API_S_VER_1 */ 0039 0040 #define IWL_TDLS_CH_SW_FRAME_MAX_SIZE 200 0041 0042 /** 0043 * struct iwl_tdls_channel_switch_frame - TDLS channel switch frame template 0044 * 0045 * A template representing a TDLS channel-switch request or response frame 0046 * 0047 * @switch_time_offset: offset to the channel switch timing IE in the template 0048 * @tx_cmd: Tx parameters for the frame 0049 * @data: frame data 0050 */ 0051 struct iwl_tdls_channel_switch_frame { 0052 __le32 switch_time_offset; 0053 struct iwl_tx_cmd tx_cmd; 0054 u8 data[IWL_TDLS_CH_SW_FRAME_MAX_SIZE]; 0055 } __packed; /* TDLS_STA_CHANNEL_SWITCH_FRAME_API_S_VER_1 */ 0056 0057 /** 0058 * struct iwl_tdls_channel_switch_cmd_tail - tail of iwl_tdls_channel_switch_cmd 0059 * 0060 * @timing: timing related data for command 0061 * @frame: channel-switch request/response template, depending to switch_type 0062 */ 0063 struct iwl_tdls_channel_switch_cmd_tail { 0064 struct iwl_tdls_channel_switch_timing timing; 0065 struct iwl_tdls_channel_switch_frame frame; 0066 } __packed; 0067 0068 /** 0069 * struct iwl_tdls_channel_switch_cmd - TDLS channel switch command 0070 * 0071 * The command is sent to initiate a channel switch and also in response to 0072 * incoming TDLS channel-switch request/response packets from remote peers. 0073 * 0074 * @switch_type: see &enum iwl_tdls_channel_switch_type 0075 * @peer_sta_id: station id of TDLS peer 0076 * @ci: channel we switch to 0077 * @tail: command tail 0078 */ 0079 struct iwl_tdls_channel_switch_cmd { 0080 u8 switch_type; 0081 __le32 peer_sta_id; 0082 struct iwl_fw_channel_info ci; 0083 struct iwl_tdls_channel_switch_cmd_tail tail; 0084 } __packed; /* TDLS_STA_CHANNEL_SWITCH_CMD_API_S_VER_1 */ 0085 0086 /** 0087 * struct iwl_tdls_channel_switch_notif - TDLS channel switch start notification 0088 * 0089 * @status: non-zero on success 0090 * @offchannel_duration: duration given in microseconds 0091 * @sta_id: peer currently performing the channel-switch with 0092 */ 0093 struct iwl_tdls_channel_switch_notif { 0094 __le32 status; 0095 __le32 offchannel_duration; 0096 __le32 sta_id; 0097 } __packed; /* TDLS_STA_CHANNEL_SWITCH_NTFY_API_S_VER_1 */ 0098 0099 /** 0100 * struct iwl_tdls_sta_info - TDLS station info 0101 * 0102 * @sta_id: station id of the TDLS peer 0103 * @tx_to_peer_tid: TID reserved vs. the peer for FW based Tx 0104 * @tx_to_peer_ssn: initial SSN the FW should use for Tx on its TID vs the peer 0105 * @is_initiator: 1 if the peer is the TDLS link initiator, 0 otherwise 0106 */ 0107 struct iwl_tdls_sta_info { 0108 u8 sta_id; 0109 u8 tx_to_peer_tid; 0110 __le16 tx_to_peer_ssn; 0111 __le32 is_initiator; 0112 } __packed; /* TDLS_STA_INFO_VER_1 */ 0113 0114 /** 0115 * struct iwl_tdls_config_cmd - TDLS basic config command 0116 * 0117 * @id_and_color: MAC id and color being configured 0118 * @tdls_peer_count: amount of currently connected TDLS peers 0119 * @tx_to_ap_tid: TID reverved vs. the AP for FW based Tx 0120 * @tx_to_ap_ssn: initial SSN the FW should use for Tx on its TID vs. the AP 0121 * @sta_info: per-station info. Only the first tdls_peer_count entries are set 0122 * @pti_req_data_offset: offset of network-level data for the PTI template 0123 * @pti_req_tx_cmd: Tx parameters for PTI request template 0124 * @pti_req_template: PTI request template data 0125 */ 0126 struct iwl_tdls_config_cmd { 0127 __le32 id_and_color; /* mac id and color */ 0128 u8 tdls_peer_count; 0129 u8 tx_to_ap_tid; 0130 __le16 tx_to_ap_ssn; 0131 struct iwl_tdls_sta_info sta_info[IWL_MVM_TDLS_STA_COUNT]; 0132 0133 __le32 pti_req_data_offset; 0134 struct iwl_tx_cmd pti_req_tx_cmd; 0135 u8 pti_req_template[]; 0136 } __packed; /* TDLS_CONFIG_CMD_API_S_VER_1 */ 0137 0138 /** 0139 * struct iwl_tdls_config_sta_info_res - TDLS per-station config information 0140 * 0141 * @sta_id: station id of the TDLS peer 0142 * @tx_to_peer_last_seq: last sequence number used by FW during FW-based Tx to 0143 * the peer 0144 */ 0145 struct iwl_tdls_config_sta_info_res { 0146 __le16 sta_id; 0147 __le16 tx_to_peer_last_seq; 0148 } __packed; /* TDLS_STA_INFO_RSP_VER_1 */ 0149 0150 /** 0151 * struct iwl_tdls_config_res - TDLS config information from FW 0152 * 0153 * @tx_to_ap_last_seq: last sequence number used by FW during FW-based Tx to AP 0154 * @sta_info: per-station TDLS config information 0155 */ 0156 struct iwl_tdls_config_res { 0157 __le32 tx_to_ap_last_seq; 0158 struct iwl_tdls_config_sta_info_res sta_info[IWL_MVM_TDLS_STA_COUNT]; 0159 } __packed; /* TDLS_CONFIG_RSP_API_S_VER_1 */ 0160 0161 #endif /* __iwl_fw_api_tdls_h__ */
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.1.0 LXR engine. The LXR team |
![]() ![]() |