fix: rename RINA to LISA

This commit is contained in:
Faynot
2026-06-23 22:48:46 +03:00
parent d542b5586d
commit 8a195462e5
3 changed files with 104 additions and 94 deletions

View File

@@ -45,9 +45,9 @@ impl DrawTarget for FramebufferDisplay<'_> {
for Pixel(coord, color) in pixels {
if coord.x >= 0 && coord.x < self.framebuffer.width() as i32 &&
coord.y >= 0 && coord.y < self.framebuffer.height() as i32 {
let offset = (coord.y as usize * self.framebuffer.pitch() as usize) + (coord.x as usize * 4);
unsafe {
self.framebuffer.addr().add(offset).cast::<u32>().write(color.into_storage());
}
@@ -76,7 +76,7 @@ impl<'a> Console<'a> {
Self { display, x: 10, y: 20, current_color: Rgb888::WHITE }
}
pub fn set_color(&mut self, color: Rgb888) {
pub fn set_color(&mut self, color: Rgb888) {
self.current_color = color;
}
@@ -94,7 +94,7 @@ impl<'a> Console<'a> {
let fb = self.display.framebuffer;
let pitch = fb.pitch() as usize;
let height = fb.height() as usize;
let font_height = 10;
let font_height = 10;
let shift = font_height * pitch;
unsafe {
@@ -123,7 +123,7 @@ impl fmt::Write for Console<'_> {
let mut buf = [0u8; 4];
let s_char = c.encode_utf8(&mut buf);
let _ = Text::new(s_char, Point::new(self.x, self.y), style).draw(&mut self.display);
self.x += 6;
}
@@ -172,7 +172,7 @@ unsafe extern "C" fn kmain() -> ! {
let mut console = Console::new(FramebufferDisplay { framebuffer: &fb });
console.clear();
info!(console, "BOOT", "RINA Kernel Starting...");
info!(console, "BOOT", "LISA Kernel Starting...");
unsafe { mem::pmm::BitmapPMM::init(&mmap_res, hhdm_offset); }
info!(console, "MEM", "Physical Memory Manager initialized.");
@@ -210,7 +210,7 @@ unsafe extern "C" fn kmain() -> ! {
}
info!(console, "HEAP", "Global Allocator is online.");
let root_cnode = cap::CNode::new(256);
if let Some(frame) = mem::pmm::alloc_frame() {
@@ -220,13 +220,13 @@ unsafe extern "C" fn kmain() -> ! {
relation: Relation::Strong,
token_sig: 0x1,
};
root_cnode.insert(0, mem_cap).unwrap();
info!(console, "CAP", "Root capability created at slot 0");
}
root_cnode.mint(0, 10, Relation::Borrow, CapRights::READ | CapRights::WRITE).unwrap();
if let Some(c) = root_cnode.get_cap(10) {
info!(console, "CAP", "Slot 10 (Borrowed): {:?}", c.relation);
}
@@ -238,23 +238,23 @@ unsafe extern "C" fn kmain() -> ! {
}
}
let logo = r#"
###########
##################
###### ######
##### #####
#### ##### ####
#### ### ###### ####
###########
##################
###### ######
##### #####
#### ##### ####
#### ### ###### ####
#### #### #### ####
#### #### ### ####
#### ### ## ### ####
#### ######## #### ####
#### #### #### ####
#### ###### ### ####
#### ####### ####
##### #####
###### ######
##################
############
#### ###### ### ####
#### ####### ####
##### #####
###### ######
##################
############
"#;
let _ = writeln!(console, "{}", logo);