Skip to content

Commit

Permalink
net: remove redundant code in dev_hard_start_xmit()
Browse files Browse the repository at this point in the history
This reverts commit 068a2de (net: release dst entry while
cache-hot for GSO case too)

Before GSO packet segmentation, we already take care of skb->dst if it
can be released.

There is no point adding extra test for every segment in the gso loop.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Krishna Kumar <krkumar2@in.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Eric Dumazet authored and David S. Miller committed Apr 25, 2013
1 parent ee80fbf commit e12472d
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions net/core/dev.c
Original file line number Diff line number Diff line change
Expand Up @@ -2546,13 +2546,6 @@ int dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev,
skb->next = nskb->next;
nskb->next = NULL;

/*
* If device doesn't need nskb->dst, release it right now while
* its hot in this cpu cache
*/
if (dev->priv_flags & IFF_XMIT_DST_RELEASE)
skb_dst_drop(nskb);

if (!list_empty(&ptype_all))
dev_queue_xmit_nit(nskb, dev);

Expand Down

0 comments on commit e12472d

Please sign in to comment.