1 /* 2 * Copyright (C) 2021 HiSilicon (Shanghai) Technologies CO., LIMITED. 3 * 4 * This program is free software; you can redistribute it and/or 5 * modify it under the terms of the GNU General Public License 6 * as published by the Free Software Foundation; either version 2 7 * of the License, or (at your option) any later version. 8 * 9 * This program is distributed in the hope that it will be useful, 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 * GNU General Public License for more details. 13 * 14 * You should have received a copy of the GNU General Public License 15 * along with this program; if not, write to the Free Software 16 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 */ 18 19 #ifndef __WAL_MAIN_H__ 20 #define __WAL_MAIN_H__ 21 22 /* **************************************************************************** 23 1 其他头文件包含 24 **************************************************************************** */ 25 #include "oal_ext_if.h" 26 #include "oam_ext_if.h" 27 #include "wal_event_msg.h" 28 29 #ifdef __cplusplus 30 #if __cplusplus 31 extern "C" { 32 #endif 33 #endif 34 35 /* **************************************************************************** 36 2 宏定义 37 **************************************************************************** */ 38 #define WAL_SDT_MEM_MAX_LEN 32 /* SDT读写内存的最大长度 */ 39 /* 读取和设置全局变量的结构体 */ 40 #define WAL_GLB_VAR_NAME_LEN 31 41 #define WAL_GLB_VAR_VAL_LEN 128 42 /* 提升到与接收任务优先级一致,避免因优先级低于接收任务,DHCP结果迟迟无法发送而连接失败 */ 43 #define wal_wake_lock() 44 #define wal_wake_unlock() 45 46 /* **************************************************************************** 47 3 枚举定义 48 **************************************************************************** */ 49 /* offload时,表示哪一个核的枚举 */ 50 typedef enum { 51 WAL_OFFLOAD_CORE_MODE_HMAC, 52 WAL_OFFLOAD_CORE_MODE_DMAC, 53 54 WAL_OFFLOAD_CORE_MODE_BUTT 55 } wal_offload_core_mode_enum; 56 typedef hi_u8 wal_offload_core_mode_enum_uint8; 57 58 /* **************************************************************************** 59 4 结构体定义 60 **************************************************************************** */ 61 /* 维测,设置某一种具体event上报开关的参数结构体 */ 62 typedef struct { 63 hi_s32 l_event_type; 64 hi_s32 l_param; 65 } wal_specific_event_type_param_stru; 66 67 /* **************************************************************************** 68 4 函数声明 69 **************************************************************************** */ 70 hi_u32 wal_main_init(hi_void); 71 hi_void wal_main_exit(hi_void); 72 hi_u32 hi_wifi_device_init(hi_void); 73 hi_u32 hi_wifi_host_init(struct BusDev *bus); 74 hi_void hi_wifi_host_exit(hi_void); 75 hi_u32 hi_wifi_plat_init(const hi_u8 vap_num, const hi_u8 user_num); 76 hi_void hi_wifi_plat_exit(hi_void); 77 hi_void hisi_wifi_resume_process(hi_void); 78 hi_u8 hi_wifi_get_host_exit_flag(hi_void); 79 #ifdef __cplusplus 80 #if __cplusplus 81 } 82 #endif 83 #endif 84 85 #endif /* end of wal_main */ 86