aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/if_vlan.h
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2008-02-05 19:20:22 -0500
committerDavid S. Miller <davem@davemloft.net>2008-02-05 19:20:22 -0500
commit181499356e5a9f0bcbd69adc3c6df450f6e2586d (patch)
tree6df194a9c4049877f906e93cf3b7c70533732eee /include/linux/if_vlan.h
parent4f25049106e0507ff21a9e1fc0645d849e19faf0 (diff)
[VLAN]: Constify skb argument to vlan_get_tag()
Required by next patch to use it from the flow classifier. Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/if_vlan.h')
-rw-r--r--include/linux/if_vlan.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/linux/if_vlan.h b/include/linux/if_vlan.h
index 34f40efc7607..79504b22a932 100644
--- a/include/linux/if_vlan.h
+++ b/include/linux/if_vlan.h
@@ -327,7 +327,7 @@ static inline struct sk_buff *vlan_put_tag(struct sk_buff *skb, unsigned short t
327 * 327 *
328 * Returns error if the skb is not of VLAN type 328 * Returns error if the skb is not of VLAN type
329 */ 329 */
330static inline int __vlan_get_tag(struct sk_buff *skb, unsigned short *tag) 330static inline int __vlan_get_tag(const struct sk_buff *skb, unsigned short *tag)
331{ 331{
332 struct vlan_ethhdr *veth = (struct vlan_ethhdr *)skb->data; 332 struct vlan_ethhdr *veth = (struct vlan_ethhdr *)skb->data;
333 333
@@ -347,7 +347,8 @@ static inline int __vlan_get_tag(struct sk_buff *skb, unsigned short *tag)
347 * 347 *
348 * Returns error if @skb->cb[] is not set correctly 348 * Returns error if @skb->cb[] is not set correctly
349 */ 349 */
350static inline int __vlan_hwaccel_get_tag(struct sk_buff *skb, unsigned short *tag) 350static inline int __vlan_hwaccel_get_tag(const struct sk_buff *skb,
351 unsigned short *tag)
351{ 352{
352 struct vlan_skb_tx_cookie *cookie; 353 struct vlan_skb_tx_cookie *cookie;
353 354
@@ -370,7 +371,7 @@ static inline int __vlan_hwaccel_get_tag(struct sk_buff *skb, unsigned short *ta
370 * 371 *
371 * Returns error if the skb is not VLAN tagged 372 * Returns error if the skb is not VLAN tagged
372 */ 373 */
373static inline int vlan_get_tag(struct sk_buff *skb, unsigned short *tag) 374static inline int vlan_get_tag(const struct sk_buff *skb, unsigned short *tag)
374{ 375{
375 if (skb->dev->features & NETIF_F_HW_VLAN_TX) { 376 if (skb->dev->features & NETIF_F_HW_VLAN_TX) {
376 return __vlan_hwaccel_get_tag(skb, tag); 377 return __vlan_hwaccel_get_tag(skb, tag);