From: Patrick McHardy <kaber@trash.net>
To: davem@davemloft.net
Cc: netdev@vger.kernel.org, Patrick McHardy <kaber@trash.net>
Subject: [VLAN 03/04]: Constify skb argument to vlan_get_tag()
Date: Tue, 5 Feb 2008 15:29:43 +0100 (MET) [thread overview]
Message-ID: <20080205142906.13543.98167.sendpatchset@localhost.localdomain> (raw)
In-Reply-To: <20080205142902.13543.88604.sendpatchset@localhost.localdomain>
[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>
---
commit 03faf81b8195be455c3c7592d76d712ea9d80b13
tree 9da377d2bd44421494a4c4d7cf6c705d199c26ce
parent 2e5915ef51e55135522e59e041bb176432857d82
author Patrick McHardy <kaber@trash.net> Tue, 05 Feb 2008 15:22:23 +0100
committer Patrick McHardy <kaber@trash.net> Tue, 05 Feb 2008 15:22:23 +0100
include/linux/if_vlan.h | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/include/linux/if_vlan.h b/include/linux/if_vlan.h
index 34f40ef..79504b2 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
*
* Returns error if the skb is not of VLAN type
*/
-static inline int __vlan_get_tag(struct sk_buff *skb, unsigned short *tag)
+static inline int __vlan_get_tag(const struct sk_buff *skb, unsigned short *tag)
{
struct vlan_ethhdr *veth = (struct vlan_ethhdr *)skb->data;
@@ -347,7 +347,8 @@ static inline int __vlan_get_tag(struct sk_buff *skb, unsigned short *tag)
*
* Returns error if @skb->cb[] is not set correctly
*/
-static inline int __vlan_hwaccel_get_tag(struct sk_buff *skb, unsigned short *tag)
+static inline int __vlan_hwaccel_get_tag(const struct sk_buff *skb,
+ unsigned short *tag)
{
struct vlan_skb_tx_cookie *cookie;
@@ -370,7 +371,7 @@ static inline int __vlan_hwaccel_get_tag(struct sk_buff *skb, unsigned short *ta
*
* Returns error if the skb is not VLAN tagged
*/
-static inline int vlan_get_tag(struct sk_buff *skb, unsigned short *tag)
+static inline int vlan_get_tag(const struct sk_buff *skb, unsigned short *tag)
{
if (skb->dev->features & NETIF_F_HW_VLAN_TX) {
return __vlan_hwaccel_get_tag(skb, tag);
next prev parent reply other threads:[~2008-02-05 14:29 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-05 14:29 [NET_SCHED 00/04]: Two fixes + cls_flow VLAN tag based classification Patrick McHardy
2008-02-05 14:29 ` [NET_SCHED 01/04]: em_meta: fix compile warning Patrick McHardy
2008-02-06 0:19 ` David Miller
2008-02-05 14:29 ` [NET_SCHED 02/04]: cls_flow: fix key mask validity check Patrick McHardy
2008-02-06 0:20 ` David Miller
2008-02-05 14:29 ` Patrick McHardy [this message]
2008-02-06 0:20 ` [VLAN 03/04]: Constify skb argument to vlan_get_tag() David Miller
2008-02-05 14:29 ` [NET_SCHED 04/04]: cls_flow: support classification based on VLAN tag Patrick McHardy
2008-02-06 0:21 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080205142906.13543.98167.sendpatchset@localhost.localdomain \
--to=kaber@trash.net \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).