diff --git a/dp/wifi3.0/dp_ipa.c b/dp/wifi3.0/dp_ipa.c index 95bcc1bdaf..810a75e0f5 100644 --- a/dp/wifi3.0/dp_ipa.c +++ b/dp/wifi3.0/dp_ipa.c @@ -15,8 +15,6 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#ifdef IPA_OFFLOAD - #include #include #include @@ -42,6 +40,8 @@ #include "dp_txrx_wds.h" #endif +#ifdef IPA_OFFLOAD + /* Hard coded config parameters until dp_ops_cfg.cfg_attach implemented */ #define CFG_IPA_UC_TX_BUF_SIZE_DEFAULT (2048) diff --git a/ipa/core/inc/wlan_ipa_core.h b/ipa/core/inc/wlan_ipa_core.h index f68044faed..009302ea69 100644 --- a/ipa/core/inc/wlan_ipa_core.h +++ b/ipa/core/inc/wlan_ipa_core.h @@ -20,11 +20,11 @@ #ifndef _WLAN_IPA_CORE_H_ #define _WLAN_IPA_CORE_H_ -#ifdef IPA_OFFLOAD - #include "wlan_ipa_priv.h" #include "wlan_ipa_public_struct.h" +#ifdef IPA_OFFLOAD + /** * wlan_ipa_is_enabled() - Is IPA enabled? * @ipa_cfg: IPA config diff --git a/ipa/core/inc/wlan_ipa_main.h b/ipa/core/inc/wlan_ipa_main.h index 186c90a3e3..2cc49cc495 100644 --- a/ipa/core/inc/wlan_ipa_main.h +++ b/ipa/core/inc/wlan_ipa_main.h @@ -24,13 +24,12 @@ #ifndef _WLAN_IPA_MAIN_H_ #define _WLAN_IPA_MAIN_H_ -#ifdef IPA_OFFLOAD - #include #include #include #include +#ifdef IPA_OFFLOAD /* Declare a variable for IPA instancess added based on pdev */ extern uint8_t g_instances_added; #define IPA_INVALID_HDL 0xFF diff --git a/ipa/core/inc/wlan_ipa_priv.h b/ipa/core/inc/wlan_ipa_priv.h index 9d940cc014..606222f7ca 100644 --- a/ipa/core/inc/wlan_ipa_priv.h +++ b/ipa/core/inc/wlan_ipa_priv.h @@ -25,8 +25,6 @@ #ifndef _WLAN_IPA_PRIV_STRUCT_H_ #define _WLAN_IPA_PRIV_STRUCT_H_ -#ifdef IPA_OFFLOAD - #include #include @@ -48,6 +46,7 @@ #include "cdp_txrx_ipa.h" #endif +#ifdef IPA_OFFLOAD #define WLAN_IPA_RX_INACTIVITY_MSEC_DELAY 1000 #define WLAN_IPA_UC_WLAN_8023_HDR_SIZE 14 diff --git a/ipa/core/src/wlan_ipa_core.c b/ipa/core/src/wlan_ipa_core.c index 693d31d635..119275403f 100644 --- a/ipa/core/src/wlan_ipa_core.c +++ b/ipa/core/src/wlan_ipa_core.c @@ -30,6 +30,7 @@ #include #include #include +#ifdef IPA_OFFLOAD #ifdef IPA_OPT_WIFI_DP #include "init_deinit_lmac.h" #endif @@ -5208,3 +5209,4 @@ void wlan_ipa_wdi_opt_dpath_notify_flt_add_rem_cb(int flt0_rslt, int flt1_rslt) qdf_event_set(&ipa_obj->ipa_flt_evnt); } #endif /* IPA_OPT_WIFI_DP */ +#endif /* IPA_OFFLOAD */ diff --git a/ipa/core/src/wlan_ipa_main.c b/ipa/core/src/wlan_ipa_main.c index bb0c6639a1..3a80b50c1c 100644 --- a/ipa/core/src/wlan_ipa_main.c +++ b/ipa/core/src/wlan_ipa_main.c @@ -1,6 +1,6 @@ /* * Copyright (c) 2018-2021 The Linux Foundation. All rights reserved. - * Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved. + * Copyright (c) 2021-2023 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 @@ -27,6 +27,7 @@ #include "cfg_ucfg_api.h" #include "wlan_ipa_obj_mgmt_api.h" +#ifdef IPA_OFFLOAD static struct wlan_ipa_config *g_ipa_config; static bool g_ipa_hw_support; static bool g_ipa_pld_enable = true; @@ -911,3 +912,4 @@ bool ipa_is_wds_enabled(void) { return g_ipa_config ? g_ipa_config->ipa_wds : 0; } +#endif /* IPA_OFFLOAD */ diff --git a/ipa/core/src/wlan_ipa_rm.c b/ipa/core/src/wlan_ipa_rm.c index c80d93fef8..2670f5e569 100644 --- a/ipa/core/src/wlan_ipa_rm.c +++ b/ipa/core/src/wlan_ipa_rm.c @@ -25,6 +25,7 @@ #include "host_diag_core_event.h" #include "wlan_reg_services_api.h" +#ifdef IPA_OFFLOAD QDF_STATUS wlan_ipa_set_perf_level(struct wlan_ipa_priv *ipa_ctx, uint64_t tx_packets, uint64_t rx_packets) @@ -542,3 +543,4 @@ bool wlan_ipa_is_rm_released(struct wlan_ipa_priv *ipa_ctx) return true; } #endif /* CONFIG_IPA_WDI_UNIFIED_API */ +#endif diff --git a/ipa/core/src/wlan_ipa_stats.c b/ipa/core/src/wlan_ipa_stats.c index bb13b4b91a..5701eedfb4 100644 --- a/ipa/core/src/wlan_ipa_stats.c +++ b/ipa/core/src/wlan_ipa_stats.c @@ -23,6 +23,7 @@ #include "cdp_txrx_ipa.h" #include "qdf_platform.h" +#ifdef IPA_OFFLOAD /** * wlan_ipa_uc_rt_debug_host_fill - fill rt debug buffer * @ctext: pointer to ipa context. @@ -1032,3 +1033,4 @@ void wlan_ipa_wdi_meter_notifier_cb(qdf_ipa_wdi_meter_evt_type_t evt, qdf_op_unprotect(op_sync); } #endif /* FEATURE_METERING */ +#endif /* IPA_OFFLOAD */ diff --git a/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c b/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c index e3c0770545..3517230a29 100644 --- a/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c +++ b/ipa/dispatcher/src/wlan_ipa_obj_mgmt_api.c @@ -1,6 +1,6 @@ /* * Copyright (c) 2018, 2020-2021 The Linux Foundation. All rights reserved. - * Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved. + * Copyright (c) 2021-2023 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 @@ -29,6 +29,7 @@ #include "qdf_platform.h" #include "qdf_module.h" +#ifdef IPA_OFFLOAD /* This is as per IPA capbility */ #define MAX_INSTANCES_SUPPORTED 2 @@ -370,3 +371,4 @@ bool wlan_ipa_is_vlan_enabled(void) } qdf_export_symbol(wlan_ipa_is_vlan_enabled); +#endif diff --git a/ipa/dispatcher/src/wlan_ipa_tgt_api.c b/ipa/dispatcher/src/wlan_ipa_tgt_api.c index b6438bedd4..16fb90a6c1 100644 --- a/ipa/dispatcher/src/wlan_ipa_tgt_api.c +++ b/ipa/dispatcher/src/wlan_ipa_tgt_api.c @@ -1,6 +1,6 @@ /* * Copyright (c) 2018, 2020-2021 The Linux Foundation. All rights reserved. - * Copyright (c) 2021 Qualcomm Innovation Center, Inc. All rights reserved. + * Copyright (c) 2021, 2023 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 @@ -27,6 +27,7 @@ #include #include +#ifdef IPA_OFFLOAD QDF_STATUS tgt_ipa_uc_offload_enable_disable(struct wlan_objmgr_pdev *pdev, struct ipa_uc_offload_control_params *req) { @@ -79,4 +80,4 @@ tgt_ipa_intrabss_enable_disable(struct wlan_objmgr_pdev *pdev, IPA_EXIT(); return status; } - +#endif diff --git a/ipa/dispatcher/src/wlan_ipa_ucfg_api.c b/ipa/dispatcher/src/wlan_ipa_ucfg_api.c index b3740d6bda..ee91bd68f9 100644 --- a/ipa/dispatcher/src/wlan_ipa_ucfg_api.c +++ b/ipa/dispatcher/src/wlan_ipa_ucfg_api.c @@ -1,6 +1,6 @@ /* * Copyright (c) 2018-2021 The Linux Foundation. All rights reserved. - * Copyright (c) 2021-2022 Qualcomm Innovation Center, Inc. All rights reserved. + * Copyright (c) 2021-2023 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 @@ -25,6 +25,7 @@ #include "cfg_ucfg_api.h" #include "qdf_module.h" +#ifdef IPA_OFFLOAD void ucfg_ipa_set_pld_enable(bool flag) { ipa_set_pld_enable(flag); @@ -361,3 +362,4 @@ bool ucfg_ipa_is_wds_enabled(void) } qdf_export_symbol(ucfg_ipa_is_wds_enabled); +#endif diff --git a/target_if/ipa/src/target_if_ipa.c b/target_if/ipa/src/target_if_ipa.c index 3dbe19713e..a509836b03 100644 --- a/target_if/ipa/src/target_if_ipa.c +++ b/target_if/ipa/src/target_if_ipa.c @@ -30,6 +30,7 @@ #include #include +#ifdef IPA_OFFLOAD /** * target_if_ipa_uc_offload_control_req() - send IPA offload control to FW * @psoc: pointer to PSOC object @@ -89,3 +90,4 @@ target_if_ipa_register_tx_ops(struct wlan_lmac_if_tx_ops *tx_ops) return QDF_STATUS_SUCCESS; } +#endif