summaryrefslogtreecommitdiff
path: root/sys/arch/i386
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2006-03-06 19:10:07 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2006-03-06 19:10:07 +0000
commit30a5db1b60cfa5bc65715d448757ece6a2067200 (patch)
tree7e36c70d33f9c71c470e8259ae66dc1266ac09d2 /sys/arch/i386
parent6ee30170b5e77bdc4eca74a92404b236b68fd9a7 (diff)
Synch bits of the i386 and amd64 ioapic code.
Make ioapic redirect register writes atomic on amd64 just like on i386. ok niklas@, grange@
Diffstat (limited to 'sys/arch/i386')
-rw-r--r--sys/arch/i386/i386/ioapic.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/sys/arch/i386/i386/ioapic.c b/sys/arch/i386/i386/ioapic.c
index 3bddb3b3881..9a9f0bdd0ad 100644
--- a/sys/arch/i386/i386/ioapic.c
+++ b/sys/arch/i386/i386/ioapic.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ioapic.c,v 1.6 2005/11/10 14:35:13 mickey Exp $ */
+/* $OpenBSD: ioapic.c,v 1.7 2006/03/06 19:10:06 kettenis Exp $ */
/* $NetBSD: ioapic.c,v 1.7 2003/07/14 22:32:40 lukem Exp $ */
/*-
@@ -232,7 +232,7 @@ ioapic_set_id(struct ioapic_softc *sc) {
if (apic_id != sc->sc_apicid)
printf(", can't remap to apid %d\n", sc->sc_apicid);
else
- printf(", remapped to apic %d\n", sc->sc_apicid);
+ printf(", remapped to apid %d\n", sc->sc_apicid);
}
/*
@@ -372,11 +372,7 @@ apic_set_redir(struct ioapic_softc *sc, int pin)
pp = &sc->sc_pins[pin];
map = pp->ip_map;
- if (map == NULL) {
- redlo = IOAPIC_REDLO_MASK;
- } else {
- redlo = map->redir;
- }
+ redlo = (map == NULL) ? IOAPIC_REDLO_MASK : map->redir;
delmode = (redlo & IOAPIC_REDLO_DEL_MASK) >> IOAPIC_REDLO_DEL_SHIFT;
/* XXX magic numbers */