dp_rx_mon_feature.h 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. /*
  2. * Copyright (c) 2017-2020 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 _DP_RX_MON_FEATURE_H_
  19. #define _DP_RX_MON_FEATURE_H_
  20. #ifdef WLAN_RX_PKT_CAPTURE_ENH
  21. /*
  22. * dp_rx_populate_cdp_indication_mpdu_info() - Populate cdp rx indication
  23. * MPDU info structure
  24. * @pdev: pdev ctx
  25. * @ppdu_info: ppdu info structure from monitor status ring
  26. * @cdp_mpdu_info: cdp rx indication MPDU info structure
  27. * @user: user ID
  28. *
  29. * Return: none
  30. */
  31. void
  32. dp_rx_populate_cdp_indication_mpdu_info(
  33. struct dp_pdev *pdev, struct hal_rx_ppdu_info *ppdu_info,
  34. struct cdp_rx_indication_mpdu_info *cdp_mpdu_info,
  35. uint32_t user);
  36. /*
  37. * dp_rx_handle_enh_capture() - Deliver Rx enhanced capture data
  38. * @pdev: pdev ctx
  39. * @ppdu_info: ppdu info structure from monitor status ring
  40. *
  41. * Return: QDF status
  42. */
  43. QDF_STATUS
  44. dp_rx_handle_enh_capture(struct dp_soc *soc, struct dp_pdev *pdev,
  45. struct hal_rx_ppdu_info *ppdu_info);
  46. /*
  47. * dp_rx_mon_enh_capture_process() - Rx enhanced capture mode
  48. * processing.
  49. * @pdev: pdev structure
  50. * @tlv_status: processed TLV status
  51. * @status_nbuf: monitor status ring buffer
  52. * @ppdu_info: ppdu info structure from monitor status ring
  53. * @nbuf_used: nbuf need a clone
  54. *
  55. * Return: none
  56. */
  57. void
  58. dp_rx_mon_enh_capture_process(struct dp_pdev *pdev, uint32_t tlv_status,
  59. qdf_nbuf_t status_nbuf,
  60. struct hal_rx_ppdu_info *ppdu_info,
  61. bool *nbuf_used);
  62. /*
  63. * dp_config_enh_rx_capture()- API to enable/disable enhanced rx capture
  64. * @pdev: DP_PDEV handle
  65. * @val: user provided value
  66. *
  67. * Return: 0 for success. nonzero for failure.
  68. */
  69. QDF_STATUS
  70. dp_config_enh_rx_capture(struct dp_pdev *pdev, uint8_t val);
  71. /**
  72. * dp_peer_set_rx_capture_enabled: Set rx_cap_enabled bit in peer
  73. * @peer_handle: Peer handle
  74. * @value: Enable/disable setting for rx_cap_enabled
  75. *
  76. * Return: None
  77. */
  78. void
  79. dp_peer_set_rx_capture_enabled(struct dp_peer *peer, bool value);
  80. #endif /* WLAN_RX_PKT_CAPTURE_ENH */
  81. #endif /* _DP_RX_MON_FEATURE_H_ */