wlan: During ARP debug set FW in datapath for ARP

For ARP packet debug keep FW in datapath and set tx BD complete
Tx interrupt field with dialogue token. Also Make use of reserved
TX BD field to indicate packet as ARP to FW.

Change-Id: I8477388ecc83bf6e9dfa75d85d5c8dcbb9f774d7
CRs-Fixed: 1115218
diff --git a/CORE/HDD/inc/wlan_hdd_main.h b/CORE/HDD/inc/wlan_hdd_main.h
index ad84c95..8495e49 100644
--- a/CORE/HDD/inc/wlan_hdd_main.h
+++ b/CORE/HDD/inc/wlan_hdd_main.h
@@ -1795,6 +1795,8 @@
     scan_reject_states last_scan_reject_reason;
     v_TIME_t last_scan_reject_timestamp;
     bool is_ap_mode_wow_supported;
+
+    uint32_t track_arp_ip;
 };
 
 typedef enum  {
diff --git a/CORE/HDD/src/wlan_hdd_cfg80211.c b/CORE/HDD/src/wlan_hdd_cfg80211.c
index fa56021..7bc99e3 100644
--- a/CORE/HDD/src/wlan_hdd_cfg80211.c
+++ b/CORE/HDD/src/wlan_hdd_cfg80211.c
@@ -7586,6 +7586,7 @@
     struct net_device   *dev = wdev->netdev;
     hdd_adapter_t       *adapter = WLAN_HDD_GET_PRIV_PTR(dev);
     hdd_context_t *hdd_ctx = wiphy_priv(wiphy);
+    v_CONTEXT_t pVosContext = (WLAN_HDD_GET_CTX(adapter))->pvosContext;
     setArpStatsParams arp_stats_params;
     int err = 0;
 
@@ -7630,6 +7631,19 @@
 
     arp_stats_params.pkt_type = 1; // ARP packet type
 
+    if (arp_stats_params.flag) {
+       hdd_ctx->track_arp_ip = arp_stats_params.ip_addr;
+       WLANTL_SetARPFWDatapath(pVosContext, true);
+       VOS_TRACE(VOS_MODULE_ID_HDD, VOS_TRACE_LEVEL_INFO,
+                 "%s Set FW in data path for ARP with tgt IP :%d",
+                 __func__,  hdd_ctx->track_arp_ip);
+    }
+    else {
+       WLANTL_SetARPFWDatapath(pVosContext, false);
+       VOS_TRACE(VOS_MODULE_ID_HDD, VOS_TRACE_LEVEL_INFO,
+                 "%s Remove FW from data path", __func__);
+    }
+
     arp_stats_params.rsp_cb_fn = hdd_set_nud_stats_cb;
     arp_stats_params.data_ctx = adapter;