Skip to content

Commit 5dcfc06

Browse files
JuliaLawallgregkh
authored andcommitted
bnx2x: use the right constant
[ Upstream commit dd612f1 ] Nearby code that also tests port suggests that the P0 constant should be used when port is zero. The semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression e,e1; @@ * e ? e1 : e1 // </smpl> Fixes: 6c3218c ("bnx2x: Adjust ETS to 578xx") Signed-off-by: Julia Lawall <[email protected]> Signed-off-by: David S. Miller <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 8655f28 commit 5dcfc06

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/broadcom/bnx2x/bnx2x_link.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -594,7 +594,7 @@ static void bnx2x_ets_e3b0_nig_disabled(const struct link_params *params,
594594
* slots for the highest priority.
595595
*/
596596
REG_WR(bp, (port) ? NIG_REG_P1_TX_ARB_NUM_STRICT_ARB_SLOTS :
597-
NIG_REG_P1_TX_ARB_NUM_STRICT_ARB_SLOTS, 0x100);
597+
NIG_REG_P0_TX_ARB_NUM_STRICT_ARB_SLOTS, 0x100);
598598
/* Mapping between the CREDIT_WEIGHT registers and actual client
599599
* numbers
600600
*/

0 commit comments

Comments
 (0)