wmi_unified_apf_tlv.h 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. /*
  2. * Copyright (c) 2016-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. #ifndef _WMI_UNIFIED_APF_TLV_H_
  19. #define _WMI_UNIFIED_APF_TLV_H_
  20. #ifdef FEATURE_WLAN_APF
  21. #include "wmi_unified.h"
  22. #include "wmi_unified_api.h"
  23. #include "wmi_unified_param.h"
  24. /**
  25. * wmi_send_set_active_apf_mode_cmd_tlv() - configure active APF mode in FW
  26. * @wmi_handle: the WMI handle
  27. * @vdev_id: the Id of the vdev to apply the configuration to
  28. * @ucast_mode: the active APF mode to configure for unicast packets
  29. * @mcast_bcast_mode: the active APF mode to configure for multicast/broadcast
  30. * packets
  31. *
  32. * Return: QDF status
  33. */
  34. QDF_STATUS
  35. wmi_send_set_active_apf_mode_cmd_tlv(wmi_unified_t wmi_handle,
  36. uint8_t vdev_id,
  37. enum wmi_host_active_apf_mode ucast_mode,
  38. enum wmi_host_active_apf_mode
  39. mcast_bcast_mode);
  40. /**
  41. * wmi_send_apf_enable_cmd_tlv() - send cmd to enable/disable APF interpreter
  42. * @wmi_handle: the WMI handle
  43. * @vdev_id: VDEV on which APF interpreter is to be enabled/disabled
  44. * @enable: true: enable, false: disable
  45. *
  46. * Return: QDF status
  47. */
  48. QDF_STATUS
  49. wmi_send_apf_enable_cmd_tlv(wmi_unified_t wmi_handle, uint32_t vdev_id,
  50. bool enable);
  51. /**
  52. * wmi_send_apf_write_work_memory_cmd_tlv() - send cmd to write into the APF
  53. * work
  54. * memory
  55. * @wmi_handle: the WMI handle
  56. * @apf_write_params: parameters and buffer pointer for the write
  57. *
  58. * Return: QDF status
  59. */
  60. QDF_STATUS
  61. wmi_send_apf_write_work_memory_cmd_tlv(wmi_unified_t wmi_handle,
  62. struct wmi_apf_write_memory_params
  63. *apf_write_params);
  64. /**
  65. * wmi_send_apf_read_work_memory_cmd_tlv() - send cmd to read part of APF
  66. * work memory
  67. * @wmi_handle: the WMI handle
  68. * @apf_read_params: contains relative address and length to read from
  69. *
  70. * Return: QDF status
  71. */
  72. QDF_STATUS
  73. wmi_send_apf_read_work_memory_cmd_tlv(wmi_unified_t wmi_handle,
  74. struct wmi_apf_read_memory_params
  75. *apf_read_params);
  76. /**
  77. * wmi_extract_apf_read_memory_resp_event_tlv() - extract read memory response
  78. * event into the given structure pointer
  79. * @wmi_handle: the WMI handle
  80. * @evt_buf: Pointer to the event buffer
  81. * @resp: pointer to memory to extract event parameters into
  82. *
  83. * Return: QDF status
  84. */
  85. QDF_STATUS
  86. wmi_extract_apf_read_memory_resp_event_tlv(wmi_unified_t wmi_handle,
  87. void *evt_buf,
  88. struct wmi_apf_read_memory_resp_event_params
  89. *resp);
  90. #endif /* FEATURE_WLAN_APF */
  91. #endif /* _WMI_UNIFIED_APF_TLV_H_ */