mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-30 06:10:56 +00:00
x86: apic_64.c - add sanity check for spurious vector definition
Do not check for SPUTIOUS_APIC_VECTOR definition twice. Check it once - is what we need. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com> Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:
parent
920fa7a507
commit
80e5609cab
1 changed files with 7 additions and 2 deletions
|
@ -46,6 +46,13 @@
|
||||||
#include <mach_ipi.h>
|
#include <mach_ipi.h>
|
||||||
#include <mach_apic.h>
|
#include <mach_apic.h>
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Sanity check
|
||||||
|
*/
|
||||||
|
#if ((SPURIOUS_APIC_VECTOR & 0x0F) != 0x0F)
|
||||||
|
# error SPURIOUS_APIC_VECTOR definition error
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Disable local APIC timer from the kernel commandline or via dmi quirk */
|
/* Disable local APIC timer from the kernel commandline or via dmi quirk */
|
||||||
static int disable_apic_timer __cpuinitdata;
|
static int disable_apic_timer __cpuinitdata;
|
||||||
static int apic_calibrate_pmtmr __initdata;
|
static int apic_calibrate_pmtmr __initdata;
|
||||||
|
@ -939,8 +946,6 @@ void __cpuinit setup_local_APIC(void)
|
||||||
preempt_disable();
|
preempt_disable();
|
||||||
value = apic_read(APIC_LVR);
|
value = apic_read(APIC_LVR);
|
||||||
|
|
||||||
BUILD_BUG_ON((SPURIOUS_APIC_VECTOR & 0x0f) != 0x0f);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Double-check whether this APIC is really registered.
|
* Double-check whether this APIC is really registered.
|
||||||
* This is meaningless in clustered apic mode, so we skip it.
|
* This is meaningless in clustered apic mode, so we skip it.
|
||||||
|
|
Loading…
Reference in a new issue