dect
/
linux-2.6
Archived
13
0
Fork 0

bnx2x: fix vector traveling while looking for an empty entry

Fixes the bug that may prevent from mac to be configured,
while there is an empty slot for it.

Reported-by: Maciej Żenczykowski <zenczykowski@gmail.com>
Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Dmitry Kravkov 2012-03-26 21:08:55 +00:00 committed by David S. Miller
parent 452427b015
commit c54e9bd38a
1 changed files with 1 additions and 1 deletions

View File

@ -3847,7 +3847,7 @@ static bool bnx2x_credit_pool_get_entry(
continue;
/* If we've got here we are going to find a free entry */
for (idx = vec * BNX2X_POOL_VEC_SIZE, i = 0;
for (idx = vec * BIT_VEC64_ELEM_SZ, i = 0;
i < BIT_VEC64_ELEM_SZ; idx++, i++)
if (BIT_VEC64_TEST_BIT(o->pool_mirror, idx)) {