aboutsummaryrefslogtreecommitdiff
path: root/i386
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2023-08-13 00:57:14 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2023-08-13 00:57:14 +0200
commitd6ca407ed23159d161309740c5bf342d13edcc43 (patch)
tree27ac659129ff79a47eec7fdae1f63c1c5162f023 /i386
parent6dcf01215edfd49a97c86e7c0d49e0d75785cf84 (diff)
downloadgnumach-d6ca407ed23159d161309740c5bf342d13edcc43.tar.gz
gnumach-d6ca407ed23159d161309740c5bf342d13edcc43.tar.bz2
gnumach-d6ca407ed23159d161309740c5bf342d13edcc43.zip
IPI: Rework irq names and fix x86_64 build
Diffstat (limited to 'i386')
-rw-r--r--i386/i386/i386asm.sym4
-rw-r--r--i386/i386/locore.S5
-rw-r--r--i386/i386/smp.c4
-rw-r--r--i386/i386at/idt.h4
-rw-r--r--i386/i386at/int_init.c4
-rw-r--r--i386/i386at/interrupt.S6
6 files changed, 13 insertions, 14 deletions
diff --git a/i386/i386/i386asm.sym b/i386/i386/i386asm.sym
index 18b208e9..436e296a 100644
--- a/i386/i386/i386asm.sym
+++ b/i386/i386/i386asm.sym
@@ -48,8 +48,8 @@
#include <i386/apic.h>
#include <i386/xen.h>
-expr CALL_LOCAL_AST_BASE
-expr CALL_SINGLE_FUNCTION_BASE
+expr CALL_AST_CHECK
+expr CALL_PMAP_UPDATE
offset ApicLocalUnit lu apic_id APIC_ID
diff --git a/i386/i386/locore.S b/i386/i386/locore.S
index c8262e22..aee9a8ee 100644
--- a/i386/i386/locore.S
+++ b/i386/i386/locore.S
@@ -652,9 +652,8 @@ INTERRUPT(21)
INTERRUPT(22)
INTERRUPT(23)
#endif
-INTERRUPT(CALL_LOCAL_AST_BASE)
-/* Invalidate TLB IPI to call pmap_update_interrupt() on a specific cpu */
-INTERRUPT(CALL_SINGLE_FUNCTION_BASE)
+INTERRUPT(CALL_AST_CHECK)
+INTERRUPT(CALL_PMAP_UPDATE)
#ifdef APIC
/* Spurious interrupt, set irq number to vect number */
INTERRUPT(255)
diff --git a/i386/i386/smp.c b/i386/i386/smp.c
index f3810370..fb43ecb6 100644
--- a/i386/i386/smp.c
+++ b/i386/i386/smp.c
@@ -68,12 +68,12 @@ static void smp_send_ipi(unsigned apic_id, unsigned vector)
void smp_remote_ast(unsigned apic_id)
{
- smp_send_ipi(apic_id, CALL_LOCAL_AST_BASE);
+ smp_send_ipi(apic_id, CALL_AST_CHECK);
}
void smp_pmap_update(unsigned apic_id)
{
- smp_send_ipi(apic_id, CALL_SINGLE_FUNCTION_BASE);
+ smp_send_ipi(apic_id, CALL_PMAP_UPDATE);
}
/* See Intel IA32/64 Software Developer's Manual 3A Section 8.4.4.1 */
diff --git a/i386/i386at/idt.h b/i386/i386at/idt.h
index 1c30eb7d..19e0abe8 100644
--- a/i386/i386at/idt.h
+++ b/i386/i386at/idt.h
@@ -38,10 +38,10 @@
#define IOAPIC_SPURIOUS_BASE 0xff
/* Remote -> local AST requests */
-#define CALL_LOCAL_AST_BASE 0xfa
+#define CALL_AST_CHECK 0xfa
/* Currently for TLB shootdowns */
-#define CALL_SINGLE_FUNCTION_BASE 0xfb
+#define CALL_PMAP_UPDATE 0xfb
#include <i386/idt-gen.h>
diff --git a/i386/i386at/int_init.c b/i386/i386at/int_init.c
index e3c4b8c8..47ba8150 100644
--- a/i386/i386at/int_init.c
+++ b/i386/i386at/int_init.c
@@ -45,11 +45,11 @@ int_fill(struct real_gate *myidt)
int_entry_table[i], KERNEL_CS,
ACC_PL_K|ACC_INTR_GATE, 0);
}
- fill_idt_gate(myidt, CALL_LOCAL_AST_BASE,
+ fill_idt_gate(myidt, CALL_AST_CHECK,
int_entry_table[i], KERNEL_CS,
ACC_PL_K|ACC_INTR_GATE, 0);
i++;
- fill_idt_gate(myidt, CALL_SINGLE_FUNCTION_BASE,
+ fill_idt_gate(myidt, CALL_PMAP_UPDATE,
int_entry_table[i], KERNEL_CS,
ACC_PL_K|ACC_INTR_GATE, 0);
i++;
diff --git a/i386/i386at/interrupt.S b/i386/i386at/interrupt.S
index 01198bf5..18680090 100644
--- a/i386/i386at/interrupt.S
+++ b/i386/i386at/interrupt.S
@@ -45,10 +45,10 @@ ENTRY(interrupt)
ret /* if so, just return */
1:
#endif
- cmpl $CALL_SINGLE_FUNCTION_BASE,%eax /* was this a SMP call single function request? */
+ cmpl $CALL_PMAP_UPDATE,%eax /* was this a SMP pmap_update request? */
je _call_single
- cmpl $CALL_LOCAL_AST_BASE,%eax /* was this a SMP remote -> local ast request? */
+ cmpl $CALL_AST_CHECK,%eax /* was this a SMP remote -> local ast request? */
je _call_local_ast
subl $24,%esp /* Two local variables + 4 parameters */
@@ -130,7 +130,7 @@ _no_eoi:
_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 */
+ call EXT(pmap_update_interrupt)
ret
_call_local_ast: