1 /* 2 * Copyright (c) 2022 Qualcomm Innovation Center, Inc. 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 17 /** 18 * DOC: os_if_wifi_pos_utils.h 19 * This file provide declaration of wifi_pos's os_if APIs 20 */ 21 #ifndef _OS_IF_WIFI_POS_UTILS_H_ 22 #define _OS_IF_WIFI_POS_UTILS_H_ 23 24 #include "qdf_types.h" 25 #include "qdf_status.h" 26 #include <wlan_objmgr_cmn.h> 27 #include "wifi_pos_public_struct.h" 28 29 #if defined(WIFI_POS_CONVERGED) 30 /** 31 * struct wifi_pos_osif_ops - Wifi POS osif callbacks 32 * @osif_initiate_pasn_cb: Callback to initiate PASN authentication 33 */ 34 struct wifi_pos_osif_ops { 35 QDF_STATUS (*osif_initiate_pasn_cb)(struct wlan_objmgr_vdev *vdev, 36 struct wlan_pasn_request *pasn_peer, 37 uint8_t num_pasn_peers, 38 bool is_initiate_pasn); 39 }; 40 #endif 41 42 #if defined(WIFI_POS_CONVERGED) && defined(WLAN_FEATURE_RTT_11AZ_SUPPORT) 43 44 /** 45 * osif_wifi_pos_register_ops() - Register Wifi-Pos module OS_IF callbacks 46 * @psoc: Pointer to PSOC obj 47 * 48 * Return: QDF_STATUS 49 */ 50 QDF_STATUS 51 osif_wifi_pos_register_ops(struct wlan_objmgr_psoc *psoc); 52 53 /** 54 * osif_wifi_pos_deregister_ops - Deregister the wifi pos OS_IF callbacks 55 * @psoc: Pointer to PSOC obj 56 * 57 * Return: QDF_STATUS 58 */ 59 QDF_STATUS 60 osif_wifi_pos_deregister_ops(struct wlan_objmgr_psoc *psoc); 61 #else 62 static inline QDF_STATUS 63 osif_wifi_pos_register_ops(struct wlan_objmgr_psoc *psoc) 64 { 65 return QDF_STATUS_SUCCESS; 66 } 67 68 static inline QDF_STATUS 69 osif_wifi_pos_deregister_ops(struct wlan_objmgr_psoc *psoc) 70 { 71 return QDF_STATUS_SUCCESS; 72 } 73 #endif /* WIFI_POS_CONVERGED */ 74 #endif /* _OS_IF_WIFI_POS_UTILS_H_ */ 75