From 8cdc0de0931b19623a5df079937f54ecefd6de58 Mon Sep 17 00:00:00 2001 From: Tom Zimmerman Date: Fri, 3 Oct 2003 15:46:08 +0000 Subject: [PATCH] Made changes that allow for one cpu to be plugged into a SMP board. --- src/mainboard/tyan/s2466/mainboard.c | 17 ++++++++--------- src/mainboard/tyan/s2466/mptable.c | 6 +++++- src/mainboard/tyan/s2469/mainboard.c | 17 ++++++++--------- src/mainboard/tyan/s2469/mptable.c | 4 +++- 4 files changed, 24 insertions(+), 20 deletions(-) diff --git a/src/mainboard/tyan/s2466/mainboard.c b/src/mainboard/tyan/s2466/mainboard.c index 717d736e89..243f17dfc3 100644 --- a/src/mainboard/tyan/s2466/mainboard.c +++ b/src/mainboard/tyan/s2466/mainboard.c @@ -90,16 +90,23 @@ static void print_whami(void) static void check_cpus(void) { struct pci_dev *dev; - u32 biu1; + u32 biu0,biu1; + /* Find out which processor I'm running on, and if it was the boot * procesor so I can verify everything was setup correctly */ dev = pci_find_device(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_FE_GATE_700C,0); if (dev != NULL) { + pci_read_config_dword(dev, 0x60, &biu0); + if( !(biu0 & 0x80000000)) { + initial_apicid[0] = -1; + } pci_read_config_dword(dev, 0x68, &biu1); if( !(biu1 & 0x80000000)) { initial_apicid[1] = -1; } + printk_debug("biu0 = 0x%08lx, apicid[0] = %d\n", biu0, + initial_apicid[0]); printk_debug("biu1 = 0x%08lx, apicid[1] = %d\n", biu1, initial_apicid[1]); } @@ -234,14 +241,6 @@ static void hide_devices(void) void mainboard_cpu_fixup(int cpu) { - if(cpu == 1) { - check_cpus(); - if(initial_apicid[1] == -1) { - printk_err("Only one CPU installed. Linux Bios requires 2\n"); - while(1); /* print error and spin */ - return; /* no apic because no cpu */ - } - } /* This is an error, something is locked up */ full_reset(); } diff --git a/src/mainboard/tyan/s2466/mptable.c b/src/mainboard/tyan/s2466/mptable.c index 8d628a276f..1c068962dc 100644 --- a/src/mainboard/tyan/s2466/mptable.c +++ b/src/mainboard/tyan/s2466/mptable.c @@ -42,12 +42,16 @@ void *smp_write_config_table(void *v, unsigned long * processor_map) smp_write_bus(mc, 1, "PCI "); smp_write_bus(mc, 2, "PCI "); smp_write_bus(mc, 3, "ISA "); - +#if 0 for(i=apic=0;i