Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d4675b52 authored by Roel Kluin's avatar Roel Kluin Committed by David S. Miller
Browse files

TG3: limit reaches -1



With while (limit--) { ... } limit reaches -1, so 0 means success.

Signed-off-by: default avatarRoel Kluin <roel.kluin@gmail.com>
Acked-by: default avatarMichael Chan <mchan@broadcom.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 89c581b3
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -852,7 +852,7 @@ static int tg3_bmcr_reset(struct tg3 *tp)
		}
		udelay(10);
	}
	if (limit <= 0)
	if (limit < 0)
		return -EBUSY;

	return 0;
@@ -1603,7 +1603,7 @@ static int tg3_wait_macro_done(struct tg3 *tp)
				break;
		}
	}
	if (limit <= 0)
	if (limit < 0)
		return -EBUSY;

	return 0;