qcacld-3.0: Print APF work memory as it is read or written

Just like the legacy APF commands, dump the contents of the
APF instructions/data as it is read or written by upper
layer using the new APFv3 vendor commands. This is helpful
for debugging purposes.

Change-Id: I24725b5b8431fcaa573953187f8412e4f4d0b510
CRs-Fixed: 2375362
diff --git a/core/hdd/src/wlan_hdd_apf.c b/core/hdd/src/wlan_hdd_apf.c
index 639495e..faffbb1 100644
--- a/core/hdd/src/wlan_hdd_apf.c
+++ b/core/hdd/src/wlan_hdd_apf.c
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012-2018 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved.
  *
  * Permission to use, copy, modify, and/or distribute this software for
  * any purpose with or without fee is hereby granted, provided that the
@@ -409,6 +409,11 @@
 		ret = -EINVAL;
 	}
 
+	hdd_debug("Writing successful into APF work memory from offset 0x%X:",
+		  write_mem_params.addr_offset);
+	QDF_TRACE_HEX_DUMP(QDF_MODULE_ID_HDD, QDF_TRACE_LEVEL_DEBUG,
+			   write_mem_params.buf, write_mem_params.length);
+
 	if (write_mem_params.buf)
 		qdf_mem_free(write_mem_params.buf);
 
@@ -577,6 +582,11 @@
 	}
 
 	cfg80211_vendor_cmd_reply(skb);
+
+	hdd_debug("Reading APF work memory from offset 0x%X:",
+		  read_mem_params.addr_offset);
+	QDF_TRACE_HEX_DUMP(QDF_MODULE_ID_HDD, QDF_TRACE_LEVEL_DEBUG,
+			   context->buf, read_mem_params.length);
 fail:
 	if (context->buf) {
 		qdf_mem_free(context->buf);