aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/net/bnx2x_link.c38
-rw-r--r--drivers/net/bnx2x_reg.h1
2 files changed, 9 insertions, 30 deletions
diff --git a/drivers/net/bnx2x_link.c b/drivers/net/bnx2x_link.c
index 1b73c1d72fc1..d2c9e19bcd5a 100644
--- a/drivers/net/bnx2x_link.c
+++ b/drivers/net/bnx2x_link.c
@@ -3533,8 +3533,8 @@ static void bnx2x_8481_set_10G_led_mode(struct link_params *params,
3533 MDIO_PMA_REG_8481_LINK_SIGNAL, 3533 MDIO_PMA_REG_8481_LINK_SIGNAL,
3534 &val1); 3534 &val1);
3535 /* Set bit 2 to 0, and bits [1:0] to 10 */ 3535 /* Set bit 2 to 0, and bits [1:0] to 10 */
3536 val1 &= ~((1<<0) | (1<<2)); /* Clear bits 0,2*/ 3536 val1 &= ~((1<<0) | (1<<2) | (1<<7)); /* Clear bits 0,2,7*/
3537 val1 |= (1<<1); /* Set bit 1 */ 3537 val1 |= ((1<<1) | (1<<6)); /* Set bit 1, 6 */
3538 3538
3539 bnx2x_cl45_write(bp, params->port, 3539 bnx2x_cl45_write(bp, params->port,
3540 ext_phy_type, 3540 ext_phy_type,
@@ -3568,36 +3568,19 @@ static void bnx2x_8481_set_10G_led_mode(struct link_params *params,
3568 MDIO_PMA_REG_8481_LED2_MASK, 3568 MDIO_PMA_REG_8481_LED2_MASK,
3569 0); 3569 0);
3570 3570
3571 /* LED3 (10G/1G/100/10G Activity) */ 3571 /* Unmask LED3 for 10G link */
3572 bnx2x_cl45_read(bp, params->port,
3573 ext_phy_type,
3574 ext_phy_addr,
3575 MDIO_PMA_DEVAD,
3576 MDIO_PMA_REG_8481_LINK_SIGNAL,
3577 &val1);
3578 /* Enable blink based on source 4(Activity) */
3579 val1 &= ~((1<<7) | (1<<8)); /* Clear bits 7,8 */
3580 val1 |= (1<<6); /* Set only bit 6 */
3581 bnx2x_cl45_write(bp, params->port, 3572 bnx2x_cl45_write(bp, params->port,
3582 ext_phy_type, 3573 ext_phy_type,
3583 ext_phy_addr, 3574 ext_phy_addr,
3584 MDIO_PMA_DEVAD, 3575 MDIO_PMA_DEVAD,
3585 MDIO_PMA_REG_8481_LINK_SIGNAL,
3586 val1);
3587
3588 bnx2x_cl45_read(bp, params->port,
3589 ext_phy_type,
3590 ext_phy_addr,
3591 MDIO_PMA_DEVAD,
3592 MDIO_PMA_REG_8481_LED3_MASK, 3576 MDIO_PMA_REG_8481_LED3_MASK,
3593 &val1); 3577 0x6);
3594 val1 |= (1<<4); /* Unmask LED3 for 10G link */
3595 bnx2x_cl45_write(bp, params->port, 3578 bnx2x_cl45_write(bp, params->port,
3596 ext_phy_type, 3579 ext_phy_type,
3597 ext_phy_addr, 3580 ext_phy_addr,
3598 MDIO_PMA_DEVAD, 3581 MDIO_PMA_DEVAD,
3599 MDIO_PMA_REG_8481_LED3_MASK, 3582 MDIO_PMA_REG_8481_LED3_BLINK,
3600 val1); 3583 0);
3601} 3584}
3602 3585
3603 3586
@@ -4476,17 +4459,12 @@ static u8 bnx2x_ext_phy_init(struct link_params *params, struct link_vars *vars)
4476 PORT_HW_CFG_SPEED_CAPABILITY_D0_10G) { 4459 PORT_HW_CFG_SPEED_CAPABILITY_D0_10G) {
4477 DP(NETIF_MSG_LINK, "Advertising 10G\n"); 4460 DP(NETIF_MSG_LINK, "Advertising 10G\n");
4478 /* Restart autoneg for 10G*/ 4461 /* Restart autoneg for 10G*/
4479 bnx2x_cl45_read(bp, params->port, 4462
4480 ext_phy_type,
4481 ext_phy_addr,
4482 MDIO_AN_DEVAD,
4483 MDIO_AN_REG_CTRL, &val);
4484 val |= 0x200;
4485 bnx2x_cl45_write(bp, params->port, 4463 bnx2x_cl45_write(bp, params->port,
4486 ext_phy_type, 4464 ext_phy_type,
4487 ext_phy_addr, 4465 ext_phy_addr,
4488 MDIO_AN_DEVAD, 4466 MDIO_AN_DEVAD,
4489 MDIO_AN_REG_CTRL, val); 4467 MDIO_AN_REG_CTRL, 0x3200);
4490 } 4468 }
4491 } else { 4469 } else {
4492 /* Force speed */ 4470 /* Force speed */
diff --git a/drivers/net/bnx2x_reg.h b/drivers/net/bnx2x_reg.h
index 4be9bab42f5c..b668173ffcb4 100644
--- a/drivers/net/bnx2x_reg.h
+++ b/drivers/net/bnx2x_reg.h
@@ -5129,6 +5129,7 @@ Theotherbitsarereservedandshouldbezero*/
5129#define MDIO_PMA_REG_8481_LED1_MASK 0xa82c 5129#define MDIO_PMA_REG_8481_LED1_MASK 0xa82c
5130#define MDIO_PMA_REG_8481_LED2_MASK 0xa82f 5130#define MDIO_PMA_REG_8481_LED2_MASK 0xa82f
5131#define MDIO_PMA_REG_8481_LED3_MASK 0xa832 5131#define MDIO_PMA_REG_8481_LED3_MASK 0xa832
5132#define MDIO_PMA_REG_8481_LED3_BLINK 0xa834
5132#define MDIO_PMA_REG_8481_SIGNAL_MASK 0xa835 5133#define MDIO_PMA_REG_8481_SIGNAL_MASK 0xa835
5133#define MDIO_PMA_REG_8481_LINK_SIGNAL 0xa83b 5134#define MDIO_PMA_REG_8481_LINK_SIGNAL 0xa83b
5134 5135