aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/sfc
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2010-02-26 02:22:42 -0500
committerDavid S. Miller <davem@davemloft.net>2010-02-26 02:22:42 -0500
commit04488734806948624dabc4514f96f14cd75b9a50 (patch)
tree74f3a3c10a7177a5f86398b83ad7bf0569fe8b89 /drivers/net/sfc
parent54831a83bfe656c4c54e287c734c6b0ccaa3719b (diff)
parentc4d49794ff2838038fd9756eae39c39a5a685833 (diff)
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Diffstat (limited to 'drivers/net/sfc')
-rw-r--r--drivers/net/sfc/falcon_boards.c45
-rw-r--r--drivers/net/sfc/mcdi.c2
2 files changed, 28 insertions, 19 deletions
diff --git a/drivers/net/sfc/falcon_boards.c b/drivers/net/sfc/falcon_boards.c
index bf0b96af5334..5712fddd72f2 100644
--- a/drivers/net/sfc/falcon_boards.c
+++ b/drivers/net/sfc/falcon_boards.c
@@ -29,6 +29,15 @@
29#define FALCON_BOARD_SFN4111T 0x51 29#define FALCON_BOARD_SFN4111T 0x51
30#define FALCON_BOARD_SFN4112F 0x52 30#define FALCON_BOARD_SFN4112F 0x52
31 31
32/* Board temperature is about 15°C above ambient when air flow is
33 * limited. */
34#define FALCON_BOARD_TEMP_BIAS 15
35
36/* SFC4000 datasheet says: 'The maximum permitted junction temperature
37 * is 125°C; the thermal design of the environment for the SFC4000
38 * should aim to keep this well below 100°C.' */
39#define FALCON_JUNC_TEMP_MAX 90
40
32/***************************************************************************** 41/*****************************************************************************
33 * Support for LM87 sensor chip used on several boards 42 * Support for LM87 sensor chip used on several boards
34 */ 43 */
@@ -548,16 +557,16 @@ fail_hwmon:
548static u8 sfe4002_lm87_channel = 0x03; /* use AIN not FAN inputs */ 557static u8 sfe4002_lm87_channel = 0x03; /* use AIN not FAN inputs */
549 558
550static const u8 sfe4002_lm87_regs[] = { 559static const u8 sfe4002_lm87_regs[] = {
551 LM87_IN_LIMITS(0, 0x83, 0x91), /* 2.5V: 1.8V +/- 5% */ 560 LM87_IN_LIMITS(0, 0x7c, 0x99), /* 2.5V: 1.8V +/- 10% */
552 LM87_IN_LIMITS(1, 0x51, 0x5a), /* Vccp1: 1.2V +/- 5% */ 561 LM87_IN_LIMITS(1, 0x4c, 0x5e), /* Vccp1: 1.2V +/- 10% */
553 LM87_IN_LIMITS(2, 0xb6, 0xca), /* 3.3V: 3.3V +/- 5% */ 562 LM87_IN_LIMITS(2, 0xac, 0xd4), /* 3.3V: 3.3V +/- 10% */
554 LM87_IN_LIMITS(3, 0xb0, 0xc9), /* 5V: 4.6-5.2V */ 563 LM87_IN_LIMITS(3, 0xac, 0xd4), /* 5V: 5.0V +/- 10% */
555 LM87_IN_LIMITS(4, 0xb0, 0xe0), /* 12V: 11-14V */ 564 LM87_IN_LIMITS(4, 0xac, 0xe0), /* 12V: 10.8-14V */
556 LM87_IN_LIMITS(5, 0x44, 0x4b), /* Vccp2: 1.0V +/- 5% */ 565 LM87_IN_LIMITS(5, 0x3f, 0x4f), /* Vccp2: 1.0V +/- 10% */
557 LM87_AIN_LIMITS(0, 0xa0, 0xb2), /* AIN1: 1.66V +/- 5% */ 566 LM87_AIN_LIMITS(0, 0x98, 0xbb), /* AIN1: 1.66V +/- 10% */
558 LM87_AIN_LIMITS(1, 0x91, 0xa1), /* AIN2: 1.5V +/- 5% */ 567 LM87_AIN_LIMITS(1, 0x8a, 0xa9), /* AIN2: 1.5V +/- 10% */
559 LM87_TEMP_INT_LIMITS(10, 60), /* board */ 568 LM87_TEMP_INT_LIMITS(0, 80 + FALCON_BOARD_TEMP_BIAS),
560 LM87_TEMP_EXT1_LIMITS(10, 70), /* Falcon */ 569 LM87_TEMP_EXT1_LIMITS(0, FALCON_JUNC_TEMP_MAX),
561 0 570 0
562}; 571};
563 572
@@ -619,14 +628,14 @@ static int sfe4002_init(struct efx_nic *efx)
619static u8 sfn4112f_lm87_channel = 0x03; /* use AIN not FAN inputs */ 628static u8 sfn4112f_lm87_channel = 0x03; /* use AIN not FAN inputs */
620 629
621static const u8 sfn4112f_lm87_regs[] = { 630static const u8 sfn4112f_lm87_regs[] = {
622 LM87_IN_LIMITS(0, 0x83, 0x91), /* 2.5V: 1.8V +/- 5% */ 631 LM87_IN_LIMITS(0, 0x7c, 0x99), /* 2.5V: 1.8V +/- 10% */
623 LM87_IN_LIMITS(1, 0x51, 0x5a), /* Vccp1: 1.2V +/- 5% */ 632 LM87_IN_LIMITS(1, 0x4c, 0x5e), /* Vccp1: 1.2V +/- 10% */
624 LM87_IN_LIMITS(2, 0xb6, 0xca), /* 3.3V: 3.3V +/- 5% */ 633 LM87_IN_LIMITS(2, 0xac, 0xd4), /* 3.3V: 3.3V +/- 10% */
625 LM87_IN_LIMITS(4, 0xb0, 0xe0), /* 12V: 11-14V */ 634 LM87_IN_LIMITS(4, 0xac, 0xe0), /* 12V: 10.8-14V */
626 LM87_IN_LIMITS(5, 0x44, 0x4b), /* Vccp2: 1.0V +/- 5% */ 635 LM87_IN_LIMITS(5, 0x3f, 0x4f), /* Vccp2: 1.0V +/- 10% */
627 LM87_AIN_LIMITS(1, 0x91, 0xa1), /* AIN2: 1.5V +/- 5% */ 636 LM87_AIN_LIMITS(1, 0x8a, 0xa9), /* AIN2: 1.5V +/- 10% */
628 LM87_TEMP_INT_LIMITS(10, 60), /* board */ 637 LM87_TEMP_INT_LIMITS(0, 60 + FALCON_BOARD_TEMP_BIAS),
629 LM87_TEMP_EXT1_LIMITS(10, 70), /* Falcon */ 638 LM87_TEMP_EXT1_LIMITS(0, FALCON_JUNC_TEMP_MAX),
630 0 639 0
631}; 640};
632 641
diff --git a/drivers/net/sfc/mcdi.c b/drivers/net/sfc/mcdi.c
index 86610db2cff5..c48669c77414 100644
--- a/drivers/net/sfc/mcdi.c
+++ b/drivers/net/sfc/mcdi.c
@@ -127,7 +127,7 @@ static int efx_mcdi_poll(struct efx_nic *efx)
127 efx_dword_t reg; 127 efx_dword_t reg;
128 128
129 /* Check for a reboot atomically with respect to efx_mcdi_copyout() */ 129 /* Check for a reboot atomically with respect to efx_mcdi_copyout() */
130 rc = efx_mcdi_poll_reboot(efx); 130 rc = -efx_mcdi_poll_reboot(efx);
131 if (rc) 131 if (rc)
132 goto out; 132 goto out;
133 133