diff options
author | Dmitry Kravkov <dmitry@broadcom.com> | 2012-03-26 21:08:55 (GMT) |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-03-28 02:41:34 (GMT) |
commit | c54e9bd38a06babf94fd45e5f1df9a1109e12818 (patch) | |
tree | 7f5beb0b30154920d6c513fc06f786f5e725699a /drivers/net/ethernet/broadcom/bnx2x/bnx2x_sp.c | |
parent | 452427b015b1b0cbbef7b6207908726837d39d57 (diff) | |
download | linux-fsl-qoriq-c54e9bd38a06babf94fd45e5f1df9a1109e12818.tar.xz |
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>
Diffstat (limited to 'drivers/net/ethernet/broadcom/bnx2x/bnx2x_sp.c')
-rw-r--r-- | drivers/net/ethernet/broadcom/bnx2x/bnx2x_sp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sp.c b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sp.c index 3f52fad..5135733 100644 --- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sp.c +++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x_sp.c @@ -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)) { |