qcacld-3.0: add support to remove the ftm from configuration
Phase 1, after ftm componentization, we could now support to remove the ftm related components when FTM is disable from the build configuration. Size changes: after removing the ftm related binaries, we could save 15KB from module size. Change-Id: Ib363f1d6204b07947a46f32673c4f8ad6fb3dbd3 CRs-fixed: 2258441
This commit is contained in:
10
Kbuild
10
Kbuild
@@ -682,16 +682,22 @@ FTM_INC := -I$(FTM_DISP_INC) \
|
|||||||
-I$(OS_IF_FTM_INC) \
|
-I$(OS_IF_FTM_INC) \
|
||||||
-I$(TARGET_IF_FTM_INC)
|
-I$(TARGET_IF_FTM_INC)
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_QCA_WIFI_FTM), y)
|
||||||
FTM_OBJS := $(FTM_DISP_SRC)/wlan_ftm_init_deinit.o \
|
FTM_OBJS := $(FTM_DISP_SRC)/wlan_ftm_init_deinit.o \
|
||||||
$(FTM_DISP_SRC)/wlan_ftm_ucfg_api.o \
|
$(FTM_DISP_SRC)/wlan_ftm_ucfg_api.o \
|
||||||
$(FTM_CORE_SRC)/wlan_ftm_svc.o \
|
$(FTM_CORE_SRC)/wlan_ftm_svc.o \
|
||||||
$(OS_IF_FTM_SRC)/wlan_cfg80211_ftm.o \
|
|
||||||
$(TARGET_IF_FTM_SRC)/target_if_ftm.o
|
$(TARGET_IF_FTM_SRC)/target_if_ftm.o
|
||||||
|
|
||||||
|
ifeq ($(QCA_WIFI_FTM_NL80211), y)
|
||||||
|
FTM_OBJS += $(OS_IF_FTM_SRC)/wlan_cfg80211_ftm.o
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq ($(CONFIG_LINUX_QCMBR), y)
|
ifeq ($(CONFIG_LINUX_QCMBR), y)
|
||||||
FTM_OBJS += $(OS_IF_FTM_SRC)/wlan_ioctl_ftm.o
|
FTM_OBJS += $(OS_IF_FTM_SRC)/wlan_ioctl_ftm.o
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
endif
|
||||||
|
|
||||||
############# UMAC_CMN_SERVICES ############
|
############# UMAC_CMN_SERVICES ############
|
||||||
UMAC_COMMON_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/cmn_defs/inc \
|
UMAC_COMMON_INC := -I$(WLAN_COMMON_INC)/umac/cmn_services/cmn_defs/inc \
|
||||||
-I$(WLAN_COMMON_INC)/umac/cmn_services/utils/inc
|
-I$(WLAN_COMMON_INC)/umac/cmn_services/utils/inc
|
||||||
@@ -2031,6 +2037,8 @@ cppflags-$(CONFIG_TX_CREDIT_RECLAIM_SUPPORT) += -DTX_CREDIT_RECLAIM_SUPPORT
|
|||||||
|
|
||||||
#Enable FTM support
|
#Enable FTM support
|
||||||
cppflags-$(CONFIG_QCA_WIFI_FTM) += -DQCA_WIFI_FTM
|
cppflags-$(CONFIG_QCA_WIFI_FTM) += -DQCA_WIFI_FTM
|
||||||
|
cppflags-$(CONFIG_NL80211_TESTMODE) += -DQCA_WIFI_FTM_NL80211
|
||||||
|
cppflags-$(CONFIG_LINUX_QCMBR) += -DLINUX_QCMBR -DQCA_WIFI_FTM_IOCTL
|
||||||
|
|
||||||
#Enable Checksum Offload support
|
#Enable Checksum Offload support
|
||||||
cppflags-$(CONFIG_CHECKSUM_OFFLOAD) += -DCHECKSUM_OFFLOAD
|
cppflags-$(CONFIG_CHECKSUM_OFFLOAD) += -DCHECKSUM_OFFLOAD
|
||||||
|
@@ -448,6 +448,21 @@ CONFIG_TX_CREDIT_RECLAIM_SUPPORT := n
|
|||||||
#Enable FTM support
|
#Enable FTM support
|
||||||
CONFIG_QCA_WIFI_FTM := y
|
CONFIG_QCA_WIFI_FTM := y
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_QCA_WIFI_FTM), y)
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_NL80211_TESTMODE), y)
|
||||||
|
QCA_WIFI_FTM_NL80211 :=y
|
||||||
|
else
|
||||||
|
QCA_WIFI_FTM_NL80211 :=n
|
||||||
|
endif
|
||||||
|
CONFIG_LINUX_QCMBR :=y
|
||||||
|
|
||||||
|
else
|
||||||
|
QCA_WIFI_FTM_NL80211 :=n
|
||||||
|
CONFIG_LINUX_QCMBR :=n
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
#Enable Checksum Offload
|
#Enable Checksum Offload
|
||||||
CONFIG_CHECKSUM_OFFLOAD := y
|
CONFIG_CHECKSUM_OFFLOAD := y
|
||||||
|
|
||||||
|
@@ -12876,6 +12876,19 @@ static bool is_epping_mode_supported(void)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef QCA_WIFI_FTM
|
||||||
|
static bool is_ftm_mode_supported(void)
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
static bool is_ftm_mode_supported(void)
|
||||||
|
{
|
||||||
|
pr_err("FTM mode not supported!");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* is_con_mode_valid() check con mode is valid or not
|
* is_con_mode_valid() check con mode is valid or not
|
||||||
* @mode: global con mode
|
* @mode: global con mode
|
||||||
@@ -12890,6 +12903,7 @@ static bool is_con_mode_valid(enum QDF_GLOBAL_MODE mode)
|
|||||||
case QDF_GLOBAL_EPPING_MODE:
|
case QDF_GLOBAL_EPPING_MODE:
|
||||||
return is_epping_mode_supported();
|
return is_epping_mode_supported();
|
||||||
case QDF_GLOBAL_FTM_MODE:
|
case QDF_GLOBAL_FTM_MODE:
|
||||||
|
return is_ftm_mode_supported();
|
||||||
case QDF_GLOBAL_MISSION_MODE:
|
case QDF_GLOBAL_MISSION_MODE:
|
||||||
return true;
|
return true;
|
||||||
default:
|
default:
|
||||||
|
Reference in New Issue
Block a user