Skip to content

Latest commit

 

History

History
30 lines (20 loc) · 1.01 KB

apic.md

File metadata and controls

30 lines (20 loc) · 1.01 KB

How to use the APIC

src/main.rs

In the example provided we will be using a dynamic memory mapping. This is for exemplification only and can be changed with your own implementation of the memory mapper.

src/apic.rs

Here we create an AcpiHandlerImpl that implements the AcpiHandler trait from the apic crate. We have also added an enum with all the APIC registers from the OS Dev Wiki The main functions of the file are:

  • Init the Local APIC
  • Init the IO APIC
  • Map the APIC

src/frame_allocator.rs

This implements a basic frame allocator based on the blog post

src/gdt.rs

Implements a basic Global Descriptor Table based on the blog post as well as ensures that all segment registers are written, including ss and ds.

src/idt.rs

Implements a basic Interrupt Descriptor Table based on the blog post