Subject: [PATCH 2.6.17 1/2] bnx2: Fix bug in bnx2_nvram_write()

From: "Michael Chan" <[email-masked]>
Date: Mon, 22 May 2006 10:01:49 -0700

Fix a bug in bnx2_nvram_write() caused by a counter variable not
correctly incremented by 4.

Signed-off-by: Michael Chan <[email-masked]>

diff --git a/drivers/net/bnx2.c b/drivers/net/bnx2.c
index 5ca99e2..509f104 100644
--- a/drivers/net/bnx2.c
+++ b/drivers/net/bnx2.c
@@ -3061,7 +3061,7 @@ bnx2_nvram_write(struct bnx2 *bp, u32 of
 		}
 
 		/* Loop to write the new data from data_start to data_end */
-		for (addr = data_start; addr < data_end; addr += 4, i++) {
+		for (addr = data_start; addr < data_end; addr += 4, i += 4) {
 			if ((addr == page_end - 4) ||
 				((bp->flash_info->buffered) &&
 				 (addr == data_end - 4))) {