summaryrefslogtreecommitdiffstats
path: root/sys/i386
diff options
context:
space:
mode:
authorjeff <jeff@FreeBSD.org>2004-02-02 09:50:43 +0000
committerjeff <jeff@FreeBSD.org>2004-02-02 09:50:43 +0000
commit1acc8f3c8a72f84e32bec459571a9985b50c138c (patch)
tree67aa4a8927351c6a610657770c2e77d32acd28c5 /sys/i386
parent53962ffd37889dec7afa8309501675c30c9907b4 (diff)
downloadFreeBSD-src-1acc8f3c8a72f84e32bec459571a9985b50c138c.zip
FreeBSD-src-1acc8f3c8a72f84e32bec459571a9985b50c138c.tar.gz
- Make sure the apic is idle before sending an IPI. This is required on
non-X-APIC machines. Previously this was only done in the DETECT_DEADLOCK case when really it is needed in all cases. Reminded by: jhb
Diffstat (limited to 'sys/i386')
-rw-r--r--sys/i386/i386/local_apic.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/i386/i386/local_apic.c b/sys/i386/i386/local_apic.c
index bc9dc01..5370368 100644
--- a/sys/i386/i386/local_apic.c
+++ b/sys/i386/i386/local_apic.c
@@ -691,8 +691,8 @@ lapic_ipi_raw(register_t icrlo, u_int dest)
intr_restore(eflags);
}
-#ifdef DETECT_DEADLOCK
#define BEFORE_SPIN 1000000
+#ifdef DETECT_DEADLOCK
#define AFTER_SPIN 1000
#endif
@@ -723,11 +723,9 @@ lapic_ipi_vectored(u_int vector, int dest)
destfield = dest;
}
-#ifdef DETECT_DEADLOCK
- /* Check for an earlier stuck IPI. */
+ /* Wait for an earlier IPI to finish. */
if (!lapic_ipi_wait(BEFORE_SPIN))
panic("APIC: Previous IPI is stuck");
-#endif
lapic_ipi_raw(icrlo, destfield);
OpenPOWER on IntegriCloud