summaryrefslogtreecommitdiff
path: root/src/mainboard
diff options
context:
space:
mode:
authorMaggie Li <maggie.li@amd.com>2008-12-05 18:38:57 +0000
committerMarc Jones <marc.jones@amd.com>2008-12-05 18:38:57 +0000
commitf82a07730d033f0c168dd13a7fa5d4d086016376 (patch)
tree80d0ec60eab570d7a7e3a8011728087d9a3d23a7 /src/mainboard
parentc73fca35e273f827ddbffa0719d2edde5c62e7e6 (diff)
The TALERT of ADT7461 should be pull back high if the temperature is within the limit. It is done by reading the register whose device address is 0xC. It is not trivial as it looks.
Signed-off-by: Maggie Li <maggie.li@amd.com> Reviewed-by: Joe Bao <zheng.bao@amd.com> Acked-by: Ronald G. Minnich <rminnich@gmail.com> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3801 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/mainboard')
-rw-r--r--src/mainboard/amd/dbm690t/mainboard.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mainboard/amd/dbm690t/mainboard.c b/src/mainboard/amd/dbm690t/mainboard.c
index 9f0c9398cf..568670f737 100644
--- a/src/mainboard/amd/dbm690t/mainboard.c
+++ b/src/mainboard/amd/dbm690t/mainboard.c
@@ -28,6 +28,7 @@
#include "chip.h"
#define ADT7461_ADDRESS 0x4C
+#define ARA_ADDRESS 0x0C /* Alert Response Address */
#define SMBUS_IO_BASE 0x1000
extern int do_smbus_read_byte(u32 smbus_io_base, u32 device, u32 address);
@@ -35,6 +36,8 @@ extern int do_smbus_write_byte(u32 smbus_io_base, u32 device, u32 address,
u8 val);
#define ADT7461_read_byte(address) \
do_smbus_read_byte(SMBUS_IO_BASE, ADT7461_ADDRESS, address)
+#define ARA_read_byte(address) \
+ do_smbus_read_byte(SMBUS_IO_BASE, ARA_ADDRESS, address)
#define ADT7461_write_byte(address, val) \
do_smbus_write_byte(SMBUS_IO_BASE, ADT7461_ADDRESS, address, val)
@@ -132,6 +135,7 @@ static void set_thermal_config()
ADT7461_write_byte(0x20, 0x55); /* Local THERM limit */
byte = ADT7461_read_byte(0x02); /* read status register to clear it */
+ ARA_read_byte(0x05); /* A hardware alert can only be cleared by the master sending an ARA as a read command */
printk_info("Init adt7461 end , status 0x02 %02x\n", byte);
/* sb600 settings for thermal config */