aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorJiri Pirko <jiri@resnulli.us>2014-11-19 08:04:58 -0500
committerDavid S. Miller <davem@davemloft.net>2014-11-21 14:20:17 -0500
commit62749e2cb3c4a7da3eaa5c01a7e787aebeff8536 (patch)
treea464a51f430889a16db620946abf9d20874b3406 /net
parentb4bef1b57544b18899eb15569e3bafd8d2eeeff6 (diff)
vlan: rename __vlan_put_tag to vlan_insert_tag_set_proto
Name fits better. Plus there's going to be introduced __vlan_insert_tag later on. Signed-off-by: Jiri Pirko <jiri@resnulli.us> Acked-by: Pravin B Shelar <pshelar@nicira.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r--net/bridge/br_vlan.c4
-rw-r--r--net/core/dev.c4
-rw-r--r--net/core/netpoll.c4
-rw-r--r--net/ipv4/geneve.c11
-rw-r--r--net/openvswitch/actions.c4
-rw-r--r--net/openvswitch/datapath.c3
-rw-r--r--net/openvswitch/vport-gre.c6
7 files changed, 19 insertions, 17 deletions
diff --git a/net/bridge/br_vlan.c b/net/bridge/br_vlan.c
index 150048fb99b0..97b8ddf57363 100644
--- a/net/bridge/br_vlan.c
+++ b/net/bridge/br_vlan.c
@@ -199,8 +199,8 @@ bool br_allowed_ingress(struct net_bridge *br, struct net_port_vlans *v,
199 if (skb->vlan_proto != proto) { 199 if (skb->vlan_proto != proto) {
200 /* Protocol-mismatch, empty out vlan_tci for new tag */ 200 /* Protocol-mismatch, empty out vlan_tci for new tag */
201 skb_push(skb, ETH_HLEN); 201 skb_push(skb, ETH_HLEN);
202 skb = __vlan_put_tag(skb, skb->vlan_proto, 202 skb = vlan_insert_tag_set_proto(skb, skb->vlan_proto,
203 vlan_tx_tag_get(skb)); 203 vlan_tx_tag_get(skb));
204 if (unlikely(!skb)) 204 if (unlikely(!skb))
205 return false; 205 return false;
206 206
diff --git a/net/core/dev.c b/net/core/dev.c
index 1ab168e0fdf7..3611e60df407 100644
--- a/net/core/dev.c
+++ b/net/core/dev.c
@@ -2645,8 +2645,8 @@ static struct sk_buff *validate_xmit_vlan(struct sk_buff *skb,
2645{ 2645{
2646 if (vlan_tx_tag_present(skb) && 2646 if (vlan_tx_tag_present(skb) &&
2647 !vlan_hw_offload_capable(features, skb->vlan_proto)) { 2647 !vlan_hw_offload_capable(features, skb->vlan_proto)) {
2648 skb = __vlan_put_tag(skb, skb->vlan_proto, 2648 skb = vlan_insert_tag_set_proto(skb, skb->vlan_proto,
2649 vlan_tx_tag_get(skb)); 2649 vlan_tx_tag_get(skb));
2650 if (skb) 2650 if (skb)
2651 skb->vlan_tci = 0; 2651 skb->vlan_tci = 0;
2652 } 2652 }
diff --git a/net/core/netpoll.c b/net/core/netpoll.c
index e6645b4f330a..65d372384a3f 100644
--- a/net/core/netpoll.c
+++ b/net/core/netpoll.c
@@ -79,8 +79,8 @@ static int netpoll_start_xmit(struct sk_buff *skb, struct net_device *dev,
79 79
80 if (vlan_tx_tag_present(skb) && 80 if (vlan_tx_tag_present(skb) &&
81 !vlan_hw_offload_capable(features, skb->vlan_proto)) { 81 !vlan_hw_offload_capable(features, skb->vlan_proto)) {
82 skb = __vlan_put_tag(skb, skb->vlan_proto, 82 skb = vlan_insert_tag_set_proto(skb, skb->vlan_proto,
83 vlan_tx_tag_get(skb)); 83 vlan_tx_tag_get(skb));
84 if (unlikely(!skb)) { 84 if (unlikely(!skb)) {
85 /* This is actually a packet drop, but we 85 /* This is actually a packet drop, but we
86 * don't want the code that calls this 86 * don't want the code that calls this
diff --git a/net/ipv4/geneve.c b/net/ipv4/geneve.c
index 31802afce34f..fd430a6a1c37 100644
--- a/net/ipv4/geneve.c
+++ b/net/ipv4/geneve.c
@@ -132,12 +132,11 @@ int geneve_xmit_skb(struct geneve_sock *gs, struct rtable *rt,
132 return err; 132 return err;
133 133
134 if (vlan_tx_tag_present(skb)) { 134 if (vlan_tx_tag_present(skb)) {
135 if (unlikely(!__vlan_put_tag(skb, 135 skb = vlan_insert_tag_set_proto(skb, skb->vlan_proto,
136 skb->vlan_proto, 136 vlan_tx_tag_get(skb));
137 vlan_tx_tag_get(skb)))) { 137 if (unlikely(!skb)
138 err = -ENOMEM; 138 return -ENOMEM;
139 return err; 139
140 }
141 skb->vlan_tci = 0; 140 skb->vlan_tci = 0;
142 } 141 }
143 142
diff --git a/net/openvswitch/actions.c b/net/openvswitch/actions.c
index 749a30163071..426b9131ede0 100644
--- a/net/openvswitch/actions.c
+++ b/net/openvswitch/actions.c
@@ -287,7 +287,9 @@ static int push_vlan(struct sk_buff *skb, struct sw_flow_key *key,
287 /* push down current VLAN tag */ 287 /* push down current VLAN tag */
288 current_tag = vlan_tx_tag_get(skb); 288 current_tag = vlan_tx_tag_get(skb);
289 289
290 if (!__vlan_put_tag(skb, skb->vlan_proto, current_tag)) 290 skb = vlan_insert_tag_set_proto(skb, skb->vlan_proto,
291 current_tag);
292 if (!skb)
291 return -ENOMEM; 293 return -ENOMEM;
292 /* Update mac_len for subsequent MPLS actions */ 294 /* Update mac_len for subsequent MPLS actions */
293 skb->mac_len += VLAN_HLEN; 295 skb->mac_len += VLAN_HLEN;
diff --git a/net/openvswitch/datapath.c b/net/openvswitch/datapath.c
index ab141d49bb9d..c63e60e4d947 100644
--- a/net/openvswitch/datapath.c
+++ b/net/openvswitch/datapath.c
@@ -425,7 +425,8 @@ static int queue_userspace_packet(struct datapath *dp, struct sk_buff *skb,
425 if (!nskb) 425 if (!nskb)
426 return -ENOMEM; 426 return -ENOMEM;
427 427
428 nskb = __vlan_put_tag(nskb, nskb->vlan_proto, vlan_tx_tag_get(nskb)); 428 nskb = vlan_insert_tag_set_proto(nskb, nskb->vlan_proto,
429 vlan_tx_tag_get(nskb));
429 if (!nskb) 430 if (!nskb)
430 return -ENOMEM; 431 return -ENOMEM;
431 432
diff --git a/net/openvswitch/vport-gre.c b/net/openvswitch/vport-gre.c
index 8e61a5c6ae7c..777cd8c71d53 100644
--- a/net/openvswitch/vport-gre.c
+++ b/net/openvswitch/vport-gre.c
@@ -176,9 +176,9 @@ static int gre_tnl_send(struct vport *vport, struct sk_buff *skb)
176 } 176 }
177 177
178 if (vlan_tx_tag_present(skb)) { 178 if (vlan_tx_tag_present(skb)) {
179 if (unlikely(!__vlan_put_tag(skb, 179 skb = vlan_insert_tag_set_proto(skb, skb->vlan_proto,
180 skb->vlan_proto, 180 vlan_tx_tag_get(skb));
181 vlan_tx_tag_get(skb)))) { 181 if (unlikely(!skb) {
182 err = -ENOMEM; 182 err = -ENOMEM;
183 goto err_free_rt; 183 goto err_free_rt;
184 } 184 }