From 7856c3d6289ed0fc8bd05d5d5200d7497e6c24aa Mon Sep 17 00:00:00 2001 From: Nick Nunley Date: Wed, 17 Feb 2010 01:06:16 +0000 Subject: [PATCH] --- yaml --- r: 184274 b: refs/heads/master c: a77ff709dd30a263f8154b05a8514b46098b42ba h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/net/igb/igb_main.c | 8 +++----- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/[refs] b/[refs] index 2677644127fc..efa27e762dfc 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 58fd62f525e1182fbb2f7566aecb4545720d9aad +refs/heads/master: a77ff709dd30a263f8154b05a8514b46098b42ba diff --git a/trunk/drivers/net/igb/igb_main.c b/trunk/drivers/net/igb/igb_main.c index ab7c5e97ed02..f588e49c65f1 100644 --- a/trunk/drivers/net/igb/igb_main.c +++ b/trunk/drivers/net/igb/igb_main.c @@ -3647,14 +3647,12 @@ static inline int igb_tx_map_adv(struct igb_ring *tx_ring, struct sk_buff *skb, buffer_info->length = 0; buffer_info->next_to_watch = 0; buffer_info->mapped_as_page = false; - count--; /* clear timestamp and dma mappings for remaining portion of packet */ - while (count >= 0) { - count--; + while (count--) { + if (i == 0) + i = tx_ring->count; i--; - if (i < 0) - i += tx_ring->count; buffer_info = &tx_ring->buffer_info[i]; igb_unmap_and_free_tx_resource(tx_ring, buffer_info); }