diff options
author | Stefan Reinauer <stepan@coresystems.de> | 2009-07-21 21:58:20 +0000 |
---|---|---|
committer | Stefan Reinauer <stepan@openbios.org> | 2009-07-21 21:58:20 +0000 |
commit | a5fdadfa18fce0dfa60f6ae45b877173d9fa312b (patch) | |
tree | 033901051881e3881f329d223e5f13b9e6326d86 /src/mainboard/kontron/986lcd-m/auto.c | |
parent | e1a66573b15840f2d434f0736280264a99e2250e (diff) | |
download | coreboot-a5fdadfa18fce0dfa60f6ae45b877173d9fa312b.tar.xz |
Kontron updates, get board up to date with i945 and ich7 updates.
Move interrupt routing to mainboard specific code.
Signed-off-by: Stefan Reinauer <stepan@coresystems.de>
Acked-by: Peter Stuge <peter@stuge.se>
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@4458 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/mainboard/kontron/986lcd-m/auto.c')
-rw-r--r-- | src/mainboard/kontron/986lcd-m/auto.c | 31 |
1 files changed, 30 insertions, 1 deletions
diff --git a/src/mainboard/kontron/986lcd-m/auto.c b/src/mainboard/kontron/986lcd-m/auto.c index 781ef2ceba..0b401f9595 100644 --- a/src/mainboard/kontron/986lcd-m/auto.c +++ b/src/mainboard/kontron/986lcd-m/auto.c @@ -39,6 +39,12 @@ #include "arch/i386/lib/console.c" #include <cpu/x86/bist.h> +#if CONFIG_USBDEBUG_DIRECT +#define DBGP_DEFAULT 1 +#include "southbridge/intel/i82801gx/i82801gx_usb_debug.c" +#include "pc80/usbdebug_direct_serial.c" +#endif + #include "ram/ramtest.c" #include "southbridge/intel/i82801gx/i82801gx_early_smbus.c" #include "reset.c" @@ -48,7 +54,7 @@ #define SERIAL_DEV PNP_DEV(0x2e, W83627THG_SP1) -#include "northbridge/intel/i945/ich7.h" +#include "southbridge/intel/i82801gx/i82801gx.h" static void setup_ich7_gpios(void) { /* TODO: This is highly board specific and should be moved */ @@ -302,6 +308,7 @@ static void early_ich7_init(void) void real_main(unsigned long bist) { + u32 reg32; int boot_mode = 0; if (bist == 0) { @@ -313,6 +320,12 @@ void real_main(unsigned long bist) /* Set up the console */ uart_init(); + +#if CONFIG_USBDEBUG_DIRECT + i82801gx_enable_usbdebug_direct(DBGP_DEFAULT); + early_usbdebug_direct_init(); +#endif + console_init(); /* Halt if there was a built in self test failure */ @@ -328,6 +341,22 @@ void real_main(unsigned long bist) */ i945_early_initialization(); + /* Read PM1_CNT */ + reg32 = inl(DEFAULT_PMBASE + 0x04); + printk_debug("PM1_CNT: %08x\n", reg32); + if (((reg32 >> 10) & 7) == 5) { +#if HAVE_ACPI_RESUME + printk_debug("Resume from S3 detected.\n"); + boot_mode = 2; + /* Clear SLP_TYPE. This will break stage2 but + * we care for that when we get there. + */ + outl(reg32 & ~(7 << 10), DEFAULT_PMBASE + 0x04); +#else + printk_debug("Resume from S3 detected, but disabled.\n"); +#endif + } + /* Enable SPD ROMs and DDR-II DRAM */ enable_smbus(); |