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.c
19 * This file defines the important functions pertinent to wifi positioning
20 * component's os_if layer.
21 */
22
23 #include "wlan_objmgr_psoc_obj.h"
24 #include "os_if_wifi_pos_utils.h"
25 #include "wifi_pos_ucfg_i.h"
26 #include "os_if_wifi_pos.h"
27
28 #if defined(WIFI_POS_CONVERGED) && defined(WLAN_FEATURE_RTT_11AZ_SUPPORT)
29 static struct wifi_pos_osif_ops osif_ops = {
30 .osif_initiate_pasn_cb = os_if_wifi_pos_initiate_pasn_auth,
31 };
32
33 QDF_STATUS
osif_wifi_pos_register_ops(struct wlan_objmgr_psoc * psoc)34 osif_wifi_pos_register_ops(struct wlan_objmgr_psoc *psoc)
35 {
36 return ucfg_wifi_pos_register_osif_callbacks(psoc, &osif_ops);
37 }
38
39 QDF_STATUS
osif_wifi_pos_deregister_ops(struct wlan_objmgr_psoc * psoc)40 osif_wifi_pos_deregister_ops(struct wlan_objmgr_psoc *psoc)
41 {
42 return ucfg_wifi_pos_deregister_osif_callbacks(psoc);
43 }
44 #endif
45