qcacmn: compiling WDI3 version of IPA
Depreciated IPA APIs are currently getting compiled. To fix this, adding linux kernel version check Change-Id: I2288db34c09d60047c67a5df9081de08a6c2f62b CRs-Fixed: 2927413
This commit is contained in:

committed by
Madan Koyyalamudi

parent
8394348196
commit
9f3b9ca800
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2016-2020 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2016-2021 The Linux Foundation. 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
|
||||
@@ -24,7 +24,8 @@
|
||||
#define _CDP_TXRX_IPA_H_
|
||||
|
||||
#ifdef IPA_OFFLOAD
|
||||
#ifdef CONFIG_IPA_WDI_UNIFIED_API
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 0)) || \
|
||||
defined(CONFIG_IPA_WDI_UNIFIED_API)
|
||||
#include <qdf_ipa_wdi3.h>
|
||||
#else
|
||||
#include <qdf_ipa.h>
|
||||
@@ -359,7 +360,9 @@ cdp_ipa_disable_autonomy(ol_txrx_soc_handle soc, uint8_t pdev_id)
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_IPA_WDI_UNIFIED_API
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 0)) || \
|
||||
defined(CONFIG_IPA_WDI_UNIFIED_API)
|
||||
|
||||
/**
|
||||
* cdp_ipa_setup() - Setup and connect IPA pipes
|
||||
* @soc: data path soc handle
|
||||
|
@@ -33,7 +33,8 @@
|
||||
#include <wdi_event_api.h>
|
||||
|
||||
#ifdef IPA_OFFLOAD
|
||||
#ifdef CONFIG_IPA_WDI_UNIFIED_API
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 0)) || \
|
||||
defined(CONFIG_IPA_WDI_UNIFIED_API)
|
||||
#include <qdf_ipa_wdi3.h>
|
||||
#else
|
||||
#include <qdf_ipa.h>
|
||||
@@ -1586,7 +1587,9 @@ struct cdp_ipa_ops {
|
||||
uint8_t pdev_id);
|
||||
QDF_STATUS (*ipa_disable_autonomy)(struct cdp_soc_t *soc_hdl,
|
||||
uint8_t pdev_id);
|
||||
#ifdef CONFIG_IPA_WDI_UNIFIED_API
|
||||
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 0)) || \
|
||||
defined(CONFIG_IPA_WDI_UNIFIED_API)
|
||||
QDF_STATUS (*ipa_setup)(struct cdp_soc_t *soc_hdl, uint8_t pdev_id,
|
||||
void *ipa_i2w_cb, void *ipa_w2i_cb,
|
||||
void *ipa_wdi_meter_notifier_cb,
|
||||
|
@@ -1759,7 +1759,8 @@ QDF_STATUS dp_ipa_disable_autonomy(struct cdp_soc_t *soc_hdl, uint8_t pdev_id)
|
||||
/* This should be configurable per H/W configuration enable status */
|
||||
#define L3_HEADER_PADDING 2
|
||||
|
||||
#ifdef CONFIG_IPA_WDI_UNIFIED_API
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 0)) || \
|
||||
defined(CONFIG_IPA_WDI_UNIFIED_API)
|
||||
|
||||
#ifndef QCA_LL_TX_FLOW_CONTROL_V2
|
||||
static inline void dp_setup_mcc_sys_pipes(
|
||||
|
@@ -159,7 +159,8 @@ QDF_STATUS dp_ipa_enable_autonomy(struct cdp_soc_t *soc_hdl, uint8_t pdev_id);
|
||||
*/
|
||||
QDF_STATUS dp_ipa_disable_autonomy(struct cdp_soc_t *soc_hdl, uint8_t pdev_id);
|
||||
|
||||
#ifdef CONFIG_IPA_WDI_UNIFIED_API
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 0)) || \
|
||||
defined(CONFIG_IPA_WDI_UNIFIED_API)
|
||||
/**
|
||||
* dp_ipa_setup() - Setup and connect IPA pipes
|
||||
* @soc_hdl - data path soc handle
|
||||
|
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017-2020, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2017-2021, The Linux Foundation. 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 above
|
||||
@@ -286,6 +286,8 @@ typedef void (*qdf_ipa_ready_cb)(void *user_data);
|
||||
/*
|
||||
* Resume / Suspend
|
||||
*/
|
||||
|
||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(5, 10, 0))
|
||||
static inline int qdf_ipa_reset_endpoint(u32 clnt_hdl)
|
||||
{
|
||||
return __qdf_ipa_reset_endpoint(clnt_hdl);
|
||||
@@ -332,15 +334,6 @@ static inline int qdf_ipa_copy_hdr(qdf_ipa_ioc_copy_hdr_t *copy)
|
||||
return __qdf_ipa_copy_hdr(copy);
|
||||
}
|
||||
|
||||
/*
|
||||
* Messaging
|
||||
*/
|
||||
static inline int qdf_ipa_send_msg(qdf_ipa_msg_meta_t *meta, void *buff,
|
||||
ipa_msg_free_fn callback)
|
||||
{
|
||||
return __qdf_ipa_send_msg(meta, buff, callback);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_register_pull_msg(qdf_ipa_msg_meta_t *meta,
|
||||
qdf_ipa_msg_pull_fn callback)
|
||||
{
|
||||
@@ -394,11 +387,6 @@ static inline int qdf_ipa_tx_dp_mul(
|
||||
return __qdf_ipa_tx_dp_mul(dst, data_desc);
|
||||
}
|
||||
|
||||
static inline void qdf_ipa_free_skb(qdf_ipa_rx_data_t *rx_in)
|
||||
{
|
||||
return __qdf_ipa_free_skb(rx_in);;
|
||||
}
|
||||
|
||||
/*
|
||||
* System pipes
|
||||
*/
|
||||
@@ -407,17 +395,6 @@ static inline u16 qdf_ipa_get_smem_restr_bytes(void)
|
||||
return __qdf_ipa_get_smem_restr_bytes();
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_setup_sys_pipe(qdf_ipa_sys_connect_params_t *sys_in,
|
||||
u32 *clnt_hdl)
|
||||
{
|
||||
return __qdf_ipa_setup_sys_pipe(sys_in, clnt_hdl);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_teardown_sys_pipe(u32 clnt_hdl)
|
||||
{
|
||||
return __qdf_ipa_teardown_sys_pipe(clnt_hdl);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_connect_wdi_pipe(qdf_ipa_wdi_in_params_t *in,
|
||||
qdf_ipa_wdi_out_params_t *out)
|
||||
{
|
||||
@@ -455,17 +432,6 @@ static inline int qdf_ipa_uc_wdi_get_dbpa(
|
||||
return __qdf_ipa_uc_wdi_get_dbpa(out);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_uc_reg_rdyCB(
|
||||
qdf_ipa_wdi_uc_ready_params_t *param)
|
||||
{
|
||||
return __qdf_ipa_uc_reg_rdyCB(param);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_uc_dereg_rdyCB(void)
|
||||
{
|
||||
return __qdf_ipa_uc_dereg_rdyCB();
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Resource manager
|
||||
@@ -573,21 +539,11 @@ static inline void qdf_ipa_bam_reg_dump(void)
|
||||
return __qdf_ipa_bam_reg_dump();
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_get_wdi_stats(qdf_ipa_hw_stats_wdi_info_data_t *stats)
|
||||
{
|
||||
return __qdf_ipa_get_wdi_stats(stats);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_get_ep_mapping(qdf_ipa_client_type_t client)
|
||||
{
|
||||
return __qdf_ipa_get_ep_mapping(client);
|
||||
}
|
||||
|
||||
static inline bool qdf_ipa_is_ready(void)
|
||||
{
|
||||
return __qdf_ipa_is_ready();
|
||||
}
|
||||
|
||||
static inline void qdf_ipa_proxy_clk_vote(void)
|
||||
{
|
||||
return __qdf_ipa_proxy_clk_vote();
|
||||
@@ -647,6 +603,28 @@ static inline int qdf_ipa_stop_gsi_channel(u32 clnt_hdl)
|
||||
return __qdf_ipa_stop_gsi_channel(clnt_hdl);
|
||||
}
|
||||
|
||||
#endif
|
||||
static inline void qdf_ipa_free_skb(qdf_ipa_rx_data_t *rx_in)
|
||||
{
|
||||
return __qdf_ipa_free_skb(rx_in);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_uc_reg_rdyCB(
|
||||
qdf_ipa_wdi_uc_ready_params_t *param)
|
||||
{
|
||||
return __qdf_ipa_uc_reg_rdyCB(param);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_uc_dereg_rdyCB(void)
|
||||
{
|
||||
return __qdf_ipa_uc_dereg_rdyCB();
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_get_wdi_stats(qdf_ipa_hw_stats_wdi_info_data_t *stats)
|
||||
{
|
||||
return __qdf_ipa_get_wdi_stats(stats);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_register_ipa_ready_cb(
|
||||
void (*qdf_ipa_ready_cb)(void *user_data),
|
||||
void *user_data)
|
||||
@@ -654,6 +632,31 @@ static inline int qdf_ipa_register_ipa_ready_cb(
|
||||
return __qdf_ipa_register_ipa_ready_cb(qdf_ipa_ready_cb, user_data);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_setup_sys_pipe(qdf_ipa_sys_connect_params_t *sys_in,
|
||||
u32 *clnt_hdl)
|
||||
{
|
||||
return __qdf_ipa_setup_sys_pipe(sys_in, clnt_hdl);
|
||||
}
|
||||
|
||||
static inline int qdf_ipa_teardown_sys_pipe(u32 clnt_hdl)
|
||||
{
|
||||
return __qdf_ipa_teardown_sys_pipe(clnt_hdl);
|
||||
}
|
||||
|
||||
/*
|
||||
* Messaging
|
||||
*/
|
||||
static inline int qdf_ipa_send_msg(qdf_ipa_msg_meta_t *meta, void *buff,
|
||||
ipa_msg_free_fn callback)
|
||||
{
|
||||
return __qdf_ipa_send_msg(meta, buff, callback);
|
||||
}
|
||||
|
||||
static inline bool qdf_ipa_is_ready(void)
|
||||
{
|
||||
return __qdf_ipa_is_ready();
|
||||
}
|
||||
|
||||
#ifdef FEATURE_METERING
|
||||
static inline int qdf_ipa_broadcast_wdi_quota_reach_ind(uint32_t index,
|
||||
uint64_t quota_bytes)
|
||||
|
@@ -27,7 +27,9 @@
|
||||
#include <qdf_ipa.h>
|
||||
#include <i_qdf_ipa_wdi3.h>
|
||||
|
||||
#ifdef CONFIG_IPA_WDI_UNIFIED_API
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 0)) || \
|
||||
defined(CONFIG_IPA_WDI_UNIFIED_API)
|
||||
|
||||
/**
|
||||
* qdf_ipa_wdi_version_t - IPA WDI version
|
||||
*/
|
||||
|
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017-2020, The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2017-2021, The Linux Foundation. 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 above
|
||||
@@ -560,6 +560,7 @@ typedef struct ipa_wlan_hdr_attrib_val __qdf_ipa_wlan_hdr_attrib_val_t;
|
||||
#define IPA_LAN_RX_NAPI_SUPPORT
|
||||
#endif
|
||||
|
||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(5, 10, 0))
|
||||
/*
|
||||
* Resume / Suspend
|
||||
*/
|
||||
@@ -609,15 +610,6 @@ static inline int __qdf_ipa_copy_hdr(struct ipa_ioc_copy_hdr *copy)
|
||||
return ipa_copy_hdr(copy);
|
||||
}
|
||||
|
||||
/*
|
||||
* Messaging
|
||||
*/
|
||||
static inline int __qdf_ipa_send_msg(struct ipa_msg_meta *meta, void *buff,
|
||||
ipa_msg_free_fn callback)
|
||||
{
|
||||
return ipa_send_msg(meta, buff, callback);
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_register_pull_msg(struct ipa_msg_meta *meta,
|
||||
ipa_msg_pull_fn callback)
|
||||
{
|
||||
@@ -671,11 +663,6 @@ static inline int __qdf_ipa_tx_dp_mul(
|
||||
return ipa_tx_dp_mul(dst, data_desc);
|
||||
}
|
||||
|
||||
static inline void __qdf_ipa_free_skb(struct ipa_rx_data *rx_in)
|
||||
{
|
||||
return ipa_free_skb(rx_in);;
|
||||
}
|
||||
|
||||
/*
|
||||
* System pipes
|
||||
*/
|
||||
@@ -684,17 +671,6 @@ static inline u16 __qdf_ipa_get_smem_restr_bytes(void)
|
||||
return ipa_get_smem_restr_bytes();
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_setup_sys_pipe(struct ipa_sys_connect_params *sys_in,
|
||||
u32 *clnt_hdl)
|
||||
{
|
||||
return ipa_setup_sys_pipe(sys_in, clnt_hdl);
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_teardown_sys_pipe(u32 clnt_hdl)
|
||||
{
|
||||
return ipa_teardown_sys_pipe(clnt_hdl);
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_connect_wdi_pipe(struct ipa_wdi_in_params *in,
|
||||
struct ipa_wdi_out_params *out)
|
||||
{
|
||||
@@ -732,18 +708,6 @@ static inline int __qdf_ipa_uc_wdi_get_dbpa(
|
||||
return ipa_uc_wdi_get_dbpa(out);
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_uc_reg_rdyCB(
|
||||
struct ipa_wdi_uc_ready_params *param)
|
||||
{
|
||||
return ipa_uc_reg_rdyCB(param);
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_uc_dereg_rdyCB(void)
|
||||
{
|
||||
return ipa_uc_dereg_rdyCB();
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* Resource manager
|
||||
*/
|
||||
@@ -850,21 +814,11 @@ static inline void __qdf_ipa_bam_reg_dump(void)
|
||||
return ipa_bam_reg_dump();
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_get_wdi_stats(struct IpaHwStatsWDIInfoData_t *stats)
|
||||
{
|
||||
return ipa_get_wdi_stats(stats);
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_get_ep_mapping(enum ipa_client_type client)
|
||||
{
|
||||
return ipa_get_ep_mapping(client);
|
||||
}
|
||||
|
||||
static inline bool __qdf_ipa_is_ready(void)
|
||||
{
|
||||
return ipa_is_ready();
|
||||
}
|
||||
|
||||
static inline void __qdf_ipa_proxy_clk_vote(void)
|
||||
{
|
||||
return ipa_proxy_clk_vote();
|
||||
@@ -938,6 +892,27 @@ static inline int __qdf_ipa_stop_gsi_channel(u32 clnt_hdl)
|
||||
return ipa_stop_gsi_channel(clnt_hdl);
|
||||
}
|
||||
|
||||
#endif
|
||||
static inline void __qdf_ipa_free_skb(struct ipa_rx_data *rx_in)
|
||||
{
|
||||
return ipa_free_skb(rx_in);
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_get_wdi_stats(struct IpaHwStatsWDIInfoData_t *stats)
|
||||
{
|
||||
return ipa_get_wdi_stats(stats);
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_uc_reg_rdyCB(struct ipa_wdi_uc_ready_params *param)
|
||||
{
|
||||
return ipa_uc_reg_rdyCB(param);
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_uc_dereg_rdyCB(void)
|
||||
{
|
||||
return ipa_uc_dereg_rdyCB();
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_register_ipa_ready_cb(
|
||||
void (*ipa_ready_cb)(void *user_data),
|
||||
void *user_data)
|
||||
@@ -945,6 +920,32 @@ static inline int __qdf_ipa_register_ipa_ready_cb(
|
||||
return ipa_register_ipa_ready_cb(ipa_ready_cb, user_data);
|
||||
}
|
||||
|
||||
static inline
|
||||
int __qdf_ipa_setup_sys_pipe(struct ipa_sys_connect_params *sys_in,
|
||||
u32 *clnt_hdl)
|
||||
{
|
||||
return ipa_setup_sys_pipe(sys_in, clnt_hdl);
|
||||
}
|
||||
|
||||
static inline int __qdf_ipa_teardown_sys_pipe(u32 clnt_hdl)
|
||||
{
|
||||
return ipa_teardown_sys_pipe(clnt_hdl);
|
||||
}
|
||||
|
||||
/*
|
||||
* Messaging
|
||||
*/
|
||||
static inline int __qdf_ipa_send_msg(struct ipa_msg_meta *meta, void *buff,
|
||||
ipa_msg_free_fn callback)
|
||||
{
|
||||
return ipa_send_msg(meta, buff, callback);
|
||||
}
|
||||
|
||||
static inline bool __qdf_ipa_is_ready(void)
|
||||
{
|
||||
return ipa_is_ready();
|
||||
}
|
||||
|
||||
#ifdef FEATURE_METERING
|
||||
static inline int __qdf_ipa_broadcast_wdi_quota_reach_ind(uint32_t index,
|
||||
uint64_t quota_bytes)
|
||||
|
@@ -27,7 +27,8 @@
|
||||
#include <qdf_status.h> /* QDF_STATUS */
|
||||
#include <linux/ipa_wdi3.h>
|
||||
|
||||
#ifdef CONFIG_IPA_WDI_UNIFIED_API
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 10, 0)) || \
|
||||
defined(CONFIG_IPA_WDI_UNIFIED_API)
|
||||
|
||||
/**
|
||||
* __qdf_ipa_wdi_version_t - IPA WDI version
|
||||
|
Reference in New Issue
Block a user