# This is a BitKeeper generated patch for the following project: # Project Name: Linux kernel tree # This patch format is intended for GNU patch command version 2.5 or higher. # This patch includes the following deltas: # ChangeSet 1.1176 -> 1.1177 # include/asm-i386/acpi.h 1.11 -> 1.12 # include/asm-x86_64/acpi.h 1.5 -> 1.6 # drivers/acpi/executer/exfldio.c 1.24 -> 1.25 # arch/x86_64/kernel/e820.c 1.6 -> 1.7 # arch/i386/kernel/setup.c 1.75 -> 1.76 # Documentation/kernel-parameters.txt 1.12 -> 1.13 # arch/i386/kernel/acpi.c 1.20 -> 1.21 # Documentation/Configure.help 1.180 -> 1.181 # include/asm-ia64/acpi.h 1.2 -> 1.3 # arch/x86_64/kernel/acpi.c 1.9 -> 1.10 # # The following is the BitKeeper ChangeSet Log # -------------------------------------------- # 04/02/27 len.brown@intel.com 1.1177 # [ACPI] include CONFIG_ACPI_RELAXED_AML code always # add acpi=strict option to disable platform workarounds # -------------------------------------------- # diff -Nru a/Documentation/Configure.help b/Documentation/Configure.help --- a/Documentation/Configure.help Fri Feb 27 00:54:33 2004 +++ b/Documentation/Configure.help Fri Feb 27 00:54:33 2004 @@ -18983,14 +18983,6 @@ of verbosity. Saying Y enables these statements. This will increase your kernel size by around 50K. -ACPI Relaxed AML Checking -CONFIG_ACPI_RELAXED_AML - If you say `Y' here, the ACPI interpreter will relax its checking - for valid AML and will ignore some AML mistakes, such as off-by-one - errors in region sizes. Some laptops may require this option. In - particular, many Toshiba laptops require this for correct operation - of the AC module. - ACPI Button CONFIG_ACPI_BUTTON This driver registers for events based on buttons, such as the diff -Nru a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt --- a/Documentation/kernel-parameters.txt Fri Feb 27 00:54:33 2004 +++ b/Documentation/kernel-parameters.txt Fri Feb 27 00:54:33 2004 @@ -73,6 +73,8 @@ off Disable ACPI ht Limit ACPI to boot-time LAPIC enumeration for HT, disabling the run-time AML interpreter. + strict Be less tolerant of platforms that are not + strictly ACPI specification compliant. acpi_pic_sci= [HW,ACPI] ACPI System Conrol Interrupt trigger mode level Force PIC-mode SCI to Level Trigger (default) diff -Nru a/arch/i386/kernel/acpi.c b/arch/i386/kernel/acpi.c --- a/arch/i386/kernel/acpi.c Fri Feb 27 00:54:33 2004 +++ b/arch/i386/kernel/acpi.c Fri Feb 27 00:54:33 2004 @@ -49,14 +49,14 @@ #define PREFIX "ACPI: " -int acpi_lapic = 0; -int acpi_ioapic = 0; +int acpi_lapic; +int acpi_ioapic; +int acpi_strict; /* -------------------------------------------------------------------------- Boot-time Configuration -------------------------------------------------------------------------- */ -#ifdef CONFIG_ACPI_BOOT int acpi_noirq __initdata = 0; /* skip ACPI IRQ initialization */ int acpi_ht __initdata = 1; /* enable HT */ @@ -472,7 +472,6 @@ return 0; } -#endif /*CONFIG_ACPI_BOOT*/ #ifdef CONFIG_ACPI_BUS /* diff -Nru a/arch/i386/kernel/setup.c b/arch/i386/kernel/setup.c --- a/arch/i386/kernel/setup.c Fri Feb 27 00:54:33 2004 +++ b/arch/i386/kernel/setup.c Fri Feb 27 00:54:33 2004 @@ -829,6 +829,11 @@ if (!acpi_force) acpi_disabled = 1; } + /* acpi=strict disables out-of-spec workarounds */ + else if (!memcmp(from, "acpi=strict", 11)) { + acpi_strict = 1; + } + else if (!memcmp(from, "pci=noacpi", 10)) { acpi_noirq_set(); } diff -Nru a/arch/x86_64/kernel/acpi.c b/arch/x86_64/kernel/acpi.c --- a/arch/x86_64/kernel/acpi.c Fri Feb 27 00:54:33 2004 +++ b/arch/x86_64/kernel/acpi.c Fri Feb 27 00:54:33 2004 @@ -47,14 +47,14 @@ #define PREFIX "ACPI: " -int acpi_lapic = 0; -int acpi_ioapic = 0; +int acpi_lapic; +int acpi_ioapic; +int acpi_strict; /* -------------------------------------------------------------------------- Boot-time Configuration -------------------------------------------------------------------------- */ -#ifdef CONFIG_ACPI_BOOT enum acpi_irq_model_id acpi_irq_model; @@ -548,8 +548,6 @@ return 0; } - -#endif /*CONFIG_ACPI_BOOT*/ /* -------------------------------------------------------------------------- diff -Nru a/arch/x86_64/kernel/e820.c b/arch/x86_64/kernel/e820.c --- a/arch/x86_64/kernel/e820.c Fri Feb 27 00:54:33 2004 +++ b/arch/x86_64/kernel/e820.c Fri Feb 27 00:54:33 2004 @@ -544,6 +544,11 @@ else if (!memcmp(from, "acpi=off", 8)) acpi_disabled = 1; + /* acpi=strict disables out-of-spec workarounds */ + else if (!memcmp(from, "acpi=strict", 11)) { + acpi_strict = 1; + } + else if (!memcmp(from, "pci=noacpi", 10)) { acpi_noirq_set(); } diff -Nru a/drivers/acpi/executer/exfldio.c b/drivers/acpi/executer/exfldio.c --- a/drivers/acpi/executer/exfldio.c Fri Feb 27 00:54:33 2004 +++ b/drivers/acpi/executer/exfldio.c Fri Feb 27 00:54:33 2004 @@ -154,8 +154,7 @@ field_datum_byte_offset, obj_desc->common_field.access_byte_width, acpi_ut_get_node_name (rgn_desc->region.node), rgn_desc->region.length)); - #ifdef CONFIG_ACPI_RELAXED_AML - { + if (!acpi_strict) { /* * Allow access to the field if it is within the region size * rounded up to a multiple of the access byte width. This @@ -186,9 +185,9 @@ return_ACPI_STATUS (AE_OK); } } - #else + else { return_ACPI_STATUS (AE_AML_REGION_LIMIT); - #endif + } } return_ACPI_STATUS (AE_OK); diff -Nru a/include/asm-i386/acpi.h b/include/asm-i386/acpi.h --- a/include/asm-i386/acpi.h Fri Feb 27 00:54:33 2004 +++ b/include/asm-i386/acpi.h Fri Feb 27 00:54:33 2004 @@ -110,6 +110,7 @@ extern int acpi_lapic; extern int acpi_ioapic; extern int acpi_noirq; +extern int acpi_strict; /* Fixmap pages to reserve for ACPI boot-time tables (see fixmap.h) */ #define FIX_ACPI_PAGES 4 diff -Nru a/include/asm-ia64/acpi.h b/include/asm-ia64/acpi.h --- a/include/asm-ia64/acpi.h Fri Feb 27 00:54:33 2004 +++ b/include/asm-ia64/acpi.h Fri Feb 27 00:54:33 2004 @@ -96,6 +96,8 @@ :"=r"(Acq):"r"(GLptr):"r2","r29","r30","memory"); \ } while (0) +#define acpi_strict 1 /* no ACPI workarounds */ + const char *acpi_get_sysname (void); int acpi_boot_init (char *cdline); int acpi_request_vector (u32 int_type); diff -Nru a/include/asm-x86_64/acpi.h b/include/asm-x86_64/acpi.h --- a/include/asm-x86_64/acpi.h Fri Feb 27 00:54:33 2004 +++ b/include/asm-x86_64/acpi.h Fri Feb 27 00:54:33 2004 @@ -108,6 +108,7 @@ extern int acpi_lapic; extern int acpi_ioapic; extern int acpi_noirq; +extern int acpi_strict; /* Fixmap pages to reserve for ACPI boot-time tables (see fixmap.h) */ #define FIX_ACPI_PAGES 4