wmi_unified_roam_param.h 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179
  1. /*
  2. * Copyright (c) 2013-2021, The Linux Foundation. All rights reserved.
  3. *
  4. * Permission to use, copy, modify, and/or distribute this software for any
  5. * purpose with or without fee is hereby granted, provided that the above
  6. * copyright notice and this permission notice appear in all copies.
  7. *
  8. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  9. * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  10. * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  11. * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  12. * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  13. * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  14. * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  15. */
  16. /*
  17. * This file contains the API definitions for the ROAMING WMI APIs.
  18. */
  19. #ifndef _WMI_UNIFIED_ROAM_PARAM_H_
  20. #define _WMI_UNIFIED_ROAM_PARAM_H_
  21. #include <wlan_blm_public_struct.h>
  22. #include <wlan_cm_bss_score_param.h>
  23. /**
  24. * struct gateway_update_req_param - gateway parameter update request
  25. * @request_id: request id
  26. * @vdev_id: vdev id
  27. * @max_retries: Max ARP/NS retry attempts
  28. * @timeout: Retry interval
  29. * @ipv4_addr_type: on ipv4 network
  30. * @ipv6_addr_type: on ipv6 network
  31. * @gw_mac_addr: gateway mac addr
  32. * @ipv4_addr: ipv4 addr
  33. * @ipv6_addr: ipv6 addr
  34. */
  35. struct gateway_update_req_param {
  36. uint32_t request_id;
  37. uint32_t vdev_id;
  38. uint32_t max_retries;
  39. uint32_t timeout;
  40. uint32_t ipv4_addr_type;
  41. uint32_t ipv6_addr_type;
  42. struct qdf_mac_addr gw_mac_addr;
  43. uint8_t ipv4_addr[QDF_IPV4_ADDR_SIZE];
  44. uint8_t ipv6_addr[QDF_IPV6_ADDR_SIZE];
  45. };
  46. /**
  47. * struct rssi_monitor_param - rssi monitoring
  48. * @request_id: request id
  49. * @vdev_id: vdev id
  50. * @min_rssi: minimum rssi
  51. * @max_rssi: maximum rssi
  52. * @control: flag to indicate start or stop
  53. */
  54. struct rssi_monitor_param {
  55. uint32_t request_id;
  56. uint32_t vdev_id;
  57. int8_t min_rssi;
  58. int8_t max_rssi;
  59. bool control;
  60. };
  61. #define WMI_CFG_VALID_CHANNEL_LIST_LEN 100
  62. /* Occupied channel list remains static */
  63. #define WMI_CHANNEL_LIST_STATIC 1
  64. /* Occupied channel list can be learnt after init */
  65. #define WMI_CHANNEL_LIST_DYNAMIC_INIT 2
  66. /* Occupied channel list can be learnt after flush */
  67. #define WMI_CHANNEL_LIST_DYNAMIC_FLUSH 3
  68. /* Occupied channel list can be learnt after update */
  69. #define WMI_CHANNEL_LIST_DYNAMIC_UPDATE 4
  70. /**
  71. * struct plm_req_params - plm req parameter
  72. * @diag_token: Dialog token
  73. * @meas_token: measurement token
  74. * @num_bursts: total number of bursts
  75. * @burst_int: burst interval in seconds
  76. * @meas_duration:in TU's,STA goes off-ch
  77. * @burst_len: no of times the STA should cycle through PLM ch list
  78. * @desired_tx_pwr: desired tx power
  79. * @mac_addr: MC dest addr
  80. * @plm_num_ch: channel numbers
  81. * @plm_ch_freq_list: channel frequency list
  82. * @vdev_id: vdev id
  83. * @enable: enable/disable
  84. */
  85. struct plm_req_params {
  86. uint16_t diag_token;
  87. uint16_t meas_token;
  88. uint16_t num_bursts;
  89. uint16_t burst_int;
  90. uint16_t meas_duration;
  91. /* no of times the STA should cycle through PLM ch list */
  92. uint8_t burst_len;
  93. int8_t desired_tx_pwr;
  94. struct qdf_mac_addr mac_addr;
  95. /* no of channels */
  96. uint8_t plm_num_ch;
  97. /* channel frequency list */
  98. uint32_t plm_ch_freq_list[WMI_CFG_VALID_CHANNEL_LIST_LEN];
  99. uint8_t vdev_id;
  100. bool enable;
  101. };
  102. /**
  103. * struct wmi_limit_off_chan_param - limit off channel parameters
  104. * @vdev_id: vdev id
  105. * @status: status of the command (enable/disable)
  106. * @max_offchan_time: max off channel time
  107. * @rest_time: home channel time
  108. * @skip_dfs_chans: skip dfs channels during scan
  109. */
  110. struct wmi_limit_off_chan_param {
  111. uint32_t vdev_id;
  112. bool status;
  113. uint32_t max_offchan_time;
  114. uint32_t rest_time;
  115. bool skip_dfs_chans;
  116. };
  117. #define WMI_MAX_HLP_IE_LEN 2048
  118. /**
  119. * struct hlp_params - HLP info params
  120. * @vdev_id: vdev id
  121. * @hlp_ie_len: HLP IE length
  122. * @hlp_ie: HLP IE
  123. */
  124. struct hlp_params {
  125. uint8_t vdev_id;
  126. uint32_t hlp_ie_len;
  127. uint8_t hlp_ie[WMI_MAX_HLP_IE_LEN];
  128. };
  129. /**
  130. * struct wmi_roam_auth_status_params - WPA3 roam auth response status
  131. * parameters
  132. * @vdev_id: Vdev on which roam preauth is happening
  133. * @preauth_status: Status of the Auth response.
  134. * IEEE80211_STATUS_SUCCESS(0) for success. Corresponding
  135. * IEEE80211 failure status code for failure.
  136. *
  137. * @bssid: Candidate BSSID
  138. * @pmkid: PMKID derived for the auth
  139. */
  140. struct wmi_roam_auth_status_params {
  141. uint32_t vdev_id;
  142. uint32_t preauth_status;
  143. struct qdf_mac_addr bssid;
  144. uint8_t pmkid[PMKID_LEN];
  145. };
  146. /**
  147. * struct wmi_invoke_neighbor_report_params - Invoke neighbor report request
  148. * from IW to FW
  149. * @vdev_id: vdev id
  150. * @send_resp_to_host: bool to send response to host or not
  151. * @ssid: ssid given from the IW command
  152. */
  153. struct wmi_invoke_neighbor_report_params {
  154. uint32_t vdev_id;
  155. uint32_t send_resp_to_host;
  156. struct wlan_ssid ssid;
  157. };
  158. /**
  159. * set_pcl_cmd_params - Set PCL command params
  160. * @vdev_id: Vdev id
  161. * @weight: PCL weight
  162. */
  163. struct set_pcl_cmd_params {
  164. uint8_t vdev_id;
  165. struct wmi_pcl_chan_weights *weights;
  166. };
  167. #endif /* _WMI_UNIFIED_ROAM_PARAM_H_ */