Skip to content

Commit

Permalink
x86: apic - unify end_local_APIC_setup
Browse files Browse the repository at this point in the history
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Cyrill Gorcunov authored and Ingo Molnar committed Aug 19, 2008
1 parent 1b313f4 commit fa6b95f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
6 changes: 4 additions & 2 deletions arch/x86/kernel/apic_32.c
Original file line number Diff line number Diff line change
Expand Up @@ -1155,13 +1155,15 @@ void __cpuinit setup_local_APIC(void)

void __cpuinit end_local_APIC_setup(void)
{
unsigned long value;

lapic_setup_esr();

#ifdef CONFIG_X86_32
unsigned int value;
/* Disable the local apic timer */
value = apic_read(APIC_LVTT);
value |= (APIC_LVT_MASKED | LOCAL_TIMER_VECTOR);
apic_write(APIC_LVTT, value);
#endif

setup_apic_nmi_watchdog(NULL);
apic_pm_activate();
Expand Down
9 changes: 9 additions & 0 deletions arch/x86/kernel/apic_64.c
Original file line number Diff line number Diff line change
Expand Up @@ -1014,6 +1014,15 @@ void __cpuinit setup_local_APIC(void)
void __cpuinit end_local_APIC_setup(void)
{
lapic_setup_esr();

#ifdef CONFIG_X86_32
unsigned int value;
/* Disable the local apic timer */
value = apic_read(APIC_LVTT);
value |= (APIC_LVT_MASKED | LOCAL_TIMER_VECTOR);
apic_write(APIC_LVTT, value);
#endif

setup_apic_nmi_watchdog(NULL);
apic_pm_activate();
}
Expand Down

0 comments on commit fa6b95f

Please sign in to comment.