diff options
Diffstat (limited to 'drivers/net/sfc/tenxpress.c')
-rw-r--r-- | drivers/net/sfc/tenxpress.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/drivers/net/sfc/tenxpress.c b/drivers/net/sfc/tenxpress.c index 390b27b5ace9..19c78d281700 100644 --- a/drivers/net/sfc/tenxpress.c +++ b/drivers/net/sfc/tenxpress.c | |||
@@ -83,9 +83,9 @@ | |||
83 | #define PMA_PMD_LED_FLASH (3) | 83 | #define PMA_PMD_LED_FLASH (3) |
84 | #define PMA_PMD_LED_MASK 3 | 84 | #define PMA_PMD_LED_MASK 3 |
85 | /* All LEDs under hardware control */ | 85 | /* All LEDs under hardware control */ |
86 | #define PMA_PMD_LED_FULL_AUTO (0) | 86 | #define SFT9001_PMA_PMD_LED_DEFAULT 0 |
87 | /* Green and Amber under hardware control, Red off */ | 87 | /* Green and Amber under hardware control, Red off */ |
88 | #define PMA_PMD_LED_DEFAULT (PMA_PMD_LED_OFF << PMA_PMD_LED_RX_LBN) | 88 | #define SFX7101_PMA_PMD_LED_DEFAULT (PMA_PMD_LED_OFF << PMA_PMD_LED_RX_LBN) |
89 | 89 | ||
90 | #define PMA_PMD_SPEED_ENABLE_REG 49192 | 90 | #define PMA_PMD_SPEED_ENABLE_REG 49192 |
91 | #define PMA_PMD_100TX_ADV_LBN 1 | 91 | #define PMA_PMD_100TX_ADV_LBN 1 |
@@ -291,7 +291,7 @@ static int tenxpress_init(struct efx_nic *efx) | |||
291 | efx_mdio_set_flag(efx, MDIO_MMD_PMAPMD, PMA_PMD_LED_CTRL_REG, | 291 | efx_mdio_set_flag(efx, MDIO_MMD_PMAPMD, PMA_PMD_LED_CTRL_REG, |
292 | 1 << PMA_PMA_LED_ACTIVITY_LBN, true); | 292 | 1 << PMA_PMA_LED_ACTIVITY_LBN, true); |
293 | efx_mdio_write(efx, MDIO_MMD_PMAPMD, PMA_PMD_LED_OVERR_REG, | 293 | efx_mdio_write(efx, MDIO_MMD_PMAPMD, PMA_PMD_LED_OVERR_REG, |
294 | PMA_PMD_LED_DEFAULT); | 294 | SFX7101_PMA_PMD_LED_DEFAULT); |
295 | } | 295 | } |
296 | 296 | ||
297 | return 0; | 297 | return 0; |
@@ -624,7 +624,10 @@ void tenxpress_phy_blink(struct efx_nic *efx, bool blink) | |||
624 | (PMA_PMD_LED_FLASH << PMA_PMD_LED_RX_LBN) | | 624 | (PMA_PMD_LED_FLASH << PMA_PMD_LED_RX_LBN) | |
625 | (PMA_PMD_LED_FLASH << PMA_PMD_LED_LINK_LBN); | 625 | (PMA_PMD_LED_FLASH << PMA_PMD_LED_LINK_LBN); |
626 | else | 626 | else |
627 | reg = PMA_PMD_LED_DEFAULT; | 627 | if (efx->phy_type == PHY_TYPE_SFX7101) |
628 | reg = SFX7101_PMA_PMD_LED_DEFAULT; | ||
629 | else | ||
630 | reg = SFT9001_PMA_PMD_LED_DEFAULT; | ||
628 | 631 | ||
629 | efx_mdio_write(efx, MDIO_MMD_PMAPMD, PMA_PMD_LED_OVERR_REG, reg); | 632 | efx_mdio_write(efx, MDIO_MMD_PMAPMD, PMA_PMD_LED_OVERR_REG, reg); |
630 | } | 633 | } |