From: Arjan van de Ven <arjanv@redhat.com>

This enables apic=bigsmp automatically on some big HP machines that need
it.  This makes them boot without kernel parameters on a generic arch
kernel.

Signed-off-by: Andrew Morton <akpm@osdl.org>
---

 25-akpm/arch/i386/kernel/io_apic.c      |    2 +-
 25-akpm/arch/i386/mach-generic/bigsmp.c |   28 +++++++++++++++++++++++++++-
 2 files changed, 28 insertions(+), 2 deletions(-)

diff -puN arch/i386/kernel/io_apic.c~automatically-enable-bigsmp-on-big-hp-machines arch/i386/kernel/io_apic.c
--- 25/arch/i386/kernel/io_apic.c~automatically-enable-bigsmp-on-big-hp-machines	Thu Aug  5 14:47:29 2004
+++ 25-akpm/arch/i386/kernel/io_apic.c	Thu Aug  5 14:47:29 2004
@@ -1741,7 +1741,7 @@ static void __init setup_ioapic_ids_from
 		reg_00.raw = io_apic_read(apic, 0);
 		spin_unlock_irqrestore(&ioapic_lock, flags);
 		if (reg_00.bits.ID != mp_ioapics[apic].mpc_apicid)
-			panic("could not set ID!\n");
+			printk("could not set ID!\n");
 		else
 			apic_printk(APIC_VERBOSE, " ok.\n");
 	}
diff -puN arch/i386/mach-generic/bigsmp.c~automatically-enable-bigsmp-on-big-hp-machines arch/i386/mach-generic/bigsmp.c
--- 25/arch/i386/mach-generic/bigsmp.c~automatically-enable-bigsmp-on-big-hp-machines	Thu Aug  5 14:47:29 2004
+++ 25-akpm/arch/i386/mach-generic/bigsmp.c	Thu Aug  5 14:47:29 2004
@@ -13,15 +13,41 @@
 #include <linux/kernel.h>
 #include <linux/smp.h>
 #include <linux/init.h>
+#include <linux/dmi.h>
 #include <asm/mach-bigsmp/mach_apic.h>
 #include <asm/mach-bigsmp/mach_apicdef.h>
 #include <asm/mach-bigsmp/mach_ipi.h>
 #include <asm/mach-default/mach_mpparse.h>
 
-int dmi_bigsmp; /* can be set by dmi scanners */
+static int dmi_bigsmp; /* can be set by dmi scanners */
+
+static __init int hp_ht_bigsmp(struct dmi_system_id *d)
+{
+#ifdef CONFIG_X86_GENERICARCH
+	printk(KERN_NOTICE "%s detected: force use of apic=bigsmp\n", d->ident);
+	dmi_bigsmp = 1;
+#endif
+	return 0;
+}
+
+
+static struct dmi_system_id __initdata bigsmp_dmi_table[] = {
+	{ hp_ht_bigsmp, "HP ProLiant DL760 G2", {
+		DMI_MATCH(DMI_BIOS_VENDOR, "HP"),
+		DMI_MATCH(DMI_BIOS_VERSION, "P44-"),
+	}},
+
+	{ hp_ht_bigsmp, "HP ProLiant DL740", {
+		DMI_MATCH(DMI_BIOS_VENDOR, "HP"),
+		DMI_MATCH(DMI_BIOS_VERSION, "P47-"),
+	 }},
+	 { }
+};
+
 
 static __init int probe_bigsmp(void)
 { 
+	dmi_check_system(bigsmp_dmi_table);
 	return dmi_bigsmp; 
 } 
 
_