cfg_p2p.h 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181
  1. /*
  2. * Copyright (c) 2018-2020 The Linux Foundation. All rights reserved.
  3. * Copyright (c) 2021-2024 Qualcomm Innovation Center, Inc. All rights reserved.
  4. *
  5. * Permission to use, copy, modify, and/or distribute this software for
  6. * any purpose with or without fee is hereby granted, provided that the
  7. * above copyright notice and this permission notice appear in all
  8. * copies.
  9. *
  10. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
  11. * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
  12. * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
  13. * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
  14. * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
  15. * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
  16. * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  17. * PERFORMANCE OF THIS SOFTWARE.
  18. */
  19. #if !defined(CONFIG_P2P_H__)
  20. #define CONFIG_P2P_H__
  21. #include "cfg_define.h"
  22. #include "cfg_converged.h"
  23. #include "qdf_types.h"
  24. /*
  25. * <ini>
  26. * gGoKeepAlivePeriod - P2P GO keep alive period.
  27. * @Min: 1
  28. * @Max: 65535
  29. * @Default: 20
  30. *
  31. * This is P2P GO keep alive period.
  32. *
  33. * Related: None.
  34. *
  35. * Supported Feature: P2P
  36. *
  37. * Usage: External
  38. *
  39. * </ini>
  40. */
  41. #define CFG_GO_KEEP_ALIVE_PERIOD CFG_INI_UINT( \
  42. "gGoKeepAlivePeriod", \
  43. 1, \
  44. 65535, \
  45. 20, \
  46. CFG_VALUE_OR_DEFAULT, \
  47. "P2P GO keep alive period")
  48. /*
  49. * <ini>
  50. * gGoLinkMonitorPeriod - period where link is idle and where
  51. * we send NULL frame
  52. * @Min: 3
  53. * @Max: 50
  54. * @Default: 10
  55. *
  56. * This is period where link is idle and where we send NULL frame for P2P GO.
  57. *
  58. * Related: None.
  59. *
  60. * Supported Feature: P2P
  61. *
  62. * Usage: External
  63. *
  64. * </ini>
  65. */
  66. #define CFG_GO_LINK_MONITOR_PERIOD CFG_INI_UINT( \
  67. "gGoLinkMonitorPeriod", \
  68. 3, \
  69. 50, \
  70. 10, \
  71. CFG_VALUE_OR_DEFAULT, \
  72. "period where link is idle and where we send NULL frame")
  73. /*
  74. * <ini>
  75. * isP2pDeviceAddrAdministrated - Enables to derive the P2P MAC address from
  76. * the primary MAC address
  77. * @Min: 0
  78. * @Max: 1
  79. * @Default: 1
  80. *
  81. * This ini is used to enable/disable to derive the P2P MAC address from the
  82. * primary MAC address.
  83. *
  84. * Related: None.
  85. *
  86. * Supported Feature: P2P
  87. *
  88. * Usage: External
  89. *
  90. * </ini>
  91. */
  92. #define CFG_P2P_DEVICE_ADDRESS_ADMINISTRATED CFG_INI_BOOL( \
  93. "isP2pDeviceAddrAdministrated", \
  94. 1, \
  95. "derive the P2P MAC address from the primary MAC address")
  96. /*
  97. * <ini>
  98. * action_frame_random_seq_num_enabled - Enables random sequence number
  99. * generation for action frames
  100. * @Min: 0
  101. * @Max: 1
  102. * @Default: 1
  103. *
  104. * This ini is used to enable/disable random sequence number generation for
  105. * action frames.
  106. *
  107. * Related: None.
  108. *
  109. * Supported Feature: P2P
  110. *
  111. * Usage: external
  112. *
  113. * </ini>
  114. */
  115. #define CFG_ACTION_FRAME_RANDOM_SEQ_NUM_ENABLED CFG_INI_BOOL( \
  116. "action_frame_random_seq_num_enabled", \
  117. 1, \
  118. "Enable random seq nums for action frames")
  119. /*
  120. * <ini>
  121. * p2p_go_on_5ghz_indoor_chan - Allow P2P GO to operate on 5 GHz indoor channels
  122. *
  123. * @Min: 0
  124. * @Max: 1
  125. * @Default: 0
  126. *
  127. * This ini is used to enable/disable P2P-GO operation on 5 GHz
  128. * indoor channels.
  129. *
  130. * Related: sta_sap_scc_on_indoor_channel, gindoor_channel_support
  131. *
  132. * Supported Feature: P2P GO
  133. *
  134. * Usage: external
  135. *
  136. * </ini>
  137. */
  138. #define CFG_P2P_GO_ON_5GHZ_INDOOR_CHANNEL CFG_INI_BOOL(\
  139. "p2p_go_on_5ghz_indoor_chan", \
  140. 0, \
  141. "Allow P2P GO on 5 GHz indoor channels")
  142. /*
  143. * <ini>
  144. * p2p_go_ignore_non_p2p_probe_req - P2P GO ignore non-P2P probe req
  145. *
  146. * @Min: 0
  147. * @Max: 1
  148. * @Default: 0
  149. *
  150. * This ini is used to enable/disable P2P GO ignore non-P2P probe req and don't
  151. * send probe rsp to non-p2p device like STA.
  152. *
  153. *
  154. * Supported Feature: P2P GO
  155. *
  156. * Usage: external
  157. *
  158. * </ini>
  159. */
  160. #define CFG_GO_IGNORE_NON_P2P_PROBE_REQ CFG_INI_BOOL(\
  161. "go_ignore_non_p2p_probe_req", \
  162. 0, \
  163. "P2P GO ignore non-P2P probe req")
  164. #define CFG_P2P_ALL \
  165. CFG(CFG_ACTION_FRAME_RANDOM_SEQ_NUM_ENABLED) \
  166. CFG(CFG_GO_KEEP_ALIVE_PERIOD) \
  167. CFG(CFG_GO_LINK_MONITOR_PERIOD) \
  168. CFG(CFG_P2P_DEVICE_ADDRESS_ADMINISTRATED) \
  169. CFG(CFG_P2P_GO_ON_5GHZ_INDOOR_CHANNEL) \
  170. CFG(CFG_GO_IGNORE_NON_P2P_PROBE_REQ)
  171. #endif