Apply bootloader config correctly
Signed-off-by: Noah Knegt <git@noahknegt.com>
This commit is contained in:
@@ -1,18 +1,9 @@
|
||||
#![no_std]
|
||||
|
||||
use bootloader_api::{
|
||||
BootInfo,
|
||||
config::{BootloaderConfig, Mapping},
|
||||
};
|
||||
use bootloader_api::BootInfo;
|
||||
|
||||
mod logging;
|
||||
|
||||
pub static BOOTLOADER_CONFIG: BootloaderConfig = {
|
||||
let mut config = BootloaderConfig::new_default();
|
||||
config.mappings.physical_memory = Some(Mapping::Dynamic);
|
||||
config
|
||||
};
|
||||
|
||||
pub fn main(boot_info: &'static mut BootInfo) -> ! {
|
||||
let info = boot_info.framebuffer.as_ref().unwrap().info();
|
||||
let buffer = boot_info.framebuffer.as_mut().unwrap().buffer_mut();
|
||||
|
@@ -1,6 +1,15 @@
|
||||
#![no_std]
|
||||
#![no_main]
|
||||
|
||||
use bootloader_api::entry_point;
|
||||
use bootloader_api::{
|
||||
config::{BootloaderConfig, Mapping},
|
||||
entry_point,
|
||||
};
|
||||
|
||||
entry_point!(kernel::main);
|
||||
static BOOTLOADER_CONFIG: BootloaderConfig = {
|
||||
let mut config = BootloaderConfig::new_default();
|
||||
config.mappings.physical_memory = Some(Mapping::Dynamic);
|
||||
config
|
||||
};
|
||||
|
||||
entry_point!(kernel::main, config = &BOOTLOADER_CONFIG);
|
||||
|
Reference in New Issue
Block a user