diff options
author | Sebastian Andrzej Siewior <bigeasy@linutronix.de> | 2010-11-26 11:50:20 -0500 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2010-12-06 08:30:28 -0500 |
commit | a38c5380ef9f088be9f49b6e4c5d80af8b1b5cd4 (patch) | |
tree | fd57af94aa3dd6992b46059f6d0994da5ed30bc1 /arch/x86/kernel/apic | |
parent | 7fb2b870d6a3b92f6750ac2b72858fd098dc9e3f (diff) |
x86: io_apic: Split setup_ioapic_ids_from_mpc()
Sodaville needs to setup the IO_APIC ids as the boot loader leaves
them uninitialized. Split out the setter function so it can be called
unconditionally from the sodaville board code.
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: Yinghai Lu <yinghai@kernel.org>
LKML-Reference: <20101126165020.GA26361@www.tglx.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/kernel/apic')
-rw-r--r-- | arch/x86/kernel/apic/io_apic.c | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/arch/x86/kernel/apic/io_apic.c b/arch/x86/kernel/apic/io_apic.c index ce3c6fb4f357..4f026a632c95 100644 --- a/arch/x86/kernel/apic/io_apic.c +++ b/arch/x86/kernel/apic/io_apic.c | |||
@@ -1934,8 +1934,7 @@ void disable_IO_APIC(void) | |||
1934 | * | 1934 | * |
1935 | * by Matt Domsch <Matt_Domsch@dell.com> Tue Dec 21 12:25:05 CST 1999 | 1935 | * by Matt Domsch <Matt_Domsch@dell.com> Tue Dec 21 12:25:05 CST 1999 |
1936 | */ | 1936 | */ |
1937 | 1937 | void __init setup_ioapic_ids_from_mpc_nocheck(void) | |
1938 | void __init setup_ioapic_ids_from_mpc(void) | ||
1939 | { | 1938 | { |
1940 | union IO_APIC_reg_00 reg_00; | 1939 | union IO_APIC_reg_00 reg_00; |
1941 | physid_mask_t phys_id_present_map; | 1940 | physid_mask_t phys_id_present_map; |
@@ -1944,15 +1943,6 @@ void __init setup_ioapic_ids_from_mpc(void) | |||
1944 | unsigned char old_id; | 1943 | unsigned char old_id; |
1945 | unsigned long flags; | 1944 | unsigned long flags; |
1946 | 1945 | ||
1947 | if (acpi_ioapic) | ||
1948 | return; | ||
1949 | /* | ||
1950 | * Don't check I/O APIC IDs for xAPIC systems. They have | ||
1951 | * no meaning without the serial APIC bus. | ||
1952 | */ | ||
1953 | if (!(boot_cpu_data.x86_vendor == X86_VENDOR_INTEL) | ||
1954 | || APIC_XAPIC(apic_version[boot_cpu_physical_apicid])) | ||
1955 | return; | ||
1956 | /* | 1946 | /* |
1957 | * This is broken; anything with a real cpu count has to | 1947 | * This is broken; anything with a real cpu count has to |
1958 | * circumvent this idiocy regardless. | 1948 | * circumvent this idiocy regardless. |
@@ -2006,7 +1996,6 @@ void __init setup_ioapic_ids_from_mpc(void) | |||
2006 | physids_or(phys_id_present_map, phys_id_present_map, tmp); | 1996 | physids_or(phys_id_present_map, phys_id_present_map, tmp); |
2007 | } | 1997 | } |
2008 | 1998 | ||
2009 | |||
2010 | /* | 1999 | /* |
2011 | * We need to adjust the IRQ routing table | 2000 | * We need to adjust the IRQ routing table |
2012 | * if the ID changed. | 2001 | * if the ID changed. |
@@ -2042,6 +2031,21 @@ void __init setup_ioapic_ids_from_mpc(void) | |||
2042 | apic_printk(APIC_VERBOSE, " ok.\n"); | 2031 | apic_printk(APIC_VERBOSE, " ok.\n"); |
2043 | } | 2032 | } |
2044 | } | 2033 | } |
2034 | |||
2035 | void __init setup_ioapic_ids_from_mpc(void) | ||
2036 | { | ||
2037 | |||
2038 | if (acpi_ioapic) | ||
2039 | return; | ||
2040 | /* | ||
2041 | * Don't check I/O APIC IDs for xAPIC systems. They have | ||
2042 | * no meaning without the serial APIC bus. | ||
2043 | */ | ||
2044 | if (!(boot_cpu_data.x86_vendor == X86_VENDOR_INTEL) | ||
2045 | || APIC_XAPIC(apic_version[boot_cpu_physical_apicid])) | ||
2046 | return; | ||
2047 | setup_ioapic_ids_from_mpc_nocheck(); | ||
2048 | } | ||
2045 | #endif | 2049 | #endif |
2046 | 2050 | ||
2047 | int no_timer_check __initdata; | 2051 | int no_timer_check __initdata; |