From a46056182a7c3a235f362eb5d42376eb6b17e164 Mon Sep 17 00:00:00 2001 From: Sravan Kumar Kairam Date: Fri, 17 Feb 2017 16:31:09 +0530 Subject: [PATCH] qcacmn: Add support to log IP addr of the wow wakeup packet Add support to log the IP header source and destination address for the first Rx packet received after host wakeup. Change-Id: Ie8cf71c8ce913378687ad2c79ab9d5f46c0c2419 CRs-Fixed: 1106593 --- qdf/inc/qdf_nbuf.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/qdf/inc/qdf_nbuf.h b/qdf/inc/qdf_nbuf.h index cef0e0f14b8b..37aa4e3faac6 100644 --- a/qdf/inc/qdf_nbuf.h +++ b/qdf/inc/qdf_nbuf.h @@ -212,9 +212,11 @@ struct mon_rx_status { #define ARP_REQUEST (1) #define ARP_RESPONSE (2) -/* IPV4 Related Mask */ +/* IPV4 header fields offset values */ #define IPV4_PKT_LEN_OFFSET 16 #define IPV4_TCP_SEQ_NUM_OFFSET 38 +#define IPV4_SRC_ADDR_OFFSET 26 +#define IPV4_DST_ADDR_OFFSET 30 #define IPV4_SRC_PORT_OFFSET 34 #define IPV4_DST_PORT_OFFSET 36 @@ -224,9 +226,14 @@ struct mon_rx_status { #define ICMP_REQUEST 0x08 #define ICMP_RESPONSE 0x00 -/* IPV6 Related Mask */ +#define IPV6_ADDR_STR "%02x%02x:%02x%02x:%02x%02x:%02x%02x:%02x%02x:%02x%02x:"\ + "%02x%02x:%02x%02x" + +/* IPV6 header fields offset values */ #define IPV6_PKT_LEN_OFFSET 18 #define IPV6_TCP_SEQ_NUM_OFFSET 58 +#define IPV6_SRC_ADDR_OFFSET 22 +#define IPV6_DST_ADDR_OFFSET 38 #define IPV6_SRC_PORT_OFFSET 54 #define IPV6_DST_PORT_OFFSET 56