summaryrefslogtreecommitdiff
path: root/sys/arch/amd64
AgeCommit message (Collapse)Author
2025-11-20kern/amd64+sys: Add cacheline alignment macroIan Moffett
Cacheline alignment is a mitigation against false sharing imposed by locality of a shared resource. Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: mp: Destroy bootspace after APs are upIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: mp: Tear down lower half per APIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: sched: Implement context switchingIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: proc: Put stack on higher half if kernelIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: lapic: Add EOI functionIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: mp: Load per-core GDT/IDTIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: Move GDT selector defines to gdt.hIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: mp: Bring up per-processor idle threadsIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: mp: Add CPU idle function to split logicIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern: mu: Add percpu queue for schedulingIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: cpu: Add cpu_count() functionIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64+os: proc: Add process initializationIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: mp: Don't return on present entryIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: mmu: Set uninitialized field to paddrIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: cpu: Add user segment descriptorsIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: cpu: Expand GDT structure for clarityIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64+mu: panic: Dump registers on panicIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-19kern/amd64: mp: Keep track of brought up coresIan Moffett
This commit implements storing of processor descriptors per application processors as well helpers to request a CPU descriptor by index and better serialization Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-18kern/amd64: lapic: Add Local APIC timer interfaceIan Moffett
This commit adds an interface to perform a oneshot operation with the Local APIC timer as well as providing a stub interrupt service routine for it. Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-18kern/amd64: idt: Make idt.h includable in ASMIan Moffett
This also moves the interrupt gate defines to the idt.h header so that they can be used within C code Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-18kern/amd64: mp: Add application processor counterIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-18project: Correct malformed copyright headersIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-18kern/amd64: mmu: Add function to map pagesIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-18kern/amd64: mmu: Don't truncate bits when reading vasIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-18kern/amd64: Do low-level processor configurationIan Moffett
This commit seperates low-level processor configuration into the cpu_loinit() function. This is to be called for the BSP and per AP. Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-18kern/amd64: mmu: Add mu_pmap_forkvas() helperIan Moffett
The mu_pmap_forkvas() function copies the current virtual address with the user porition zeroed. Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: mp: Sync MTRRs between APs and BSPIan Moffett
Section 11.11.8 of the Intel SDM states that all MTRRs in a multiprocessing system must be synced to prevent undefined behavior. Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: boot: Disable interrupts on AP bootIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: mp: Update stale comment about mappingsIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: mp: Make AP bring up more stableIan Moffett
- Move BUDA to 0x9000 - Move the BUA to 0x8000 - Serialize bring up with is_booted flag - Map whole 2 megs of lower address space Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: cpu: Don't initialize bootspace twiceIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: Bring application cores to long modeIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: mp: Ensure core is online capableIan Moffett
Section 5.2.12.2, table 5.23 of the ACPI spec states that the flags needs to have the enabled bit [0] or online capable bit [1] set for startup, otherwise it should just be ignored. Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: mp: Add multiprocessing groundworkIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: lapic: Add lapic_read_id() functionIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: lapic: Fix SVR low byte to logical 1sIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: lapic: Fix typo in commentIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: lapic: Make ICR values 64-bitsIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: lapic: Add support for sending IPIsIan Moffett
This commit introduces an interface for sending inter-processor interrupts using the current Local APIC unit Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: lapic: Configure and calibrate timerIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: isa: Add minimal i8254 driverIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-17kern/amd64: cpu: Add initial Local APIC driverIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-16kern/amd64+mu: Add processor descriptor + percpu stateIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-16kern/amd64: cpu: Disable master/slave i8259 chipsIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-16kern/amd64+mu: Add initial virtual memory sourcesIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-16kern: panic: Deprecate mu_panic_preamble()Ian Moffett
This commit deprecates mu_panic_preamble() in favor of the mu_spinlock_acq() function Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-16kern/amd64: Add spinlock impl for AMD64 portIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-15build: Add header depsIan Moffett
Signed-off-by: Ian Moffett <ian@osmora.org>
2025-11-15kern/amd64: Add panic function + MU helpersIan Moffett
This commit introduces a panic function as well as a panic machine unifier layer for MD specifics that help bring the system to a halt. Signed-off-by: Ian Moffett <ian@osmora.org>