summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorGreg Rose <gregory.v.rose@intel.com>2010-03-24 10:35:42 +0100
committerDavid S. Miller <davem@davemloft.net>2010-03-26 19:56:00 +0100
commit65deeed7b34bc5b8d3cbff495e8fa2ae7b563480 (patch)
treedececb1885019a371596895665765f2a7b15facd /drivers
parentnetxen: update version to 4.0.73 (diff)
downloadlinux-65deeed7b34bc5b8d3cbff495e8fa2ae7b563480.tar.xz
linux-65deeed7b34bc5b8d3cbff495e8fa2ae7b563480.zip
ixgbevf: Fix signed/unsigned int error
In the Tx mapping function if a DMA error occurred then the unwind of previously mapped sections would improperly check an unsigned int if it was less than zero. Changed the index variable to signed to avoid the error. Signed-off-by: Greg Rose <gregory.v.rose@intel.com> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/ixgbevf/ixgbevf_main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/ixgbevf/ixgbevf_main.c b/drivers/net/ixgbevf/ixgbevf_main.c
index d6cbd943a6f0..1bbbef3ee3f4 100644
--- a/drivers/net/ixgbevf/ixgbevf_main.c
+++ b/drivers/net/ixgbevf/ixgbevf_main.c
@@ -2943,9 +2943,10 @@ static int ixgbevf_tx_map(struct ixgbevf_adapter *adapter,
struct ixgbevf_tx_buffer *tx_buffer_info;
unsigned int len;
unsigned int total = skb->len;
- unsigned int offset = 0, size, count = 0, i;
+ unsigned int offset = 0, size, count = 0;
unsigned int nr_frags = skb_shinfo(skb)->nr_frags;
unsigned int f;
+ int i;
i = tx_ring->next_to_use;