Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 150301
b: refs/heads/master
c: 450c4ea
h: refs/heads/master
i:
  150299: 4e922b4
v: v3
  • Loading branch information
Eric Dumazet authored and David S. Miller committed May 18, 2009
1 parent a78bfaf commit 48d67d7
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 9 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7004bf252c53da18f6b55103e0c92f777f846806
refs/heads/master: 450c4ea15ecb89567e6a75b89cbb8a598a7efb75
14 changes: 7 additions & 7 deletions trunk/net/8021q/vlan_dev.c
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ static int vlan_dev_hard_header(struct sk_buff *skb, struct net_device *dev,

static int vlan_dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev)
{
struct net_device_stats *stats = &dev->stats;
struct netdev_queue *txq = netdev_get_tx_queue(dev, 0);
struct vlan_ethhdr *veth = (struct vlan_ethhdr *)(skb->data);

/* Handle non-VLAN frames if they are sent to us, for example by DHCP.
Expand All @@ -309,16 +309,16 @@ static int vlan_dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev)
vlan_tci |= vlan_dev_get_egress_qos_mask(dev, skb);
skb = __vlan_put_tag(skb, vlan_tci);
if (!skb) {
stats->tx_dropped++;
txq->tx_dropped++;
return NETDEV_TX_OK;
}

if (orig_headroom < VLAN_HLEN)
vlan_dev_info(dev)->cnt_inc_headroom_on_tx++;
}

stats->tx_packets++;
stats->tx_bytes += skb->len;
txq->tx_packets++;
txq->tx_bytes += skb->len;

skb->dev = vlan_dev_info(dev)->real_dev;
dev_queue_xmit(skb);
Expand All @@ -328,15 +328,15 @@ static int vlan_dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev)
static int vlan_dev_hwaccel_hard_start_xmit(struct sk_buff *skb,
struct net_device *dev)
{
struct net_device_stats *stats = &dev->stats;
struct netdev_queue *txq = netdev_get_tx_queue(dev, 0);
u16 vlan_tci;

vlan_tci = vlan_dev_info(dev)->vlan_id;
vlan_tci |= vlan_dev_get_egress_qos_mask(dev, skb);
skb = __vlan_hwaccel_put_tag(skb, vlan_tci);

stats->tx_packets++;
stats->tx_bytes += skb->len;
txq->tx_packets++;
txq->tx_bytes += skb->len;

skb->dev = vlan_dev_info(dev)->real_dev;
dev_queue_xmit(skb);
Expand Down
3 changes: 2 additions & 1 deletion trunk/net/8021q/vlanproc.c
Original file line number Diff line number Diff line change
Expand Up @@ -279,13 +279,14 @@ static int vlandev_seq_show(struct seq_file *seq, void *offset)
{
struct net_device *vlandev = (struct net_device *) seq->private;
const struct vlan_dev_info *dev_info = vlan_dev_info(vlandev);
struct net_device_stats *stats = &vlandev->stats;
const struct net_device_stats *stats;
static const char fmt[] = "%30s %12lu\n";
int i;

if (!is_vlan_dev(vlandev))
return 0;

stats = dev_get_stats(vlandev);
seq_printf(seq,
"%s VID: %d REORDER_HDR: %i dev->priv_flags: %hx\n",
vlandev->name, dev_info->vlan_id,
Expand Down

0 comments on commit 48d67d7

Please sign in to comment.