summaryrefslogtreecommitdiff
path: root/x86_64
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2023-08-10 19:03:10 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2023-08-10 19:03:10 +0200
commitd2a853126d4b017d5029e2adbdcb844542fb7d7a (patch)
tree306c5cb2cea0476ee6b0beddb6899493e2b8f0c1 /x86_64
parentf895575c639e338474c7de6678ee8f3a0756c0d1 (diff)
x86_64: homogeneize with i386 about _call_single
Diffstat (limited to 'x86_64')
-rw-r--r--x86_64/interrupt.S12
-rw-r--r--x86_64/locore.S4
2 files changed, 10 insertions, 6 deletions
diff --git a/x86_64/interrupt.S b/x86_64/interrupt.S
index eabf934e..845e0d1a 100644
--- a/x86_64/interrupt.S
+++ b/x86_64/interrupt.S
@@ -42,12 +42,13 @@ ENTRY(interrupt)
#ifdef APIC
cmpl $255,%eax /* was this a spurious intr? */
je _no_eoi /* if so, just return */
-
+#endif
cmpl $CALL_SINGLE_FUNCTION_BASE,%eax /* was this a SMP call single function request? */
je _call_single
-#endif
+
subq $16,%rsp /* Two local variables */
movl %eax,S_IRQ /* save irq number */
+
call spl7 /* set ipl */
movl %eax,S_IPL /* save previous ipl */
@@ -115,15 +116,14 @@ ENTRY(interrupt)
_isa_eoi:
movl %ecx,%edi /* load irq number as 1st arg */
call EXT(ioapic_irq_eoi) /* ioapic irq specific EOI */
+#endif
addq $16,%rsp /* pop local variables */
+_no_eoi:
ret
+
_call_single:
cli /* no nested interrupts */
call EXT(lapic_eoi) /* lapic EOI before the handler to allow extra update */
call EXT(pmap_update_interrupt) /* TODO: Allow other functions */
ret
-#endif
- addq $16,%rsp /* pop local variables */
-_no_eoi:
- ret
END(interrupt)
diff --git a/x86_64/locore.S b/x86_64/locore.S
index 42049cbe..9bafaac5 100644
--- a/x86_64/locore.S
+++ b/x86_64/locore.S
@@ -768,6 +768,10 @@ INTERRUPT(20)
INTERRUPT(21)
INTERRUPT(22)
INTERRUPT(23)
+#endif
+/* Invalidate TLB IPI to call pmap_update_interrupt() on a specific cpu */
+INTERRUPT(CALL_SINGLE_FUNCTION_BASE)
+#ifdef APIC
/* Spurious interrupt, set irq number to vect number */
INTERRUPT(255)
#endif