summaryrefslogtreecommitdiffstats
path: root/drivers/net/bnx2x_main.c
diff options
context:
space:
mode:
authorYaniv Rosner <yanivr@broadcom.com>2008-08-13 15:56:17 -0700
committerDavid S. Miller <davem@davemloft.net>2008-08-13 16:04:30 -0700
commit8c99e7b0436473593a68e740d1032909bc5335a1 (patch)
tree621557728da3ea1bb7cf4e4e08a4c184bf037b4e /drivers/net/bnx2x_main.c
parent57963ed94c27e94a7533434da5943195ea072a35 (diff)
downloadop-kernel-dev-8c99e7b0436473593a68e740d1032909bc5335a1.zip
op-kernel-dev-8c99e7b0436473593a68e740d1032909bc5335a1.tar.gz
bnx2x: Pause settings
Pause settings - 1G pause was not working due to missing write to the emac block (TX_MODE_FLOW_EN) - The flow control should use the negotiated result (after autoneg) so we should save both the requested autoneg and the result - The HW credits with flow control at 1G speed were not optimized and caused low throughput - It is recommended to turn off flow control if the MTU is bigger than 5000B due to internal buffers size Signed-off-by: Yaniv Rosner <yanivr@broadcom.com> Signed-off-by: Eilon Greenstein <eilong@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/bnx2x_main.c')
-rw-r--r--drivers/net/bnx2x_main.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/drivers/net/bnx2x_main.c b/drivers/net/bnx2x_main.c
index d29f227..a37549b 100644
--- a/drivers/net/bnx2x_main.c
+++ b/drivers/net/bnx2x_main.c
@@ -1946,7 +1946,14 @@ static u8 bnx2x_initial_phy_init(struct bnx2x *bp)
u8 rc;
/* Initialize link parameters structure variables */
- bp->link_params.mtu = bp->dev->mtu;
+ /* It is recommended to turn off RX FC for jumbo frames
+ for better performance */
+ if (IS_E1HMF(bp))
+ bp->link_params.req_fc_auto_adv = FLOW_CTRL_BOTH;
+ else if (bp->dev->mtu > 5000)
+ bp->link_params.req_fc_auto_adv = FLOW_CTRL_TX;
+ else
+ bp->link_params.req_fc_auto_adv = FLOW_CTRL_BOTH;
bnx2x_acquire_phy_lock(bp);
rc = bnx2x_phy_init(&bp->link_params, &bp->link_vars);
OpenPOWER on IntegriCloud