1*5113495bSYour Name /* 2*5113495bSYour Name * Copyright (c) 2020, The Linux Foundation. All rights reserved. 3*5113495bSYour Name * Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved. 4*5113495bSYour Name * 5*5113495bSYour Name * Permission to use, copy, modify, and/or distribute this software for any 6*5113495bSYour Name * purpose with or without fee is hereby granted, provided that the above 7*5113495bSYour Name * copyright notice and this permission notice appear in all copies. 8*5113495bSYour Name * 9*5113495bSYour Name * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 10*5113495bSYour Name * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 11*5113495bSYour Name * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 12*5113495bSYour Name * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 13*5113495bSYour Name * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 14*5113495bSYour Name * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 15*5113495bSYour Name * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16*5113495bSYour Name */ 17*5113495bSYour Name 18*5113495bSYour Name #ifndef _WLAN_IOT_SIM_UTILS_API_H_ 19*5113495bSYour Name #define _WLAN_IOT_SIM_UTILS_API_H_ 20*5113495bSYour Name 21*5113495bSYour Name #include <wlan_objmgr_cmn.h> 22*5113495bSYour Name #include <wlan_lmac_if_def.h> 23*5113495bSYour Name #include <wmi_unified_param.h> 24*5113495bSYour Name #include "include/wlan_pdev_mlme.h" 25*5113495bSYour Name #include "wlan_pdev_mlme_api.h" 26*5113495bSYour Name 27*5113495bSYour Name /* Forward Declarations */ 28*5113495bSYour Name struct wmi_iot_sim_cmd_ops; 29*5113495bSYour Name 30*5113495bSYour Name /** 31*5113495bSYour Name * struct iot_sim_cbacks - IOT Sim callbacks 32*5113495bSYour Name * @update_beacon_trigger: reg_beacon_trigger_handler 33*5113495bSYour Name */ 34*5113495bSYour Name struct iot_sim_cbacks { 35*5113495bSYour Name void (*update_beacon_trigger)(mlme_pdev_ext_t *); 36*5113495bSYour Name }; 37*5113495bSYour Name 38*5113495bSYour Name /** 39*5113495bSYour Name * iot_sim_cmd_handler() - IOT SIM frame handler function 40*5113495bSYour Name * @vdev: vdev object. 41*5113495bSYour Name * @buf: skb 42*5113495bSYour Name * @bcn_param: 43*5113495bSYour Name * @tx: TRUE in case of Tx 44*5113495bSYour Name * @param: mgmt_rx_event_params 45*5113495bSYour Name * 46*5113495bSYour Name * Return : QDF_STATUS_E_SUCCESS/QDF_STATUS_E_FAILURE. 47*5113495bSYour Name */ 48*5113495bSYour Name QDF_STATUS iot_sim_cmd_handler(struct wlan_objmgr_vdev *vdev, qdf_nbuf_t buf, 49*5113495bSYour Name struct beacon_tmpl_params *bcn_param, bool tx, 50*5113495bSYour Name struct mgmt_rx_event_params *param); 51*5113495bSYour Name 52*5113495bSYour Name /** 53*5113495bSYour Name * wlan_iot_sim_init() - API to init iot_sim component 54*5113495bSYour Name * 55*5113495bSYour Name * This API is invoked from dispatcher init during all component init. 56*5113495bSYour Name * This API will register all required handlers for pdev and peer object 57*5113495bSYour Name * create/delete notification. 58*5113495bSYour Name * 59*5113495bSYour Name * Return: SUCCESS, 60*5113495bSYour Name * Failure 61*5113495bSYour Name */ 62*5113495bSYour Name QDF_STATUS wlan_iot_sim_init(void); 63*5113495bSYour Name 64*5113495bSYour Name /** 65*5113495bSYour Name * wlan_iot_sim_deinit() - API to deinit iot_sim component 66*5113495bSYour Name * 67*5113495bSYour Name * This API is invoked from dispatcher deinit during all component deinit. 68*5113495bSYour Name * This API will unregister all registered handlers for pdev and peer object 69*5113495bSYour Name * create/delete notification. 70*5113495bSYour Name * 71*5113495bSYour Name * Return: SUCCESS, 72*5113495bSYour Name * Failure 73*5113495bSYour Name */ 74*5113495bSYour Name QDF_STATUS wlan_iot_sim_deinit(void); 75*5113495bSYour Name 76*5113495bSYour Name /** 77*5113495bSYour Name * wlan_lmac_if_iot_sim_register_rx_ops() - Register lmac interface Rx 78*5113495bSYour Name * operations 79*5113495bSYour Name * @rx_ops: Pointer to lmac interface Rx operations structure 80*5113495bSYour Name * 81*5113495bSYour Name * API to register iot_sim related lmac interface Rx operations 82*5113495bSYour Name * 83*5113495bSYour Name * Return: None 84*5113495bSYour Name */ 85*5113495bSYour Name void wlan_lmac_if_iot_sim_register_rx_ops(struct wlan_lmac_if_rx_ops *rx_ops); 86*5113495bSYour Name 87*5113495bSYour Name /** 88*5113495bSYour Name * wlan_register_wmi_iot_sim_cmd_ops() - Register operations related to wmi 89*5113495bSYour Name * commands on iot_sim parameters 90*5113495bSYour Name * @pdev: the physical device object 91*5113495bSYour Name * @cmd_ops: pointer to the structure holding the operations 92*5113495bSYour Name * related to wmi commands on iot_sim parameters 93*5113495bSYour Name * 94*5113495bSYour Name * API to register operations related to wmi commands on iot_sim parameters 95*5113495bSYour Name * 96*5113495bSYour Name * Return: None 97*5113495bSYour Name */ 98*5113495bSYour Name void 99*5113495bSYour Name wlan_register_wmi_iot_sim_cmd_ops(struct wlan_objmgr_pdev *pdev, 100*5113495bSYour Name struct wmi_iot_sim_cmd_ops *cmd_ops); 101*5113495bSYour Name 102*5113495bSYour Name #endif /* _WLAN_IOT_SIM_UTILS_API_H_*/ 103