qcacld-3.0: Add DFS master feature flag

Add config flag to enable / disable DFS master feature

Change-Id: Ibb0bc715c70b471b5e73626cf75ce9785a8eb567
CRs-Fixed: 2222562
This commit is contained in:
Wen Gong 2018-04-11 18:34:55 +08:00 committed by nshrivas
parent 067b9e668c
commit 01a2c63468
4 changed files with 37 additions and 11 deletions

29
Kbuild
View File

@ -477,6 +477,9 @@ CONFIG_TRACE_RECORD_FEATURE := y
#Flag to enable p2p debug feature
CONFIG_WLAN_FEATURE_P2P_DEBUG := y
#Flag to enable DFS Master feature
CONFIG_WLAN_DFS_MASTER_ENABLE := y
#Flag to enable nud tracking feature
CONFIG_WLAN_NUD_TRACKING := y
@ -1350,8 +1353,7 @@ WMI_OBJS := $(WMI_OBJ_DIR)/wmi_unified.o \
$(WMI_OBJ_DIR)/wmi_unified_tlv.o \
$(WMI_OBJ_DIR)/wmi_unified_api.o \
$(WMI_OBJ_DIR)/wmi_unified_pmo_api.o \
$(WMI_OBJ_DIR)/wmi_unified_reg_api.o \
$(WMI_OBJ_DIR)/wmi_unified_dfs_api.o
$(WMI_OBJ_DIR)/wmi_unified_reg_api.o
ifeq ($(CONFIG_WLAN_FEATURE_DSRC), y)
ifeq ($(CONFIG_OCB_UT_FRAMEWORK), y)
@ -1359,6 +1361,10 @@ WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_ocb_ut.o
endif
endif
ifeq ($(CONFIG_WLAN_DFS_MASTER_ENABLE), y)
WMI_OBJS += $(WMI_OBJ_DIR)/wmi_unified_dfs_api.o
endif
########### FWLOG ###########
FWLOG_DIR := $(WLAN_COMMON_ROOT)/utils/fwlog
@ -1886,7 +1892,6 @@ OBJS := $(HDD_OBJS) \
$(SYS_OBJS) \
$(QDF_OBJS) \
$(CDS_OBJS) \
$(DFS_OBJS) \
$(FTM_OBJS)
OBJS += $(WMA_OBJS) \
@ -1896,8 +1901,7 @@ OBJS += $(WMA_OBJS) \
$(HTC_OBJS) \
$(INIT_DEINIT_OBJS) \
$(SCHEDULER_OBJS) \
$(REGULATORY_OBJS) \
$(DFS_OBJS)
$(REGULATORY_OBJS)
OBJS += $(HIF_OBJS) \
$(BMI_OBJS) \
@ -1915,6 +1919,9 @@ ifeq ($(CONFIG_FEATURE_EPPING), y)
OBJS += $(EPPING_OBJS)
endif
ifeq ($(CONFIG_WLAN_DFS_MASTER_ENABLE), y)
OBJS += $(DFS_OBJS)
endif
OBJS += $(UMAC_OBJMGR_OBJS)
OBJS += $(WIFI_POS_OBJS)
@ -2399,15 +2406,15 @@ cppflags-y += -DQCA_HOST2FW_RXBUF_RING
#endof dummy flags
# DFS component
cppflags-y += -DQCA_MCL_DFS_SUPPORT
cppflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DQCA_MCL_DFS_SUPPORT
ifeq ($(CONFIG_WLAN_FEATURE_DFS_OFFLOAD), y)
cppflags-y += -DWLAN_DFS_FULL_OFFLOAD
cppflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DWLAN_DFS_FULL_OFFLOAD
else
cppflags-y += -DWLAN_DFS_PARTIAL_OFFLOAD
cppflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DWLAN_DFS_PARTIAL_OFFLOAD
endif
cppflags-y += -DDFS_COMPONENT_ENABLE
cppflags-y += -DQCA_DFS_USE_POLICY_MANAGER
cppflags-y += -DQCA_DFS_NOL_PLATFORM_DRV_SUPPORT
cppflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DDFS_COMPONENT_ENABLE
cppflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DQCA_DFS_USE_POLICY_MANAGER
cppflags-$(CONFIG_WLAN_DFS_MASTER_ENABLE) += -DQCA_DFS_NOL_PLATFORM_DRV_SUPPORT
cppflags-$(CONFIG_WLAN_DEBUGFS) += -DWLAN_DEBUGFS

View File

@ -1323,8 +1323,16 @@ void wlansap_extend_to_acs_range(tHalHandle hal, uint8_t *startChannelNum,
*
* Return: QDF_STATUS
*/
#ifdef DFS_COMPONENT_ENABLE
QDF_STATUS wlansap_set_dfs_nol(struct sap_context *sap_ctx,
eSapDfsNolType conf);
#else
static inline QDF_STATUS wlansap_set_dfs_nol(struct sap_context *sap_ctx,
eSapDfsNolType conf)
{
return QDF_STATUS_SUCCESS;
}
#endif
/**
* wlan_sap_set_vendor_acs() - Set vendor specific acs in sap context

View File

@ -213,6 +213,7 @@ static inline void sap_event_init(ptWLAN_SAPEvent sapEvent)
sapEvent->u2 = 0;
}
#ifdef DFS_COMPONENT_ENABLE
/**
* sap_random_channel_sel() - This function randomly pick up an available
* channel
@ -288,6 +289,12 @@ static uint8_t sap_random_channel_sel(struct sap_context *sap_ctx)
sap_ctx->ch_params.center_freq_seg1 = ch_params->center_freq_seg1;
return ch;
}
#else
static uint8_t sap_random_channel_sel(struct sap_context *sap_ctx)
{
return 0;
}
#endif
/**
* sap_is_channel_bonding_etsi_weather_channel() - check weather chan bonding.
@ -3410,6 +3417,7 @@ static QDF_STATUS sap_get_channel_list(struct sap_context *sap_ctx,
}
#endif
#ifdef DFS_COMPONENT_ENABLE
uint8_t sap_indicate_radar(struct sap_context *sap_ctx)
{
uint8_t target_channel = 0;
@ -3467,6 +3475,7 @@ uint8_t sap_indicate_radar(struct sap_context *sap_ctx)
return target_channel;
}
#endif
/*
* CAC timer callback function.

View File

@ -2352,6 +2352,7 @@ QDF_STATUS wlan_sap_set_vendor_acs(struct sap_context *sap_context,
return QDF_STATUS_SUCCESS;
}
#ifdef DFS_COMPONENT_ENABLE
QDF_STATUS wlansap_set_dfs_nol(struct sap_context *sap_ctx,
eSapDfsNolType conf)
{
@ -2397,6 +2398,7 @@ QDF_STATUS wlansap_set_dfs_nol(struct sap_context *sap_ctx,
return QDF_STATUS_SUCCESS;
}
#endif
/**
* wlansap_populate_del_sta_params() - populate delete station parameter