qcacmn: Export objmgr APIs and add lmac_if registration APIs

Export objmgr APIs to be used by SON module to register
and unregister create/destroy handler.
Also add lmac_if API to register lmac_if ops from SON
module.

Change-Id: Id4c19807792b9f7b46387ae907f853151e4e28c6
CRs-Fixed: 3118986
This commit is contained in:
nakul kachhwaha
2022-01-27 19:00:43 +05:30
gecommit door Madan Koyyalamudi
bovenliggende 211fb195c9
commit 6c2a986833
6 gewijzigde bestanden met toevoegingen van 66 en 8 verwijderingen

Bestand weergeven

@@ -1,6 +1,6 @@
/*
* Copyright (c) 2016-2021 The Linux Foundation. All rights reserved.
*
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@@ -108,6 +108,7 @@ static void wlan_iot_sim_register_rx_ops(struct wlan_lmac_if_rx_ops *rx_ops)
}
#endif
#if defined(QCA_SUPPORT_SON) || defined(WLAN_FEATURE_SON)
/* Function pointer for son rx_ops registration function */
void (*wlan_lmac_if_son_rx_ops)(struct wlan_lmac_if_rx_ops *rx_ops);
@@ -129,6 +130,16 @@ static void wlan_son_register_rx_ops(struct wlan_lmac_if_rx_ops *rx_ops)
qdf_info("\n***** SON MODULE NOT LOADED *****\n");
}
void wlan_lmac_if_son_mod_register_rx_ops(struct wlan_lmac_if_rx_ops *rx_ops)
{
wlan_son_register_rx_ops(rx_ops);
}
#else
static void wlan_son_register_rx_ops(struct wlan_lmac_if_rx_ops *rx_ops)
{
}
#endif
/**
* wlan_global_lmac_if_rx_ops_register() - Global lmac_if
* rx handler register

Bestand weergeven

@@ -1,5 +1,6 @@
/*
* Copyright (c) 2014-2021 The Linux Foundation. All rights reserved.
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@@ -906,6 +907,8 @@ void qdf_lock_stats_cookie_create(struct lock_stats *stats,
stats->cookie->u.cookie.line = line;
}
qdf_export_symbol(qdf_lock_stats_cookie_create);
void qdf_lock_stats_cookie_destroy(struct lock_stats *stats)
{
struct qdf_lock_cookie *cookie = stats->cookie;
@@ -927,4 +930,6 @@ void qdf_lock_stats_cookie_destroy(struct lock_stats *stats)
qdf_put_lock_cookie(cookie);
}
qdf_export_symbol(qdf_lock_stats_cookie_destroy);
#endif

Bestand weergeven

@@ -1,6 +1,6 @@
/*
* Copyright (c) 2016-2021 The Linux Foundation. All rights reserved.
* Copyright (c) 2021 Qualcomm Innovation Center, Inc. All rights reserved.
* Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@@ -640,6 +640,7 @@ QDF_STATUS wlan_objmgr_register_peer_create_handler(
return QDF_STATUS_SUCCESS;
}
qdf_export_symbol(wlan_objmgr_register_peer_create_handler);
QDF_STATUS wlan_objmgr_unregister_peer_create_handler(
enum wlan_umac_comp_id id,
@@ -667,6 +668,8 @@ QDF_STATUS wlan_objmgr_unregister_peer_create_handler(
return QDF_STATUS_SUCCESS;
}
qdf_export_symbol(wlan_objmgr_unregister_peer_create_handler);
QDF_STATUS wlan_objmgr_register_peer_destroy_handler(
enum wlan_umac_comp_id id,
wlan_objmgr_peer_destroy_handler handler,
@@ -693,6 +696,8 @@ QDF_STATUS wlan_objmgr_register_peer_destroy_handler(
return QDF_STATUS_SUCCESS;
}
qdf_export_symbol(wlan_objmgr_register_peer_destroy_handler);
QDF_STATUS wlan_objmgr_unregister_peer_destroy_handler(
enum wlan_umac_comp_id id,
wlan_objmgr_peer_destroy_handler handler,
@@ -719,6 +724,8 @@ QDF_STATUS wlan_objmgr_unregister_peer_destroy_handler(
return QDF_STATUS_SUCCESS;
}
qdf_export_symbol(wlan_objmgr_unregister_peer_destroy_handler);
QDF_STATUS wlan_objmgr_register_peer_status_handler(
enum wlan_umac_comp_id id,
wlan_objmgr_peer_status_handler handler,

Bestand weergeven

@@ -1,6 +1,6 @@
/*
* Copyright (c) 2016-2021 The Linux Foundation. All rights reserved.
* Copyright (c) 2021 Qualcomm Innovation Center, Inc. All rights reserved.
* Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@@ -617,6 +617,8 @@ QDF_STATUS wlan_objmgr_peer_component_obj_attach(
return QDF_STATUS_SUCCESS;
}
qdf_export_symbol(wlan_objmgr_peer_component_obj_attach);
QDF_STATUS wlan_objmgr_peer_component_obj_detach(
struct wlan_objmgr_peer *peer,
enum wlan_umac_comp_id id,
@@ -681,6 +683,7 @@ QDF_STATUS wlan_objmgr_peer_component_obj_detach(
return QDF_STATUS_SUCCESS;
}
qdf_export_symbol(wlan_objmgr_peer_component_obj_detach);
QDF_STATUS wlan_objmgr_trigger_peer_comp_priv_object_creation(
struct wlan_objmgr_peer *peer,

Bestand weergeven

@@ -558,6 +558,8 @@ QDF_STATUS wlan_objmgr_iterate_peerobj_list(
return QDF_STATUS_SUCCESS;
}
qdf_export_symbol(wlan_objmgr_iterate_peerobj_list);
/**
** APIs to get a peer with given mac in a vdev
*/

