diff options
author | Patrick McHardy <kaber@trash.net> | 2008-07-08 06:24:44 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-07-08 06:24:44 -0400 |
commit | 9bb8582efb555521c7eec595ebd34e835ddc34b8 (patch) | |
tree | 8eb6aae062bbd359e820a35d51fb16a32e7b828f /net/8021q/vlan_core.c | |
parent | df6b6a0cf62afeacdeb4c1a35b8fba21fda54399 (diff) |
vlan: TCI related type and naming cleanups
The VLAN code contains multiple spots that use tag, id and tci as
identifiers for arguments and variables incorrectly and they actually
contain or are expected to contain something different. Additionally
types are used inconsistently (unsigned short vs u16) and identifiers
are sometimes capitalized.
- consistently use u16 for storing TCI, ID or QoS values
- consistently use vlan_id and vlan_tci for storing the respective values
- remove capitalization
- add kdoc comment to netif_hwaccel_{rx,receive_skb}
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/8021q/vlan_core.c')
-rw-r--r-- | net/8021q/vlan_core.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/net/8021q/vlan_core.c b/net/8021q/vlan_core.c index f980b9154cc..68df12d3664 100644 --- a/net/8021q/vlan_core.c +++ b/net/8021q/vlan_core.c | |||
@@ -5,7 +5,7 @@ | |||
5 | 5 | ||
6 | /* VLAN rx hw acceleration helper. This acts like netif_{rx,receive_skb}(). */ | 6 | /* VLAN rx hw acceleration helper. This acts like netif_{rx,receive_skb}(). */ |
7 | int __vlan_hwaccel_rx(struct sk_buff *skb, struct vlan_group *grp, | 7 | int __vlan_hwaccel_rx(struct sk_buff *skb, struct vlan_group *grp, |
8 | unsigned short vlan_tag, int polling) | 8 | u16 vlan_tci, int polling) |
9 | { | 9 | { |
10 | struct net_device_stats *stats; | 10 | struct net_device_stats *stats; |
11 | 11 | ||
@@ -14,7 +14,7 @@ int __vlan_hwaccel_rx(struct sk_buff *skb, struct vlan_group *grp, | |||
14 | return NET_RX_DROP; | 14 | return NET_RX_DROP; |
15 | } | 15 | } |
16 | 16 | ||
17 | skb->dev = vlan_group_get_device(grp, vlan_tag & VLAN_VID_MASK); | 17 | skb->dev = vlan_group_get_device(grp, vlan_tci & VLAN_VID_MASK); |
18 | if (skb->dev == NULL) { | 18 | if (skb->dev == NULL) { |
19 | dev_kfree_skb_any(skb); | 19 | dev_kfree_skb_any(skb); |
20 | /* Not NET_RX_DROP, this is not being dropped | 20 | /* Not NET_RX_DROP, this is not being dropped |
@@ -27,7 +27,7 @@ int __vlan_hwaccel_rx(struct sk_buff *skb, struct vlan_group *grp, | |||
27 | stats->rx_packets++; | 27 | stats->rx_packets++; |
28 | stats->rx_bytes += skb->len; | 28 | stats->rx_bytes += skb->len; |
29 | 29 | ||
30 | skb->priority = vlan_get_ingress_priority(skb->dev, vlan_tag); | 30 | skb->priority = vlan_get_ingress_priority(skb->dev, vlan_tci); |
31 | switch (skb->pkt_type) { | 31 | switch (skb->pkt_type) { |
32 | case PACKET_BROADCAST: | 32 | case PACKET_BROADCAST: |
33 | break; | 33 | break; |