summaryrefslogtreecommitdiffstats
path: root/sys/i386/acpica
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2003-09-10 05:29:30 +0000
committerjhb <jhb@FreeBSD.org>2003-09-10 05:29:30 +0000
commitf1adf3f35541fa8b3018f2d830c061eeef3e600b (patch)
tree3ff2b190d2fa9c6bc4e7e69cf83e740b98fc904a /sys/i386/acpica
parent0dc22d58efc879700a8c6cd8a607f8e902af36bf (diff)
downloadFreeBSD-src-f1adf3f35541fa8b3018f2d830c061eeef3e600b.zip
FreeBSD-src-f1adf3f35541fa8b3018f2d830c061eeef3e600b.tar.gz
Finish an earlier commit:
Add a acpi_SetDefaultIntrModel() method to allow drivers to set the interrupt model prior to the acpi0 device being probed and attached.
Diffstat (limited to 'sys/i386/acpica')
-rw-r--r--sys/i386/acpica/acpi_machdep.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/sys/i386/acpica/acpi_machdep.c b/sys/i386/acpica/acpi_machdep.c
index 3cff7a9..5021866 100644
--- a/sys/i386/acpica/acpi_machdep.c
+++ b/sys/i386/acpica/acpi_machdep.c
@@ -78,6 +78,8 @@ static struct cdevsw apm_cdevsw = {
.d_maj = CDEV_MAJOR,
};
+static int intr_model = ACPI_INTR_PIC;
+
static int
acpi_capm_convert_battstate(struct acpi_battinfo *battp)
{
@@ -314,8 +316,14 @@ acpi_machdep_init(device_t dev)
acpi_install_wakeup_handler(sc);
-#ifdef SMP
- acpi_SetIntrModel(ACPI_INTR_APIC);
-#endif
+ if (intr_model != ACPI_INTR_PIC)
+ acpi_SetIntrModel(intr_model);
return (0);
}
+
+void
+acpi_SetDefaultIntrModel(int model)
+{
+
+ intr_model = model;
+}
OpenPOWER on IntegriCloud