diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2015-02-09 08:15:20 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2015-02-09 08:15:20 +0000 |
commit | bb3b197688f523b9c07622e0eb0bab810710b698 (patch) | |
tree | 772b9882e120ab377b195a8576ec87cfa7452db9 | |
parent | 4e47558cfc785e74dce19f82896a004b73750464 (diff) |
More sanity checking for Local APIC NMI entries.
ok deraadt@
-rw-r--r-- | sys/dev/acpi/acpimadt.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/acpi/acpimadt.c b/sys/dev/acpi/acpimadt.c index 1c8a9e49c3f..5b65ec575f8 100644 --- a/sys/dev/acpi/acpimadt.c +++ b/sys/dev/acpi/acpimadt.c @@ -1,4 +1,4 @@ -/* $OpenBSD: acpimadt.c,v 1.30 2014/12/09 06:58:29 doug Exp $ */ +/* $OpenBSD: acpimadt.c,v 1.31 2015/02/09 08:15:19 kettenis Exp $ */ /* * Copyright (c) 2006 Mark Kettenis <kettenis@openbsd.org> * @@ -359,7 +359,8 @@ acpimadt_attach(struct device *parent, struct device *self, void *aux) map->ioapic_pin = pin; map->flags = entry->madt_lapic_nmi.flags; - if (!acpimadt_cfg_intr(entry->madt_lapic_nmi.flags, &map->redir)) { + if ((pin != 0 && pin != 1) || + !acpimadt_cfg_intr(entry->madt_lapic_nmi.flags, &map->redir)) { printf("%s: bogus nmi for apid %d\n", self->dv_xname, map->cpu_id); mp_nintrs--; |