mirror of
https://github.com/phil-opp/blog_os.git
synced 2025-12-16 22:37:49 +00:00
Pass address of multiboot info structure to rust_main
This commit is contained in:
@@ -5,6 +5,7 @@ section .text
|
|||||||
bits 32
|
bits 32
|
||||||
start:
|
start:
|
||||||
mov esp, stack_top
|
mov esp, stack_top
|
||||||
|
mov edi, ebx ; move Multiboot info pointer to edi
|
||||||
|
|
||||||
call check_multiboot
|
call check_multiboot
|
||||||
call check_cpuid
|
call check_cpuid
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ extern crate spin;
|
|||||||
mod vga_buffer;
|
mod vga_buffer;
|
||||||
|
|
||||||
#[no_mangle]
|
#[no_mangle]
|
||||||
pub extern fn rust_main() {
|
pub extern fn rust_main(multiboot_information_address: usize) {
|
||||||
vga_buffer::clear_screen();
|
vga_buffer::clear_screen();
|
||||||
println!("Hello World{}", "!");
|
println!("Hello World{}", "!");
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user