qcacld-3.0: Add max vdev/pdev/psoc build config options

To reduce hard coding in the driver, add the following build config
options with defaults to the Kbuild:
 * CONFIG_WLAN_MAX_PSOCS
 * CONFIG_WLAN_MAX_PDEVS
 * CONFIG_WLAN_MAX_VDEVS (supercedes CONFIG_SIR_MAX_SUPPORTED_BSS)
 * CONFIG_WLAN_PSOC_MAX_VDEVS
 * CONFIG_WLAN_PDEV_MAX_VDEVS

Change-Id: I14fce4bf34eb511214ad0b31be72336a2620b960
CRs-Fixed: 2393150
This commit is contained in:
Dustin Brown
2019-02-04 14:40:26 -08:00
committed by nshrivas
parent d398b62200
commit a19834ba8b
3 changed files with 17 additions and 9 deletions

17
Kbuild
View File

@@ -2537,9 +2537,20 @@ ifdef CONFIG_CFG_NUM_OF_TDLS_CONN_TABLE_ENTRIES
ccflags-y += -DCFG_TGT_NUM_TDLS_CONN_TABLE_ENTRIES=$(CONFIG_CFG_NUM_OF_TDLS_CONN_TABLE_ENTRIES)
endif
ifdef CONFIG_SIR_MAX_SUPPORTED_BSS
ccflags-y += -DSIR_MAX_SUPPORTED_BSS=$(CONFIG_SIR_MAX_SUPPORTED_BSS)
endif
CONFIG_WLAN_MAX_PSOCS ?= 1
ccflags-y += -DWLAN_MAX_PSOCS=$(CONFIG_WLAN_MAX_PSOCS)
CONFIG_WLAN_MAX_PDEVS ?= 1
ccflags-y += -DWLAN_MAX_PDEVS=$(CONFIG_WLAN_MAX_PDEVS)
CONFIG_WLAN_MAX_VDEVS ?= 5
ccflags-y += -DWLAN_MAX_VDEVS=$(CONFIG_WLAN_MAX_VDEVS)
CONFIG_WLAN_PDEV_MAX_VDEVS ?= $(CONFIG_WLAN_MAX_VDEVS)
ccflags-y += -DWLAN_PDEV_MAX_VDEVS=$(CONFIG_WLAN_PDEV_MAX_VDEVS)
CONFIG_WLAN_PSOC_MAX_VDEVS ?= $(CONFIG_WLAN_MAX_VDEVS)
ccflags-y += -DWLAN_PSOC_MAX_VDEVS=$(CONFIG_WLAN_PSOC_MAX_VDEVS)
ifdef CONFIG_SIR_SAP_MAX_NUM_PEERS
ccflags-y += -DSIR_SAP_MAX_NUM_PEERS=$(CONFIG_SIR_SAP_MAX_NUM_PEERS)

View File

@@ -189,9 +189,8 @@ CONFIG_CFG_NUM_OF_ADDITIONAL_FW_PEERS := 0
# Number of TDLS peers that each Tdls vdev can track
CONFIG_CFG_NUM_OF_TDLS_CONN_TABLE_ENTRIES := 4
#Number of BSS sessions at a time, used for allocating memory should never be
#less then number of vdevs - INI
CONFIG_SIR_MAX_SUPPORTED_BSS := 3
# Number of vdevs supported at one time, used for allocating memory
CONFIG_WLAN_MAX_VDEVS := 3
#Number of STA sessions max connected to our SAP, used for allocating memory
#should never be less then number of max peers - INI

View File

@@ -48,9 +48,7 @@ struct mac_context;
#include "wlan_policy_mgr_api.h"
#include "wlan_tdls_public_structs.h"
#ifndef SIR_MAX_SUPPORTED_BSS
#define SIR_MAX_SUPPORTED_BSS 5
#endif
#define SIR_MAX_SUPPORTED_BSS WLAN_MAX_VDEVS
#define OFFSET_OF(structType, fldName) (&((structType *)0)->fldName)