Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 159693
b: refs/heads/master
c: 724b694
h: refs/heads/master
i:
  159691: 25109f2
v: v3
  • Loading branch information
Stephen Hemminger authored and David S. Miller committed Aug 19, 2009
1 parent e98bc7c commit 54953d2
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 15 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: 6b84dacadbdc3dab6a5b313d20d5a93b0d998641
refs/heads/master: 724b694225e711f95e6265afdbc304c9e7eb3721
16 changes: 3 additions & 13 deletions trunk/drivers/net/sky2.c
Original file line number Diff line number Diff line change
Expand Up @@ -1177,7 +1177,6 @@ static void sky2_rx_clean(struct sky2_port *sky2)
re->skb = NULL;
}
}
skb_queue_purge(&sky2->rx_recycle);
}

/* Basic MII support */
Expand Down Expand Up @@ -1269,10 +1268,8 @@ static struct sk_buff *sky2_rx_alloc(struct sky2_port *sky2)
struct sk_buff *skb;
int i;

skb = __skb_dequeue(&sky2->rx_recycle);
if (!skb)
skb = netdev_alloc_skb(sky2->netdev, sky2->rx_data_size
+ sky2_rx_pad(sky2->hw));
skb = netdev_alloc_skb(sky2->netdev,
sky2->rx_data_size + sky2_rx_pad(sky2->hw));
if (!skb)
goto nomem;

Expand Down Expand Up @@ -1364,8 +1361,6 @@ static int sky2_rx_start(struct sky2_port *sky2)

sky2->rx_data_size = size;

skb_queue_head_init(&sky2->rx_recycle);

/* Fill Rx ring */
for (i = 0; i < sky2->rx_pending; i++) {
re = sky2->rx_ring + i;
Expand Down Expand Up @@ -1776,12 +1771,7 @@ static void sky2_tx_complete(struct sky2_port *sky2, u16 done)
dev->stats.tx_packets++;
dev->stats.tx_bytes += skb->len;

if (skb_queue_len(&sky2->rx_recycle) < sky2->rx_pending
&& skb_recycle_check(skb, sky2->rx_data_size
+ sky2_rx_pad(sky2->hw)))
__skb_queue_head(&sky2->rx_recycle, skb);
else
dev_kfree_skb_any(skb);
dev_kfree_skb_any(skb);

sky2->tx_next = RING_NEXT(idx, sky2->tx_ring_size);
}
Expand Down
1 change: 0 additions & 1 deletion trunk/drivers/net/sky2.h
Original file line number Diff line number Diff line change
Expand Up @@ -2032,7 +2032,6 @@ struct sky2_port {
u16 rx_pending;
u16 rx_data_size;
u16 rx_nfrags;
struct sk_buff_head rx_recycle;

#ifdef SKY2_VLAN_TAG_USED
u16 rx_tag;
Expand Down

0 comments on commit 54953d2

Please sign in to comment.