From 77c81e226a251db54eed3fda988baf34bafcb021 Mon Sep 17 00:00:00 2001 From: Debabrata Purohit Date: Fri, 25 May 2018 15:51:49 +0100 Subject: [PATCH] [9610] wlbt: fix SKB MAC header offset If A-MSDU is enabled in transmit, the frame is translated to MSDU sub frame format from Ethernet format. But the MAC header in SKB is not updated and it causes access to wrong offset for destination address. The MAC header offset is corrected in such translation. Change-Id: I509dd5754ccd1d179ca63b9e232264a0fdd76b0e SCSC-Bug-Id: SQA-3156 Signed-off-by: Debabrata Purohit --- drivers/net/wireless/scsc/dev.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/wireless/scsc/dev.h b/drivers/net/wireless/scsc/dev.h index a144087ec545..a29a86edf7eb 100755 --- a/drivers/net/wireless/scsc/dev.h +++ b/drivers/net/wireless/scsc/dev.h @@ -90,6 +90,8 @@ static inline void ethr_ii_to_subframe_msdu(struct sk_buff *skb) memset(msduh.oui, 0x0, 3); msduh.type = ehdr->h_proto; (void)skb_push(skb, sizeof(struct msduhdr) - sizeof(struct ethhdr)); + /* update SKB mac_header to point to start of MSDU header */ + skb->mac_header -= (sizeof(struct msduhdr) - sizeof(struct ethhdr)); memcpy(skb->data, &msduh, sizeof(struct msduhdr)); } -- 2.20.1