wmi_unified_cfr_api.c 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. /*
  2. * Copyright (c) 2019-2020, 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. #include "wmi_unified_priv.h"
  17. #include "wmi_unified_cfr_api.h"
  18. #ifdef WLAN_CFR_ENABLE
  19. QDF_STATUS wmi_unified_send_peer_cfr_capture_cmd(wmi_unified_t wmi_handle,
  20. struct peer_cfr_params *param)
  21. {
  22. if (wmi_handle->ops->send_peer_cfr_capture_cmd)
  23. return wmi_handle->ops->send_peer_cfr_capture_cmd(wmi_handle,
  24. param);
  25. return QDF_STATUS_E_FAILURE;
  26. }
  27. /**
  28. * wmi_extract_cfr_peer_tx_event_param() - extract tx event params from event
  29. */
  30. QDF_STATUS
  31. wmi_extract_cfr_peer_tx_event_param(wmi_unified_t wmi_handle, void *evt_buf,
  32. wmi_cfr_peer_tx_event_param *peer_tx_event)
  33. {
  34. if (wmi_handle->ops->extract_cfr_peer_tx_event_param)
  35. return wmi_handle->ops->extract_cfr_peer_tx_event_param(
  36. wmi_handle,
  37. evt_buf,
  38. peer_tx_event);
  39. return QDF_STATUS_E_FAILURE;
  40. }
  41. #ifdef WLAN_ENH_CFR_ENABLE
  42. QDF_STATUS wmi_unified_send_cfr_rcc_cmd(wmi_unified_t wmi_handle,
  43. struct cfr_rcc_param *cfg)
  44. {
  45. if (wmi_handle->ops->send_cfr_rcc_cmd)
  46. return wmi_handle->ops->send_cfr_rcc_cmd(wmi_handle, cfg);
  47. return QDF_STATUS_E_FAILURE;
  48. }
  49. #endif /* WLAN_ENH_CFR_ENABLE */
  50. #endif /* WLAN_CFR_ENABLE */