diff options
author | Yaniv Rosner <yanivr@broadcom.com> | 2008-08-13 18:56:17 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-08-13 19:04:30 -0400 |
commit | 8c99e7b0436473593a68e740d1032909bc5335a1 (patch) | |
tree | 621557728da3ea1bb7cf4e4e08a4c184bf037b4e /drivers/net/bnx2x_main.c | |
parent | 57963ed94c27e94a7533434da5943195ea072a35 (diff) |
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.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/drivers/net/bnx2x_main.c b/drivers/net/bnx2x_main.c index d29f22763fec..a37549b5bc1c 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) | |||
1946 | u8 rc; | 1946 | u8 rc; |
1947 | 1947 | ||
1948 | /* Initialize link parameters structure variables */ | 1948 | /* Initialize link parameters structure variables */ |
1949 | bp->link_params.mtu = bp->dev->mtu; | 1949 | /* It is recommended to turn off RX FC for jumbo frames |
1950 | for better performance */ | ||
1951 | if (IS_E1HMF(bp)) | ||
1952 | bp->link_params.req_fc_auto_adv = FLOW_CTRL_BOTH; | ||
1953 | else if (bp->dev->mtu > 5000) | ||
1954 | bp->link_params.req_fc_auto_adv = FLOW_CTRL_TX; | ||
1955 | else | ||
1956 | bp->link_params.req_fc_auto_adv = FLOW_CTRL_BOTH; | ||
1950 | 1957 | ||
1951 | bnx2x_acquire_phy_lock(bp); | 1958 | bnx2x_acquire_phy_lock(bp); |
1952 | rc = bnx2x_phy_init(&bp->link_params, &bp->link_vars); | 1959 | rc = bnx2x_phy_init(&bp->link_params, &bp->link_vars); |