diff options
-rw-r--r-- | drivers/net/sfc/sfe4001.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/drivers/net/sfc/sfe4001.c b/drivers/net/sfc/sfe4001.c index c7c95db2af6d..853057e87fb2 100644 --- a/drivers/net/sfc/sfe4001.c +++ b/drivers/net/sfc/sfe4001.c | |||
@@ -375,17 +375,25 @@ static void sfn4111t_fini(struct efx_nic *efx) | |||
375 | i2c_unregister_device(efx->board_info.hwmon_client); | 375 | i2c_unregister_device(efx->board_info.hwmon_client); |
376 | } | 376 | } |
377 | 377 | ||
378 | static struct i2c_board_info sfn4111t_hwmon_info = { | 378 | static struct i2c_board_info sfn4111t_a0_hwmon_info = { |
379 | I2C_BOARD_INFO("max6647", 0x4e), | 379 | I2C_BOARD_INFO("max6647", 0x4e), |
380 | .irq = -1, | 380 | .irq = -1, |
381 | }; | 381 | }; |
382 | 382 | ||
383 | static struct i2c_board_info sfn4111t_r5_hwmon_info = { | ||
384 | I2C_BOARD_INFO("max6646", 0x4d), | ||
385 | .irq = -1, | ||
386 | }; | ||
387 | |||
383 | int sfn4111t_init(struct efx_nic *efx) | 388 | int sfn4111t_init(struct efx_nic *efx) |
384 | { | 389 | { |
385 | int rc; | 390 | int rc; |
386 | 391 | ||
387 | efx->board_info.hwmon_client = | 392 | efx->board_info.hwmon_client = |
388 | i2c_new_device(&efx->i2c_adap, &sfn4111t_hwmon_info); | 393 | i2c_new_device(&efx->i2c_adap, |
394 | (efx->board_info.minor < 5) ? | ||
395 | &sfn4111t_a0_hwmon_info : | ||
396 | &sfn4111t_r5_hwmon_info); | ||
389 | if (!efx->board_info.hwmon_client) | 397 | if (!efx->board_info.hwmon_client) |
390 | return -EIO; | 398 | return -EIO; |
391 | 399 | ||