Bestand weergeven

@@ -2153,21 +2153,40 @@ struct wlan_lmac_if_green_ap_rx_ops {
* struct wlan_lmac_if_rx_ops - south bound rx function pointers
* @mgmt_txrx_tx_ops: mgmt txrx rx ops
* @scan: scan rx ops
* @dfs_rx_ops: dfs rx ops.
* @son_rx_ops: son rx ops
* @p2p: p2p rx ops
* @iot_sim_rx_ops: iot simulation rx ops
* @atf_rx_ops: air time fairness rx ops
* @cp_stats_rx_ops: cp stats rx ops
* @dfs_rx_ops: dfs rx ops.
* @dcs_rx_ops: dcs rx ops
* @sa_api_rx_ops: sa api rx ops
* @cfr_rx_ops: cfr rx ops
* @sptrl_rx_ops: spectral rx ops
* @crypto_rx_ops: crypto rx ops
* @wifi_pos_rx_ops: wifi positioning rx ops
* @reg_rx_ops: regulatory rx ops
* @dfs_rx_ops: dfs rx ops
* @tdls_rx_ops: tdls rx ops
* @fd_rx_ops: fils rx ops
* @mops: mlme rx ops
* @green_ap_rx_ops: green ap rx ops
* @ftm_rx_ops: ftm rx ops
* @mlo_rx_ops: mlo rx ops
*
* Callback function tabled to be registered with lmac/wmi.
* lmac will use the functional table to send events/frames to umac
*/
struct wlan_lmac_if_rx_ops {
/* Components to declare function pointers required by the module
/**
* Components to declare function pointers required by the module
* in component specific structure.
* The component specific ops structure can be declared in this file
* only
*/
struct wlan_lmac_if_mgmt_txrx_rx_ops mgmt_txrx_rx_ops;
struct wlan_lmac_if_scan_rx_ops scan;
struct wlan_lmac_if_mgmt_txrx_rx_ops mgmt_txrx_rx_ops;
struct wlan_lmac_if_scan_rx_ops scan;
struct wlan_lmac_if_son_rx_ops son_rx_ops;
#ifdef CONVERGED_P2P_ENABLE
struct wlan_lmac_if_p2p_rx_ops p2p;
@@ -2217,7 +2236,6 @@ struct wlan_lmac_if_rx_ops {
#endif
struct wlan_lmac_if_ftm_rx_ops ftm_rx_ops;
struct wlan_lmac_if_son_rx_ops son_rx_ops;
#ifdef WLAN_FEATURE_11BE_MLO
struct wlan_lmac_if_mlo_rx_ops mlo_rx_ops;
#endif
@@ -2230,4 +2248,16 @@ struct wlan_lmac_if_rx_ops {
*/
extern QDF_STATUS (*wlan_lmac_if_umac_tx_ops_register)
(struct wlan_lmac_if_tx_ops *tx_ops);
#ifdef WLAN_FEATURE_SON
/**
* wlan_lmac_if_son_mod_register_rx_ops() - SON Module lmac_if rx_ops
* registration API
* @rx_ops: lmac_if rx_ops function pointer table
*
* Function to register SON rx_ops with lmac_if.
*
* Return: void
*/
void wlan_lmac_if_son_mod_register_rx_ops(struct wlan_lmac_if_rx_ops *rx_ops);
#endif
#endif /* _WLAN_LMAC_IF_DEF_H_ */