wlan_ipa_public_struct.h 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. /*
  2. * Copyright (c) 2018 The Linux Foundation. All rights reserved.
  3. *
  4. * Permission to use, copy, modify, and/or distribute this software for
  5. * any purpose with or without fee is hereby granted, provided that the
  6. * above copyright notice and this permission notice appear in all
  7. * copies.
  8. *
  9. * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
  10. * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
  11. * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
  12. * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
  13. * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
  14. * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
  15. * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
  16. * PERFORMANCE OF THIS SOFTWARE.
  17. */
  18. /*
  19. * DOC: contains ipa public structure definitions
  20. */
  21. #ifndef _WLAN_IPA_PUBLIC_STRUCT_H_
  22. #define _WLAN_IPA_PUBLIC_STRUCT_H_
  23. #include <wlan_cmn.h>
  24. #include <qdf_status.h>
  25. #include <wlan_objmgr_psoc_obj.h>
  26. /**
  27. * struct wlan_ipa_config
  28. * @ipa_config: IPA config
  29. * @desc_size: IPA descriptor size
  30. * @txbuf_count: TX buffer count
  31. * @bus_bw_high: Bus bandwidth high threshold
  32. * @bus_bw_medium: Bus bandwidth medium threshold
  33. * @bus_bw_low: Bus bandwidth low threshold
  34. * @ipa_bw_high: IPA bandwidth high threshold
  35. * @ipa_bw_medium: IPA bandwidth medium threshold
  36. * @ipa_bw_low: IPA bandwidth low threshold
  37. */
  38. struct wlan_ipa_config {
  39. uint32_t ipa_config;
  40. uint32_t desc_size;
  41. uint32_t txbuf_count;
  42. uint32_t bus_bw_high;
  43. uint32_t bus_bw_medium;
  44. uint32_t bus_bw_low;
  45. uint32_t ipa_bw_high;
  46. uint32_t ipa_bw_medium;
  47. uint32_t ipa_bw_low;
  48. };
  49. /**
  50. * enum wlan_ipa_wlan_event - WLAN IPA events
  51. * @WLAN_IPA_CLIENT_CONNECT: Client Connects
  52. * @WLAN_IPA_CLIENT_DISCONNECT: Client Disconnects
  53. * @WLAN_IPA_AP_CONNECT: SoftAP is started
  54. * @WLAN_IPA_AP_DISCONNECT: SoftAP is stopped
  55. * @WLAN_IPA_STA_CONNECT: STA associates to AP
  56. * @WLAN_IPA_STA_DISCONNECT: STA dissociates from AP
  57. * @WLAN_IPA_CLIENT_CONNECT_EX: Peer associates/re-associates to softap
  58. * @WLAN_IPA_WLAN_EVENT_MAX: Max value for the enum
  59. */
  60. enum wlan_ipa_wlan_event {
  61. WLAN_IPA_CLIENT_CONNECT,
  62. WLAN_IPA_CLIENT_DISCONNECT,
  63. WLAN_IPA_AP_CONNECT,
  64. WLAN_IPA_AP_DISCONNECT,
  65. WLAN_IPA_STA_CONNECT,
  66. WLAN_IPA_STA_DISCONNECT,
  67. WLAN_IPA_CLIENT_CONNECT_EX,
  68. WLAN_IPA_WLAN_EVENT_MAX
  69. };
  70. /**
  71. * struct ipa_uc_offload_control_params - ipa offload control params
  72. * @offload_type: ipa offload type
  73. * @vdev_id: vdev id
  74. * @enable: ipa offload enable/disable
  75. */
  76. struct ipa_uc_offload_control_params {
  77. uint32_t offload_type;
  78. uint32_t vdev_id;
  79. uint32_t enable;
  80. };
  81. /* fp to send IPA UC offload cmd */
  82. typedef QDF_STATUS (*ipa_uc_offload_control_req)(struct wlan_objmgr_psoc *psoc,
  83. struct ipa_uc_offload_control_params *req);
  84. #endif /* end of _WLAN_IPA_PUBLIC_STRUCT_H_ */