Skip to contentSkip to conversation

ADVERTISE_1000XPSE_ASYM

drivers/net/bnx2.c Applied Roel Kluin 3 participants 3 messages Jan 30, 2008 – Feb 1, 2008

Subsystems (2)
lore
Share & tools
lore

Roel Kluin

author
#0 lore raw

In drivers/net/bnx2.c:1285: it reads in function bnx2_setup_remote_phy():

if (pause_adv & (ADVERTISE_1000XPSE_ASYM | ADVERTISE_1000XPSE_ASYM))

Note that the two are the same and this is therefore equivalent to

if (pause_adv & ADVERTISE_1000XPSE_ASYM)

This appears to be incorrect, was maybe '| ADVERTISE_1000XPAUSE' intended?

#1 lore raw
Quoted 10 lines · Roel Kluin

In drivers/net/bnx2.c:1285: it reads in function bnx2_setup_remote_phy():

if (pause_adv & (ADVERTISE_1000XPSE_ASYM | ADVERTISE_1000XPSE_ASYM))

Note that the two are the same and this is therefore equivalent to

if (pause_adv & ADVERTISE_1000XPSE_ASYM)

This appears to be incorrect, was maybe '| ADVERTISE_1000XPAUSE' intended?

Thanks for catching this. The patch below will fix it.

[BNX2]: Fix ASYM PAUSE advertisement for remote PHY.

We were checking for the ASYM_PAUSE bit for 1000Base-X twice instead checking for both the 1000Base-X bit and the 10/100/1000Base-T bit. The purpose of the logic is to tell the firmware that ASYM_PAUSE is set on either the Serdes or Copper interface.

Problem was discovered by Roel Kluin <[email protected]>

drivers/net/bnx2.c +1 -1
index be7e8f8..77400ad 100644
@@ -1429,7 +1429,7 @@ bnx2_setup_remote_phy(struct bnx2 *bp, u8 port)
 
 	if (pause_adv & (ADVERTISE_1000XPAUSE | ADVERTISE_PAUSE_CAP))
 		speed_arg |= BNX2_NETLINK_SET_LINK_FC_SYM_PAUSE;
-	if (pause_adv & (ADVERTISE_1000XPSE_ASYM | ADVERTISE_1000XPSE_ASYM))
+	if (pause_adv & (ADVERTISE_1000XPSE_ASYM | ADVERTISE_PAUSE_ASYM))
 		speed_arg |= BNX2_NETLINK_SET_LINK_FC_ASYM_PAUSE;
 
 	if (port == PORT_TP)
maintainer Applied
#2 lore raw

From: "Michael Chan" <[email protected]>
Date: Wed, 30 Jan 2008 10:51:10 -0800

Quoted 10 lines

[BNX2]: Fix ASYM PAUSE advertisement for remote PHY.

We were checking for the ASYM_PAUSE bit for 1000Base-X twice instead checking for both the 1000Base-X bit and the 10/100/1000Base-T bit. The purpose of the logic is to tell the firmware that ASYM_PAUSE is set on either the Serdes or Copper interface.

Problem was discovered by Roel Kluin <[email protected]>

Applied, thanks Michael.