[coreboot] [patch 1/3] Add acpi_get_sleep_type() to i82371eb and P2B _PTS/_WAK methods

Uwe Hermann uwe at hermann-uwe.de
Fri Dec 3 00:35:31 CET 2010


On Wed, Dec 01, 2010 at 08:46:56PM +0100, Tobias Diedrich wrote:
> Signed-off-by: Tobias Diedrich <ranma+coreboot at tdiedrich.de>

Looks good (though not tested on hardware by me).

Acked-by: Uwe Hermann <uwe at hermann-uwe.de>


> Index: src/arch/i386/boot/acpi.c
> ===================================================================
> --- src/arch/i386/boot/acpi.c.orig	2010-12-01 17:50:18.000000000 +0100
> +++ src/arch/i386/boot/acpi.c	2010-12-01 17:54:01.000000000 +0100

Hm, are you diffing this stuff by hand? If so, "svn diff > foo.patch" from
the top-level dir is much simpler.


> Index: src/southbridge/intel/i82371eb/i82371eb_smbus.c
> ===================================================================
> --- src/southbridge/intel/i82371eb/i82371eb_smbus.c.orig	2010-12-01 17:50:26.000000000 +0100
> +++ src/southbridge/intel/i82371eb/i82371eb_smbus.c	2010-12-01 17:57:09.000000000 +0100
> @@ -87,7 +88,13 @@
>  	outw(0xffff,     DEFAULT_PMBASE + GLBSTS);
>  	outl(0xffffffff, DEFAULT_PMBASE + DEVSTS);
>  
> -	/* set pmcntrl default */
> +#if CONFIG_HAVE_ACPI_RESUME == 1

No "== 1" needed.

  
> Index: src/lib/cbmem.c
> ===================================================================
> --- src/lib/cbmem.c.orig	2010-12-01 17:50:18.000000000 +0100
> +++ src/lib/cbmem.c	2010-12-01 17:54:01.000000000 +0100
> @@ -198,8 +198,10 @@
>  void cbmem_initialize(void)
>  {
>  #if CONFIG_HAVE_ACPI_RESUME
> -	if (acpi_slp_type == 3) {
> +	/* Both resume from S2 and resume from S3 restart at CPU reset */
> +	if (acpi_slp_type == 3 || acpi_slp_type == 2) {
>  		if (!cbmem_reinit(high_tables_base)) {
> +			printk(BIOS_DEBUG, "cbmem_reinit failed\n");

Does printk work at this stage already? Hm, guess it should.


> Index: src/southbridge/intel/i82371eb/i82371eb_wakeup.c
> ===================================================================
> --- /dev/null	1970-01-01 00:00:00.000000000 +0000
> +++ src/southbridge/intel/i82371eb/i82371eb_wakeup.c	2010-12-01 17:53:27.000000000 +0100
> @@ -0,0 +1,59 @@
> +/*
> + * This file is part of the coreboot project.
> + *
> + * Copyright (C) 2010 Uwe Hermann <uwe at hermann-uwe.de>

Nope, (C) Tobias Diedrich, I didn't write any of this.


Uwe.
-- 
http://hermann-uwe.de     | http://sigrok.org
http://randomprojects.org | http://unmaintained-free-software.org




More information about the coreboot mailing list