prima: Support for NAT keep alive packets

qcacld-2.0 to pronto propagation

This is the host driver implementation to support sending
fixed NAT keep alive packets to WiFi Network.
1. WifiHal issues start send packet with ip_packet, ip_packet_len,
destination mac address and period. Host driver populates the data
and sends WMI message to firmware to configure the tx pattern.
2. WifiHal upon sending stop packet, host driver sends delete
tx pattern to the firmware.

Additional changes are done to pass the pattern bitmap to WDA.

Change-Id: I58309d1c58ff0ba9bcf86c31ac2a7eccfa3a7f8f
CRs-Fixed: 915690
diff --git a/CORE/HDD/inc/wlan_hdd_main.h b/CORE/HDD/inc/wlan_hdd_main.h
index ebb2a9c..424c852 100644
--- a/CORE/HDD/inc/wlan_hdd_main.h
+++ b/CORE/HDD/inc/wlan_hdd_main.h
@@ -1263,6 +1263,31 @@
 };
 #endif /* End of WLAN_FEATURE_EXTSCAN */
 
+#ifdef WLAN_FEATURE_OFFLOAD_PACKETS
+/**
+ * struct hdd_offloaded_packets - request id to pattern id mapping
+ * @request_id: request id
+ * @pattern_id: pattern id
+ *
+ */
+struct hdd_offloaded_packets
+{
+    uint32_t request_id;
+    uint8_t  pattern_id;
+};
+
+/**
+ * struct hdd_offloaded_packets_ctx - offloaded packets context
+ * @op_table: request id to pattern id table
+ * @op_lock: mutex lock
+ */
+struct hdd_offloaded_packets_ctx
+{
+    struct hdd_offloaded_packets op_table[MAXNUM_PERIODIC_TX_PTRNS];
+    struct mutex op_lock;
+};
+#endif
+
 /** Adapter stucture definition */
 
 struct hdd_context_s
@@ -1498,6 +1523,9 @@
     unsigned long  last_suspend_success;
     v_U32_t  continuous_suspend_fail_cnt;
 
+#ifdef WLAN_FEATURE_OFFLOAD_PACKETS
+    struct hdd_offloaded_packets_ctx op_ctx;
+#endif
 };