aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/core/dev.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/net/core/dev.c b/net/core/dev.c
index a51dfd7b56fb..1444ed3861a0 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -2086,6 +2086,8 @@ int dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev,
2086 int rc = NETDEV_TX_OK; 2086 int rc = NETDEV_TX_OK;
2087 2087
2088 if (likely(!skb->next)) { 2088 if (likely(!skb->next)) {
2089 int features;
2090
2089 /* 2091 /*
2090 * If device doesnt need skb->dst, release it right now while 2092 * If device doesnt need skb->dst, release it right now while
2091 * its hot in this cpu cache 2093 * its hot in this cpu cache
@@ -2098,8 +2100,10 @@ int dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev,
2098 2100
2099 skb_orphan_try(skb); 2101 skb_orphan_try(skb);
2100 2102
2103 features = netif_skb_features(skb);
2104
2101 if (vlan_tx_tag_present(skb) && 2105 if (vlan_tx_tag_present(skb) &&
2102 !(dev->features & NETIF_F_HW_VLAN_TX)) { 2106 !(features & NETIF_F_HW_VLAN_TX)) {
2103 skb = __vlan_put_tag(skb, vlan_tx_tag_get(skb)); 2107 skb = __vlan_put_tag(skb, vlan_tx_tag_get(skb));
2104 if (unlikely(!skb)) 2108 if (unlikely(!skb))
2105 goto out; 2109 goto out;
@@ -2107,7 +2111,7 @@ int dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev,
2107 skb->vlan_tci = 0; 2111 skb->vlan_tci = 0;
2108 } 2112 }
2109 2113
2110 if (netif_needs_gso(dev, skb)) { 2114 if (netif_needs_gso(skb, features)) {
2111 if (unlikely(dev_gso_segment(skb))) 2115 if (unlikely(dev_gso_segment(skb)))
2112 goto out_kfree_skb; 2116 goto out_kfree_skb;
2113 if (skb->next) 2117 if (skb->next)