diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2023-08-13 01:00:37 +0200 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2023-08-13 01:00:37 +0200 |
commit | 940639858d782cf0349ce08c865cac7dfeadf4ff (patch) | |
tree | 23bca642eb01a37c4acd5c438a3ac6962af0707a /i386 | |
parent | d6ca407ed23159d161309740c5bf342d13edcc43 (diff) | |
download | gnumach-940639858d782cf0349ce08c865cac7dfeadf4ff.tar.gz gnumach-940639858d782cf0349ce08c865cac7dfeadf4ff.tar.bz2 gnumach-940639858d782cf0349ce08c865cac7dfeadf4ff.zip |
IPI: Do not include support when NCPUS=1
Diffstat (limited to 'i386')
-rw-r--r-- | i386/i386/locore.S | 2 | ||||
-rw-r--r-- | i386/i386at/int_init.c | 2 | ||||
-rw-r--r-- | i386/i386at/interrupt.S | 4 |
3 files changed, 8 insertions, 0 deletions
diff --git a/i386/i386/locore.S b/i386/i386/locore.S index aee9a8ee..55aa9d60 100644 --- a/i386/i386/locore.S +++ b/i386/i386/locore.S @@ -652,8 +652,10 @@ INTERRUPT(21) INTERRUPT(22) INTERRUPT(23) #endif +#if NCPUS > 1 INTERRUPT(CALL_AST_CHECK) INTERRUPT(CALL_PMAP_UPDATE) +#endif #ifdef APIC /* Spurious interrupt, set irq number to vect number */ INTERRUPT(255) diff --git a/i386/i386at/int_init.c b/i386/i386at/int_init.c index 47ba8150..d55d7a48 100644 --- a/i386/i386at/int_init.c +++ b/i386/i386at/int_init.c @@ -45,6 +45,7 @@ int_fill(struct real_gate *myidt) int_entry_table[i], KERNEL_CS, ACC_PL_K|ACC_INTR_GATE, 0); } +#if NCPUS > 1 fill_idt_gate(myidt, CALL_AST_CHECK, int_entry_table[i], KERNEL_CS, ACC_PL_K|ACC_INTR_GATE, 0); @@ -53,6 +54,7 @@ int_fill(struct real_gate *myidt) int_entry_table[i], KERNEL_CS, ACC_PL_K|ACC_INTR_GATE, 0); i++; +#endif #ifdef APIC fill_idt_gate(myidt, IOAPIC_SPURIOUS_BASE, int_entry_table[i], KERNEL_CS, diff --git a/i386/i386at/interrupt.S b/i386/i386at/interrupt.S index 18680090..8ae6b97c 100644 --- a/i386/i386at/interrupt.S +++ b/i386/i386at/interrupt.S @@ -45,11 +45,13 @@ ENTRY(interrupt) ret /* if so, just return */ 1: #endif +#if NCPUS > 1 cmpl $CALL_PMAP_UPDATE,%eax /* was this a SMP pmap_update request? */ je _call_single cmpl $CALL_AST_CHECK,%eax /* was this a SMP remote -> local ast request? */ je _call_local_ast +#endif subl $24,%esp /* Two local variables + 4 parameters */ movl %eax,S_IRQ /* save irq number */ @@ -127,6 +129,7 @@ _no_eoi: addl $24,%esp /* pop local variables */ ret +#if NCPUS > 1 _call_single: cli /* no nested interrupts */ call EXT(lapic_eoi) /* lapic EOI before the handler to allow extra update */ @@ -137,4 +140,5 @@ _call_local_ast: call EXT(ast_check) /* AST check on this cpu */ call EXT(lapic_eoi) /* lapic EOI */ ret +#endif END(interrupt) |