refactored for architectures and added riscv support

This commit is contained in:
Bryan McShea
2024-01-24 00:41:51 -05:00
parent e5a6b6073f
commit 461269ed32
30 changed files with 683 additions and 425 deletions
+23
View File
@@ -0,0 +1,23 @@
use crate::main;
pub mod framebuffer;
pub mod gdt;
pub mod interrupts;
pub mod qemu;
bootloader_api::entry_point!(_start);
fn _start(boot_info: &'static mut bootloader_api::BootInfo) -> ! {
gdt::init();
interrupts::init();
if let Some(framebuffer) = boot_info.framebuffer.as_mut() {
framebuffer::draw_test(framebuffer);
}
main();
}
pub fn hlt_loop() -> ! {
loop {
x86_64::instructions::hlt();
}
}