Browse Source

qcacld-3.0: Featurize DHCP indication for SAP

Featurize DHCP indication for SAP and disable it
for QCN7605 as this feature is broken for HL
Data Path.

Change-Id: If1db649131d887a2aab18461187403b4b9a2c5b4
CRs-Fixed: 2496032
Nirav Shah 5 years ago
parent
commit
a43f6dc3cf

+ 1 - 0
Kbuild

@@ -2668,6 +2668,7 @@ cppflags-$(CONFIG_QCACLD_RX_DESC_MULTI_PAGE_ALLOC) += -DRX_DESC_MULTI_PAGE_ALLOC
 
 cppflags-$(CONFIG_WLAN_FEATURE_DP_EVENT_HISTORY) += -DWLAN_FEATURE_DP_EVENT_HISTORY
 cppflags-$(CONFIG_WLAN_DP_PER_RING_TYPE_CONFIG) += -DWLAN_DP_PER_RING_TYPE_CONFIG
+cppflags-$(CONFIG_SAP_DHCP_FW_IND) += -DSAP_DHCP_FW_IND
 
 ifdef CONFIG_MAX_LOGS_PER_SEC
 ccflags-y += -DWLAN_MAX_LOGS_PER_SEC=$(CONFIG_MAX_LOGS_PER_SEC)

+ 2 - 0
configs/default_defconfig

@@ -858,3 +858,5 @@ CONFIG_FEATURE_OEM_DATA := y
 ifeq (y,$(findstring y,$(CONFIG_ARCH_MSM) $(CONFIG_ARCH_QCOM)))
 CONFIG_WLAN_FEATURE_DP_BUS_BANDWIDTH := y
 endif
+
+CONFIG_SAP_DHCP_FW_IND := y

+ 1 - 0
configs/genoa.common

@@ -216,4 +216,5 @@ ifeq (y,$(findstring y,$(CONFIG_ARCH_MSM) $(CONFIG_ARCH_QCOM) $(CONFIG_QCA_SUPPO
 CONFIG_WLAN_FEATURE_DP_BUS_BANDWIDTH := y
 endif
 
+CONFIG_SAP_DHCP_FW_IND := n
 ###################################

+ 2 - 0
configs/qca6174_defconfig

@@ -707,3 +707,5 @@ CONFIG_FEATURE_BECN_STATS := y
 ifeq (y,$(findstring y,$(CONFIG_ARCH_MSM) $(CONFIG_ARCH_QCOM)))
 CONFIG_WLAN_FEATURE_DP_BUS_BANDWIDTH := y
 endif
+
+CONFIG_SAP_DHCP_FW_IND := y

+ 1 - 0
configs/qca6390_defconfig

@@ -725,3 +725,4 @@ CONFIG_WLAN_FEATURE_DP_BUS_BANDWIDTH := y
 endif
 
 CONFIG_FOURTH_CONNECTION := y
+CONFIG_SAP_DHCP_FW_IND := y

+ 1 - 1
configs/qcs40x.snoc.perf_defconfig

@@ -180,5 +180,5 @@ CONFIG_CFG_NUM_WMI_MGMT_EVENT_HISTORY := 16
 CONFIG_CFG_NUM_TX_RX_HISTOGRAM := 16
 # CONFIG_CFG_NUM_RX_IND_RECORD := 1024
 
-
+CONFIG_SAP_DHCP_FW_IND := y
 ###################################

+ 19 - 0
core/hdd/inc/wlan_hdd_softap_tx_rx.h

@@ -229,6 +229,7 @@ void hdd_softap_tx_resume_cb(void *adapter_context, bool tx_resume)
 }
 #endif /* QCA_LL_LEGACY_TX_FLOW_CONTROL */
 
+#ifdef SAP_DHCP_FW_IND
 /**
  * hdd_post_dhcp_ind() - Send DHCP START/STOP indication to FW
  * @adapter: pointer to hdd adapter
@@ -253,5 +254,23 @@ int hdd_inspect_dhcp_packet(struct hdd_adapter *adapter,
 			    uint8_t sta_id,
 			    struct sk_buff *skb,
 			    enum qdf_proto_dir dir);
+#else
+static inline
+int hdd_post_dhcp_ind(struct hdd_adapter *adapter,
+		      uint8_t sta_id, uint16_t type)
+{
+	return 0;
+}
+
+static inline
+int hdd_inspect_dhcp_packet(struct hdd_adapter *adapter,
+			    uint8_t sta_id,
+			    struct sk_buff *skb,
+			    enum qdf_proto_dir dir)
+{
+	return 0;
+}
+
+#endif
 
 #endif /* end #if !defined(WLAN_HDD_SOFTAP_TX_RX_H) */

+ 6 - 0
core/hdd/src/wlan_hdd_softap_tx_rx.c

@@ -236,6 +236,7 @@ static inline struct sk_buff *hdd_skb_orphan(struct hdd_adapter *adapter,
 }
 #endif /* QCA_LL_LEGACY_TX_FLOW_CONTROL */
 
+#ifdef SAP_DHCP_FW_IND
 /**
  * hdd_post_dhcp_ind() - Send DHCP START/STOP indication to FW
  * @adapter: pointer to hdd adapter
@@ -425,6 +426,11 @@ int hdd_inspect_dhcp_packet(struct hdd_adapter *adapter,
 
 	return errno;
 }
+#else
+static void hdd_softap_notify_dhcp_ind(void *context, struct sk_buff *netbuf)
+{
+}
+#endif
 
 /**
  * __hdd_softap_hard_start_xmit() - Transmit a frame