# 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.1315+1.1130.1.2 -> 1.1315.9.1 # include/linux/acpi.h 1.27.1.1 -> 1.29 # arch/i386/Kconfig 1.69.1.1 -> 1.77 # arch/i386/kernel/mpparse.c 1.46.1.1 -> 1.51 # arch/i386/kernel/dmi_scan.c 1.40.1.1 -> 1.45 # init/do_mounts.c 1.52.2.1 -> 1.56 # arch/i386/kernel/setup.c 1.90.1.2 -> 1.97 # init/do_mounts.h 1.7 -> 1.8 # arch/i386/kernel/acpi/boot.c 1.27.2.1 -> 1.32 # include/asm-i386/acpi.h 1.7.1.1 -> 1.9 # drivers/acpi/Kconfig 1.15.1.2 -> 1.21 # diff -Nru a/arch/i386/Kconfig b/arch/i386/Kconfig --- a/arch/i386/Kconfig Tue Sep 23 12:29:42 2003 +++ b/arch/i386/Kconfig Tue Sep 23 12:29:42 2003 @@ -276,9 +276,9 @@ help Select this for an IDT Winchip-2A or 3. Linux and GCC treat this chip as a 586TSC with some extended instructions - and alignment reqirements. Development kernels also enable - out of order memory stores for this CPU, which can increase - performance of some operations. + and alignment reqirements. Also enable out of order memory + stores for this CPU, which can increase performance of some + operations. config MCYRIXIII bool "CyrixIII/VIA-C3" @@ -408,6 +408,20 @@ Otherwise, say N. +config HPET_TIMER + bool "HPET Timer Support" + help + This enables the use of the HPET for the kernel's internal timer. + HPET is the next generation timer replacing legacy 8254s. + You can safely choose Y here. However, HPET will only be + activated if the platform and the BIOS support this feature. + Otherwise the 8254 will be used for timing services. + + Choose N to continue using the legacy 8254 timer. + +config HPET_EMULATE_RTC + def_bool HPET_TIMER && RTC=y + config SMP bool "Symmetric multi-processing support" ---help--- @@ -438,9 +452,10 @@ If you don't know what to do here, say N. config NR_CPUS - int "Maximum number of CPUs (2-32)" + int "Maximum number of CPUs (2-255)" depends on SMP - default "32" + default "32" if X86_NUMAQ || X86_SUMMIT || X86_BIGSMP || X86_ES7000 + default "8" help This allows you to specify the maximum number of CPUs which this kernel will support. The maximum supported value is 32 and the @@ -1155,40 +1170,6 @@ menu "Executable file formats" - -choice - prompt "Kernel core (/proc/kcore) format" - depends on PROC_FS - default KCORE_ELF - -config KCORE_ELF - bool "ELF" - ---help--- - If you enabled support for /proc file system then the file - /proc/kcore will contain the kernel core image. This can be used - in gdb: - - $ cd /usr/src/linux ; gdb vmlinux /proc/kcore - - You have two choices here: ELF and A.OUT. Selecting ELF will make - /proc/kcore appear in ELF core format as defined by the Executable - and Linking Format specification. Selecting A.OUT will choose the - old "a.out" format which may be necessary for some old versions - of binutils or on some architectures. - - This is especially useful if you have compiled the kernel with the - "-g" option to preserve debugging information. It is mainly used - for examining kernel data structures on the live kernel so if you - don't understand what this means or are not a kernel hacker, just - leave it at its default value ELF. - -config KCORE_AOUT - bool "A.OUT" - help - Not necessary unless you're using a very out-of-date binutils - version. You probably want KCORE_ELF. - -endchoice source "fs/Kconfig.binfmt" diff -Nru a/arch/i386/kernel/acpi/boot.c b/arch/i386/kernel/acpi/boot.c --- a/arch/i386/kernel/acpi/boot.c Tue Sep 23 12:29:42 2003 +++ b/arch/i386/kernel/acpi/boot.c Tue Sep 23 12:29:42 2003 @@ -35,11 +35,13 @@ #if defined (CONFIG_X86_LOCAL_APIC) #include #include +#include #endif #define PREFIX "ACPI: " extern int acpi_disabled; +extern int acpi_irq; extern int acpi_ht; int acpi_lapic = 0; @@ -267,6 +269,27 @@ return 0; } +#ifdef CONFIG_HPET_TIMER +extern unsigned long hpet_address; + +static int __init acpi_parse_hpet(unsigned long phys, unsigned long size) +{ + struct acpi_table_hpet *hpet_tbl; + + hpet_tbl = __va(phys); + + if (hpet_tbl->addr.space_id != ACPI_SPACE_MEM) { + printk(KERN_WARNING PREFIX "HPET timers must be located in " + "memory.\n"); + return -1; + } + + hpet_address = hpet_tbl->addr.addrl; + printk(KERN_INFO PREFIX "HPET id: %#x base: %#lx\n", hpet_tbl->id, + hpet_address); + return 0; +} +#endif unsigned long __init acpi_find_rsdp (void) @@ -404,7 +427,7 @@ * If MPS is present, it will handle them, * otherwise the system will stay in PIC mode */ - if (acpi_disabled) { + if (acpi_disabled || !acpi_irq) { return 1; } @@ -448,13 +471,18 @@ acpi_ioapic = 1; +#endif /* CONFIG_X86_IO_APIC && CONFIG_ACPI_INTERPRETER */ + #ifdef CONFIG_X86_LOCAL_APIC if (acpi_lapic && acpi_ioapic) { smp_found_config = 1; clustered_apic_check(); } #endif -#endif /*CONFIG_X86_IO_APIC && CONFIG_ACPI_INTERPRETER*/ + +#ifdef CONFIG_HPET_TIMER + acpi_table_parse(ACPI_HPET, acpi_parse_hpet); +#endif return 0; } diff -Nru a/arch/i386/kernel/dmi_scan.c b/arch/i386/kernel/dmi_scan.c --- a/arch/i386/kernel/dmi_scan.c Tue Sep 23 12:29:42 2003 +++ b/arch/i386/kernel/dmi_scan.c Tue Sep 23 12:29:42 2003 @@ -162,20 +162,6 @@ static char *dmi_ident[DMI_STRING_MAX]; -/* print some information suitable for a blacklist entry. */ -static void dmi_dump_system(void) -{ - printk("DMI: BIOS: %.40s, %.40s, %.40s\n", - dmi_ident[DMI_BIOS_VENDOR], dmi_ident[DMI_BIOS_VERSION], - dmi_ident[DMI_BIOS_DATE]); - printk("DMI: System: %.40s, %.40s, %.40s\n", - dmi_ident[DMI_SYS_VENDOR], dmi_ident[DMI_PRODUCT_NAME], - dmi_ident[DMI_PRODUCT_VERSION]); - printk("DMI: Board: %.40s, %.40s, %.40s\n", - dmi_ident[DMI_BOARD_VENDOR], dmi_ident[DMI_BOARD_NAME], - dmi_ident[DMI_BOARD_VERSION]); -} - /* * Save a DMI string */ @@ -314,9 +300,9 @@ static int __init local_apic_kills_bios(struct dmi_blacklist *d) { #ifdef CONFIG_X86_LOCAL_APIC - extern int dont_enable_local_apic; - if (!dont_enable_local_apic) { - dont_enable_local_apic = 1; + extern int enable_local_apic; + if (enable_local_apic == 0) { + enable_local_apic = -1; printk(KERN_WARNING "%s with broken BIOS detected. " "Refusing to enable the local APIC.\n", d->ident); @@ -779,6 +765,12 @@ NO_MATCH, NO_MATCH } }, + { local_apic_kills_bios, "ASUS L3C", { + MATCH(DMI_BOARD_VENDOR, "ASUSTeK Computer INC."), + MATCH(DMI_BOARD_NAME, "P4_L3C"), + NO_MATCH, NO_MATCH + } }, + /* Problem Intel 440GX bioses */ { broken_pirq, "SABR1 Bios", { /* Bad $PIR */ @@ -1110,4 +1102,3 @@ } EXPORT_SYMBOL(is_unsafe_smbus); - diff -Nru a/arch/i386/kernel/mpparse.c b/arch/i386/kernel/mpparse.c --- a/arch/i386/kernel/mpparse.c Tue Sep 23 12:29:42 2003 +++ b/arch/i386/kernel/mpparse.c Tue Sep 23 12:29:42 2003 @@ -71,7 +71,7 @@ static unsigned int __initdata num_processors; /* Bitmask of physically existing CPUs */ -unsigned long phys_cpu_present_map; +physid_mask_t phys_cpu_present_map; u8 bios_cpu_apicid[NR_CPUS] = { [0 ... NR_CPUS-1] = BAD_APICID }; @@ -106,6 +106,7 @@ void __init MP_processor_info (struct mpc_config_processor *m) { int ver, apicid; + physid_mask_t tmp; if (!(m->mpc_cpuflag & CPU_ENABLED)) return; @@ -166,6 +167,11 @@ boot_cpu_logical_apicid = apicid; } + if (num_processors >= NR_CPUS) { + printk(KERN_WARNING "NR_CPUS limit of %i reached. Cannot " + "boot CPU(apicid 0x%d).\n", NR_CPUS, m->mpc_apicid); + return; + } num_processors++; if (MAX_APICS - m->mpc_apicid <= 0) { @@ -176,7 +182,8 @@ } ver = m->mpc_apicver; - phys_cpu_present_map |= apicid_to_cpu_present(apicid); + tmp = apicid_to_cpu_present(apicid); + physids_or(phys_cpu_present_map, phys_cpu_present_map, tmp); /* * Validate version @@ -848,7 +855,7 @@ return i; } - printk(KERN_ERR "ERROR: Unable to locate IOAPIC for IRQ %d/n", irq); + printk(KERN_ERR "ERROR: Unable to locate IOAPIC for IRQ %d\n", irq); return -1; } diff -Nru a/arch/i386/kernel/setup.c b/arch/i386/kernel/setup.c --- a/arch/i386/kernel/setup.c Tue Sep 23 12:29:42 2003 +++ b/arch/i386/kernel/setup.c Tue Sep 23 12:29:42 2003 @@ -43,6 +43,8 @@ #include #include #include +#include +#include #include "setup_arch_pre.h" #include "mach_resources.h" @@ -70,6 +72,7 @@ EXPORT_SYMBOL(acpi_disabled); #ifdef CONFIG_ACPI_BOOT + int acpi_irq __initdata = 1; /* enable IRQ */ int acpi_ht __initdata = 1; /* enable HT */ #endif @@ -100,6 +103,7 @@ unsigned char table[0]; }; struct edid_info edid_info; +struct ist_info ist_info; struct e820map e820; unsigned char aux_device_present; @@ -543,10 +547,17 @@ if (!acpi_force) acpi_disabled = 1; } + /* "pci=noacpi" disables ACPI interrupt routing */ + else if (!memcmp(from, "pci=noacpi", 10)) { + acpi_irq = 0; + } + +#ifdef CONFIG_X86_LOCAL_APIC /* disable IO-APIC */ else if (!memcmp(from, "noapic", 6)) disable_ioapic_setup(); -#endif +#endif /* CONFIG_X86_LOCAL_APIC */ +#endif /* CONFIG_ACPI_BOOT */ /* * highmem=size forces highmem to be exactly 'size' bytes. @@ -951,6 +962,7 @@ screen_info = SCREEN_INFO; edid_info = EDID_INFO; apm_info.bios = APM_BIOS_INFO; + ist_info = IST_INFO; saved_videomode = VIDEO_MODE; printk("Video mode to be used for restore is %lx\n", saved_videomode); if( SYS_DESC_TABLE.length != 0 ) { @@ -1010,9 +1022,6 @@ #ifdef CONFIG_X86_LOCAL_APIC if (smp_found_config) get_smp_config(); -#endif -#ifdef CONFIG_X86_SUMMIT - setup_summit(); #endif register_memory(max_low_pfn); diff -Nru a/drivers/acpi/Kconfig b/drivers/acpi/Kconfig --- a/drivers/acpi/Kconfig Tue Sep 23 12:29:42 2003 +++ b/drivers/acpi/Kconfig Tue Sep 23 12:29:42 2003 @@ -10,6 +10,7 @@ config ACPI bool "ACPI Support" depends on IA64 || X86 + default y ---help--- Advanced Configuration and Power Interface (ACPI) support for @@ -79,8 +80,9 @@ config ACPI_SLEEP bool "Sleep States (EXPERIMENTAL)" depends on X86 && ACPI - depends on EXPERIMENTAL depends on ACPI_INTERPRETER + depends on EXPERIMENTAL && PM + select SOFTWARE_SUSPEND default y ---help--- This option adds support for ACPI suspend states. diff -Nru a/init/do_mounts.c b/init/do_mounts.c --- a/init/do_mounts.c Tue Sep 23 12:29:42 2003 +++ b/init/do_mounts.c Tue Sep 23 12:29:42 2003 @@ -71,13 +71,19 @@ if (len <= 0 || len == 32 || buf[len - 1] != '\n') goto fail; buf[len - 1] = '\0'; - /* - * The format of dev is now %u:%u -- see print_dev_t() - */ - if (sscanf(buf, "%u:%u", &maj, &min) == 2) + if (sscanf(buf, "%u:%u", &maj, &min) == 2) { + /* + * Try the %u:%u format -- see print_dev_t() + */ res = MKDEV(maj, min); - else - goto fail; + } else { + /* + * Nope. Try old-style "0321" + */ + res = (dev_t)simple_strtoul(buf, &s, 16); + if (*s) + goto fail; + } /* if it's there and we are not looking for a partition - that's it */ if (!part) @@ -135,9 +141,15 @@ goto out; if (strncmp(name, "/dev/", 5) != 0) { - res = (dev_t) simple_strtoul(name, &p, 16); - if (*p) - goto fail; + unsigned maj, min; + + if (sscanf(name, "%u:%u", &maj, &min) == 2) { + res = MKDEV(maj, min); + } else { + res = (dev_t)simple_strtoul(name, &p, 16); + if (*p) + goto fail; + } goto done; } name += 5; @@ -370,10 +382,6 @@ } is_floppy = MAJOR(ROOT_DEV) == FLOPPY_MAJOR; - - /* This has to be before mounting root, because even readonly mount of reiserfs would replay - log corrupting stuff */ - software_resume(); if (initrd_load()) goto out;