diff options
author | Chien Tung <ctung@neteffect.com> | 2008-09-26 16:08:10 -0400 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2008-09-30 18:35:47 -0400 |
commit | e88bd7b624133e0b07adb21c45c9e6f68f8fdda2 (patch) | |
tree | 17311ea7eec42c441a31be207705737a53aab9ce /drivers/infiniband | |
parent | 2b537c2824194d50072ab260f54d6fe4cb8d17e8 (diff) |
RDMA/nes: Fix MDC setting
Clear MDC bits before setting them to a new value. Adjust MDC value
for 10G.
Signed-off-by: Sweta Bhatt <sweta.bhatt@einfochips.com>
Signed-off-by: Chien Tung <ctung@neteffect.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/hw/nes/nes_hw.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/nes/nes_hw.c b/drivers/infiniband/hw/nes/nes_hw.c index 0e259a8b307f..1437b6e397bc 100644 --- a/drivers/infiniband/hw/nes/nes_hw.c +++ b/drivers/infiniband/hw/nes/nes_hw.c | |||
@@ -1262,6 +1262,7 @@ int nes_init_phy(struct nes_device *nesdev) | |||
1262 | if (nesadapter->phy_type[mac_index] == NES_PHY_TYPE_1G) { | 1262 | if (nesadapter->phy_type[mac_index] == NES_PHY_TYPE_1G) { |
1263 | printk(PFX "%s: Programming mdc config for 1G\n", __func__); | 1263 | printk(PFX "%s: Programming mdc config for 1G\n", __func__); |
1264 | tx_config = nes_read_indexed(nesdev, NES_IDX_MAC_TX_CONFIG); | 1264 | tx_config = nes_read_indexed(nesdev, NES_IDX_MAC_TX_CONFIG); |
1265 | tx_config &= 0xFFFFFFE3; | ||
1265 | tx_config |= 0x04; | 1266 | tx_config |= 0x04; |
1266 | nes_write_indexed(nesdev, NES_IDX_MAC_TX_CONFIG, tx_config); | 1267 | nes_write_indexed(nesdev, NES_IDX_MAC_TX_CONFIG, tx_config); |
1267 | } | 1268 | } |
@@ -1327,7 +1328,8 @@ int nes_init_phy(struct nes_device *nesdev) | |||
1327 | (nesadapter->phy_type[mac_index] == NES_PHY_TYPE_ARGUS)) { | 1328 | (nesadapter->phy_type[mac_index] == NES_PHY_TYPE_ARGUS)) { |
1328 | /* setup 10G MDIO operation */ | 1329 | /* setup 10G MDIO operation */ |
1329 | tx_config = nes_read_indexed(nesdev, NES_IDX_MAC_TX_CONFIG); | 1330 | tx_config = nes_read_indexed(nesdev, NES_IDX_MAC_TX_CONFIG); |
1330 | tx_config |= 0x14; | 1331 | tx_config &= 0xFFFFFFE3; |
1332 | tx_config |= 0x15; | ||
1331 | nes_write_indexed(nesdev, NES_IDX_MAC_TX_CONFIG, tx_config); | 1333 | nes_write_indexed(nesdev, NES_IDX_MAC_TX_CONFIG, tx_config); |
1332 | } | 1334 | } |
1333 | if ((nesadapter->phy_type[mac_index] == NES_PHY_TYPE_ARGUS)) { | 1335 | if ((nesadapter->phy_type[mac_index] == NES_PHY_TYPE_ARGUS)) { |