From 4a6c3e8568c204cf359c048e568676c6675e1ccd Mon Sep 17 00:00:00 2001 From: Vevek Venkatesan Date: Mon, 24 Jun 2019 14:29:19 +0530 Subject: [PATCH] qcacmn: CONFIG_MCL cleanup in cfg module Put MCL specific cfg default values under feaature flag WLAN_MAX_PDEVS. Change-Id: If34c10ca37e67fbd5fa36d04059be79600c3c328 CRs-Fixed: 2477486 --- dp/wifi3.0/dp_types.h | 2 +- wlan_cfg/cfg_dp.h | 4 +--- wlan_cfg/wlan_cfg.c | 4 ++-- wlan_cfg/wlan_cfg.h | 4 ++-- 4 files changed, 6 insertions(+), 8 deletions(-) diff --git a/dp/wifi3.0/dp_types.h b/dp/wifi3.0/dp_types.h index 9527782de3..54c1cae426 100644 --- a/dp/wifi3.0/dp_types.h +++ b/dp/wifi3.0/dp_types.h @@ -71,7 +71,7 @@ #define MAX_MON_LINK_DESC_BANKS 2 #define DP_VDEV_ALL 0xff -#if defined(CONFIG_MCL) +#if defined(WLAN_MAX_PDEVS) && (WLAN_MAX_PDEVS == 1) #define MAX_PDEV_CNT 1 #else #define MAX_PDEV_CNT 3 diff --git a/wlan_cfg/cfg_dp.h b/wlan_cfg/cfg_dp.h index 402bba6cf5..40e64e7557 100644 --- a/wlan_cfg/cfg_dp.h +++ b/wlan_cfg/cfg_dp.h @@ -38,7 +38,6 @@ #define WLAN_CFG_NUM_TCL_DATA_RINGS_MIN 3 #define WLAN_CFG_NUM_TCL_DATA_RINGS_MAX 3 -#ifdef CONFIG_MCL #if defined(QCA_LL_TX_FLOW_CONTROL_V2) || \ defined(QCA_LL_PDEV_TX_FLOW_CONTROL) #define WLAN_CFG_TX_FLOW_START_QUEUE_OFFSET 10 @@ -47,12 +46,11 @@ #define WLAN_CFG_TX_FLOW_START_QUEUE_OFFSET 0 #define WLAN_CFG_TX_FLOW_STOP_QUEUE_TH 0 #endif -#endif #define WLAN_CFG_PER_PDEV_TX_RING_MIN 0 #define WLAN_CFG_PER_PDEV_TX_RING_MAX 1 -#ifdef CONFIG_MCL +#if defined(WLAN_MAX_PDEVS) && (WLAN_MAX_PDEVS == 1) #define WLAN_CFG_PER_PDEV_RX_RING 0 #define WLAN_CFG_PER_PDEV_LMAC_RING 0 #define WLAN_LRO_ENABLE 0 diff --git a/wlan_cfg/wlan_cfg.c b/wlan_cfg/wlan_cfg.c index 44a5ffb8e6..0e416cf4d1 100644 --- a/wlan_cfg/wlan_cfg.c +++ b/wlan_cfg/wlan_cfg.c @@ -90,7 +90,7 @@ #define WLAN_CFG_HOST2RXDMA_RING_MASK_2 0x4 #define WLAN_CFG_HOST2RXDMA_RING_MASK_3 0x0 -#ifdef CONFIG_MCL +#if defined(WLAN_MAX_PDEVS) && (WLAN_MAX_PDEVS == 1) static const int tx_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS] = { WLAN_CFG_TX_RING_MASK_0, 0, 0, 0, 0, 0, 0}; @@ -201,7 +201,7 @@ static const int reo_status_ring_mask[WLAN_CFG_INT_NUM_CONTEXTS] = { WLAN_CFG_REO_STATUS_RING_MASK_1, WLAN_CFG_REO_STATUS_RING_MASK_2, WLAN_CFG_REO_STATUS_RING_MASK_3}; -#endif /*CONFIG_MCL*/ +#endif /* MAX_PDEV_CNT == 1 */ /** * g_wlan_srng_cfg[] - Per ring_type specific configuration diff --git a/wlan_cfg/wlan_cfg.h b/wlan_cfg/wlan_cfg.h index a50fcc016f..4c575631e9 100644 --- a/wlan_cfg/wlan_cfg.h +++ b/wlan_cfg/wlan_cfg.h @@ -23,7 +23,7 @@ * Temporary place holders. These should come either from target config * or platform configuration */ -#if defined(CONFIG_MCL) +#if defined(WLAN_MAX_PDEVS) && (WLAN_MAX_PDEVS == 1) #define WLAN_CFG_DST_RING_CACHED_DESC 0 #define MAX_PDEV_CNT 1 #define WLAN_CFG_INT_NUM_CONTEXTS 7 @@ -56,7 +56,7 @@ #define MAX_RX_MAC_RINGS 2 /* DP process status */ -#ifdef CONFIG_MCL +#if defined(MAX_PDEV_CNT) && (MAX_PDEV_CNT == 1) #define CONFIG_PROCESS_RX_STATUS 1 #define CONFIG_PROCESS_TX_STATUS 1 #else