halmac_common_88xx.h 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155
  1. /******************************************************************************
  2. *
  3. * Copyright(c) 2016 - 2018 Realtek Corporation. All rights reserved.
  4. *
  5. * This program is free software; you can redistribute it and/or modify it
  6. * under the terms of version 2 of the GNU General Public License as
  7. * published by the Free Software Foundation.
  8. *
  9. * This program is distributed in the hope that it will be useful, but WITHOUT
  10. * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11. * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
  12. * more details.
  13. *
  14. ******************************************************************************/
  15. #ifndef _HALMAC_COMMON_88XX_H_
  16. #define _HALMAC_COMMON_88XX_H_
  17. #include "../halmac_api.h"
  18. #include "../halmac_pwr_seq_cmd.h"
  19. #include "../halmac_gpio_cmd.h"
  20. #if HALMAC_88XX_SUPPORT
  21. enum halmac_ret_status
  22. ofld_func_cfg_88xx(struct halmac_adapter *adapter,
  23. struct halmac_ofld_func_info *info);
  24. enum halmac_ret_status
  25. dl_drv_rsvd_page_88xx(struct halmac_adapter *adapter, u8 pg_offset, u8 *buf,
  26. u32 size);
  27. enum halmac_ret_status
  28. dl_rsvd_page_88xx(struct halmac_adapter *adapter, u16 pg_addr, u8 *buf,
  29. u32 size);
  30. enum halmac_ret_status
  31. get_hw_value_88xx(struct halmac_adapter *adapter, enum halmac_hw_id hw_id,
  32. void *value);
  33. enum halmac_ret_status
  34. set_hw_value_88xx(struct halmac_adapter *adapter, enum halmac_hw_id hw_id,
  35. void *value);
  36. enum halmac_ret_status
  37. set_h2c_pkt_hdr_88xx(struct halmac_adapter *adapter, u8 *hdr,
  38. struct halmac_h2c_header_info *info, u16 *seq_num);
  39. enum halmac_ret_status
  40. send_h2c_pkt_88xx(struct halmac_adapter *adapter, u8 *pkt);
  41. enum halmac_ret_status
  42. get_h2c_buf_free_space_88xx(struct halmac_adapter *adapter);
  43. enum halmac_ret_status
  44. get_c2h_info_88xx(struct halmac_adapter *adapter, u8 *buf, u32 size);
  45. enum halmac_ret_status
  46. mac_debug_88xx(struct halmac_adapter *adapter);
  47. enum halmac_ret_status
  48. cfg_parameter_88xx(struct halmac_adapter *adapter,
  49. struct halmac_phy_parameter_info *info, u8 full_fifo);
  50. enum halmac_ret_status
  51. update_packet_88xx(struct halmac_adapter *adapter, enum halmac_packet_id pkt_id,
  52. u8 *pkt, u32 size);
  53. enum halmac_ret_status
  54. bcn_ie_filter_88xx(struct halmac_adapter *adapter,
  55. struct halmac_bcn_ie_info *info);
  56. enum halmac_ret_status
  57. update_datapack_88xx(struct halmac_adapter *adapter,
  58. enum halmac_data_type data_type,
  59. struct halmac_phy_parameter_info *info);
  60. enum halmac_ret_status
  61. run_datapack_88xx(struct halmac_adapter *adapter,
  62. enum halmac_data_type data_type);
  63. enum halmac_ret_status
  64. send_bt_coex_88xx(struct halmac_adapter *adapter, u8 *buf, u32 size, u8 ack);
  65. enum halmac_ret_status
  66. dump_fifo_88xx(struct halmac_adapter *adapter, enum hal_fifo_sel sel,
  67. u32 start_addr, u32 size, u8 *data);
  68. u32
  69. get_fifo_size_88xx(struct halmac_adapter *adapter, enum hal_fifo_sel sel);
  70. enum halmac_ret_status
  71. set_h2c_header_88xx(struct halmac_adapter *adapter, u8 *hdr, u16 *seq, u8 ack);
  72. enum halmac_ret_status
  73. add_ch_info_88xx(struct halmac_adapter *adapter, struct halmac_ch_info *info);
  74. enum halmac_ret_status
  75. add_extra_ch_info_88xx(struct halmac_adapter *adapter,
  76. struct halmac_ch_extra_info *info);
  77. enum halmac_ret_status
  78. ctrl_ch_switch_88xx(struct halmac_adapter *adapter,
  79. struct halmac_ch_switch_option *opt);
  80. enum halmac_ret_status
  81. clear_ch_info_88xx(struct halmac_adapter *adapter);
  82. enum halmac_ret_status
  83. chk_txdesc_88xx(struct halmac_adapter *adapter, u8 *buf, u32 size);
  84. enum halmac_ret_status
  85. get_version_88xx(struct halmac_adapter *adapter, struct halmac_ver *ver);
  86. enum halmac_ret_status
  87. p2pps_88xx(struct halmac_adapter *adapter, struct halmac_p2pps *info);
  88. enum halmac_ret_status
  89. query_status_88xx(struct halmac_adapter *adapter,
  90. enum halmac_feature_id feature_id,
  91. enum halmac_cmd_process_status *proc_status, u8 *data,
  92. u32 *size);
  93. enum halmac_ret_status
  94. cfg_drv_rsvd_pg_num_88xx(struct halmac_adapter *adapter,
  95. enum halmac_drv_rsvd_pg_num pg_num);
  96. enum halmac_ret_status
  97. h2c_lb_88xx(struct halmac_adapter *adapter);
  98. enum halmac_ret_status
  99. pwr_seq_parser_88xx(struct halmac_adapter *adapter,
  100. struct halmac_wlan_pwr_cfg **cmd_seq);
  101. enum halmac_ret_status
  102. parse_intf_phy_88xx(struct halmac_adapter *adapter,
  103. struct halmac_intf_phy_para *param,
  104. enum halmac_intf_phy_platform pltfm,
  105. enum hal_intf_phy intf_phy);
  106. enum halmac_ret_status
  107. txfifo_is_empty_88xx(struct halmac_adapter *adapter, u32 chk_num);
  108. u8*
  109. smart_malloc_88xx(struct halmac_adapter *adapter, u32 size, u32 *new_size);
  110. enum halmac_ret_status
  111. ltecoex_reg_read_88xx(struct halmac_adapter *adapter, u16 offset, u32 *value);
  112. enum halmac_ret_status
  113. ltecoex_reg_write_88xx(struct halmac_adapter *adapter, u16 offset, u32 value);
  114. #endif/* HALMAC_88XX_SUPPORT */
  115. #endif/* _HALMAC_COMMON_88XX_H_ */