1 /******************************************************************************
3 * Copyright(c) 2016 - 2018 Realtek Corporation. All rights reserved.
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.
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
14 ******************************************************************************/
16 #ifndef _HALMAC_API_H_
17 #define _HALMAC_API_H_
19 #define HALMAC_SVN_VER "11692M"
21 #define HALMAC_MAJOR_VER 0x0001
22 #define HALMAC_PROTOTYPE_VER 0x0005
23 #define HALMAC_MINOR_VER 0x0000
24 #define HALMAC_PATCH_VER 0x0002
26 #define HALMAC_88XX_SUPPORT (HALMAC_8821C_SUPPORT || \
27 HALMAC_8822B_SUPPORT || \
28 HALMAC_8822C_SUPPORT || \
31 #define HALMAC_88XX_V1_SUPPORT HALMAC_8814B_SUPPORT
33 #include "halmac_2_platform.h"
34 #include "halmac_type.h"
35 #include "halmac_hw_cfg.h"
36 #include "halmac_usb_reg.h"
37 #include "halmac_sdio_reg.h"
38 #include "halmac_pcie_reg.h"
39 #include "halmac_bit2.h"
40 #include "halmac_reg2.h"
42 #if HALMAC_PLATFORM_TESTPROGRAM
43 #include "halmac_type_testprogram.h"
46 #ifndef HALMAC_USE_TYPEDEF
47 #define HALMAC_USE_TYPEDEF 1
50 #if HALMAC_USE_TYPEDEF
51 #include "halmac_typedef.h"
54 #if HALMAC_8822B_SUPPORT
55 #include "halmac_reg_8822b.h"
56 #include "halmac_bit_8822b.h"
59 #if HALMAC_8821C_SUPPORT
60 #include "halmac_reg_8821c.h"
61 #include "halmac_bit_8821c.h"
64 #if HALMAC_8814B_SUPPORT
65 #include "halmac_reg_8814b.h"
66 #include "halmac_bit_8814b.h"
69 #if HALMAC_8822C_SUPPORT
70 #include "halmac_reg_8822c.h"
71 #include "halmac_bit_8822c.h"
74 #if (HALMAC_PLATFORM_WINDOWS || HALMAC_PLATFORM_LINUX)
75 #include "halmac_tx_desc_nic.h"
76 #include "halmac_tx_desc_buffer_nic.h"
77 #include "halmac_tx_desc_ie_nic.h"
78 #include "halmac_rx_desc_nic.h"
79 #include "halmac_tx_bd_nic.h"
80 #include "halmac_rx_bd_nic.h"
81 #include "halmac_fw_offload_c2h_nic.h"
82 #include "halmac_fw_offload_h2c_nic.h"
83 #include "halmac_h2c_extra_info_nic.h"
84 #include "halmac_original_c2h_nic.h"
85 #include "halmac_original_h2c_nic.h"
88 #if (HALMAC_PLATFORM_AP)
89 #include "halmac_rx_desc_ap.h"
90 #include "halmac_tx_desc_ap.h"
91 #include "halmac_tx_desc_buffer_ap.h"
92 #include "halmac_tx_desc_ie_ap.h"
93 #include "halmac_fw_offload_c2h_ap.h"
94 #include "halmac_fw_offload_h2c_ap.h"
95 #include "halmac_h2c_extra_info_ap.h"
96 #include "halmac_original_c2h_ap.h"
97 #include "halmac_original_h2c_ap.h"
100 #include "halmac_tx_desc_chip.h"
101 #include "halmac_rx_desc_chip.h"
102 #include "halmac_tx_desc_buffer_chip.h"
103 #include "halmac_tx_desc_ie_chip.h"
105 enum halmac_ret_status
106 halmac_init_adapter(void *drv_adapter, struct halmac_platform_api *pltfm_api,
107 enum halmac_interface intf,
108 struct halmac_adapter **halmac_adapter,
109 struct halmac_api **halmac_api);
111 enum halmac_ret_status
112 halmac_deinit_adapter(struct halmac_adapter *adapter);
114 enum halmac_ret_status
115 halmac_halt_api(struct halmac_adapter *adapter);
117 enum halmac_ret_status
118 halmac_get_version(struct halmac_ver *version);