Remove stub symbols for APIC-related functions when 'device apic' is not

included in a kernel config.  These stubs had existed previously so that
acpi.ko could always include the MADT parsing code and still link with a
kernel that did not include 'device apic'.
This commit is contained in:
John Baldwin 2010-11-08 20:32:35 +00:00
parent bfda18fcb6
commit 6c3c2b8b87

View File

@ -40,7 +40,6 @@
#include <sys/cdefs.h>
__FBSDID("$FreeBSD$");
#include "opt_apic.h"
#include "opt_atalk.h"
#include "opt_compat.h"
#include "opt_cpu.h"
@ -3614,102 +3613,6 @@ user_dbreg_trap(void)
return 0;
}
#ifndef DEV_APIC
#include <machine/apicvar.h>
/*
* Provide stub functions so that the MADT APIC enumerator in the acpi
* kernel module will link against a kernel without 'device apic'.
*
* XXX - This is a gross hack.
*/
void
apic_register_enumerator(struct apic_enumerator *enumerator)
{
}
void *
ioapic_create(vm_paddr_t addr, int32_t apic_id, int intbase)
{
return (NULL);
}
int
ioapic_disable_pin(void *cookie, u_int pin)
{
return (ENXIO);
}
int
ioapic_get_vector(void *cookie, u_int pin)
{
return (-1);
}
void
ioapic_register(void *cookie)
{
}
int
ioapic_remap_vector(void *cookie, u_int pin, int vector)
{
return (ENXIO);
}
int
ioapic_set_extint(void *cookie, u_int pin)
{
return (ENXIO);
}
int
ioapic_set_nmi(void *cookie, u_int pin)
{
return (ENXIO);
}
int
ioapic_set_polarity(void *cookie, u_int pin, enum intr_polarity pol)
{
return (ENXIO);
}
int
ioapic_set_triggermode(void *cookie, u_int pin, enum intr_trigger trigger)
{
return (ENXIO);
}
void
lapic_create(u_int apic_id, int boot_cpu)
{
}
void
lapic_init(vm_paddr_t addr)
{
}
int
lapic_set_lvt_mode(u_int apic_id, u_int lvt, u_int32_t mode)
{
return (ENXIO);
}
int
lapic_set_lvt_polarity(u_int apic_id, u_int lvt, enum intr_polarity pol)
{
return (ENXIO);
}
int
lapic_set_lvt_triggermode(u_int apic_id, u_int lvt, enum intr_trigger trigger)
{
return (ENXIO);
}
#endif
#ifdef KDB
/*