Commit a355f040 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] allow SMP kernel build without io_apic.c

Patch from Andrey Panin <pazke@orbita1.ru>

I'm here again, starting another hopeless attempt to submmit
visws subarch support for 2.5. This series of patches was tested
by me and brave people from linux-visws-devel mailing list and
our beloved workstations seem to work well under 2.5.xx.

This patch moves enable_NMI_through_LVT0() function from io_apic.c
to apic.c to allow SMP kernel build without io_apic.c included.
parent 4520ee79
...@@ -54,6 +54,18 @@ int prof_multiplier[NR_CPUS] = { 1, }; ...@@ -54,6 +54,18 @@ int prof_multiplier[NR_CPUS] = { 1, };
int prof_old_multiplier[NR_CPUS] = { 1, }; int prof_old_multiplier[NR_CPUS] = { 1, };
DEFINE_PER_CPU(int, prof_counter) = 1; DEFINE_PER_CPU(int, prof_counter) = 1;
void enable_NMI_through_LVT0 (void * dummy)
{
unsigned int v, ver;
ver = apic_read(APIC_LVR);
ver = GET_APIC_VERSION(ver);
v = APIC_DM_NMI; /* unmask and set to NMI */
if (!APIC_INTEGRATED(ver)) /* 82489DX */
v |= APIC_LVT_LEVEL_TRIGGER;
apic_write_around(APIC_LVT0, v);
}
int get_maxlvt(void) int get_maxlvt(void)
{ {
unsigned int v, ver, maxlvt; unsigned int v, ver, maxlvt;
......
...@@ -1830,18 +1830,6 @@ static struct hw_interrupt_type lapic_irq_type = { ...@@ -1830,18 +1830,6 @@ static struct hw_interrupt_type lapic_irq_type = {
end_lapic_irq end_lapic_irq
}; };
void enable_NMI_through_LVT0 (void * dummy)
{
unsigned int v, ver;
ver = apic_read(APIC_LVR);
ver = GET_APIC_VERSION(ver);
v = APIC_DM_NMI; /* unmask and set to NMI */
if (!APIC_INTEGRATED(ver)) /* 82489DX */
v |= APIC_LVT_LEVEL_TRIGGER;
apic_write_around(APIC_LVT0, v);
}
static void setup_nmi (void) static void setup_nmi (void)
{ {
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment