mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-12 07:37:31 -04:00
net: usb: ax88179: Change to check if the packets are coming from gsb
Packets from gsb are cloned packets, which has been done to optimize the dl data path. The check for cloned skb calls pskb_expand_head which gives penalty in the throughput. GSB driver data path does not consume the skb so, reallocation of skb is not necessary here. For that reason the check for all packets from gsb is introduced here. This check improves the throughput to about 150 Mbps. Change-Id: Ic1d7cc9c94605f1902ba212aac52d535d0ff84a7 Acked-by: Rishav LNU <rna@qti.qualcomm.com> Signed-off-by: Mohammed Javid <mjavid@codeaurora.org>
This commit is contained in:
parent
0149a80bda
commit
74ab1d4b33
1 changed files with 9 additions and 1 deletions
|
|
@ -1431,12 +1431,20 @@ ax88179_tx_fixup(struct usbnet *dev, struct sk_buff *skb, gfp_t flags)
|
|||
|
||||
headroom = skb_headroom(skb) - 8;
|
||||
|
||||
#ifdef CONFIG_ENABLE_SFE
|
||||
if (((!(skb->fast_forwarded) && skb_header_cloned(skb)) ||
|
||||
headroom < 0) &&
|
||||
pskb_expand_head(skb, headroom < 0 ? 8 : 0, 0, GFP_ATOMIC)) {
|
||||
dev_kfree_skb_any(skb);
|
||||
return NULL;
|
||||
}
|
||||
#else
|
||||
if ((skb_header_cloned(skb) || headroom < 0) &&
|
||||
pskb_expand_head(skb, headroom < 0 ? 8 : 0, 0, GFP_ATOMIC)) {
|
||||
dev_kfree_skb_any(skb);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
#endif
|
||||
ptr = skb_push(skb, 8);
|
||||
put_unaligned_le32(tx_hdr1, ptr);
|
||||
put_unaligned_le32(tx_hdr2, ptr + 4);
|
||||
|
|
|
|||
Loading…
Reference in a new issue