Minor readme tweaks
This commit is contained in:
parent
a429d20e18
commit
0e585b955e
@ -1,9 +1,7 @@
|
||||
|
||||
# Gila v0.2.2 - a Rust Microkernel
|
||||
|
||||
Gila is a Rust microkernel OS, inspired by the Xinu embedded OS. It will
|
||||
hopefully be capable of multitasking some day. I do not intend for Gila to
|
||||
be POSIX-like or compatible.
|
||||
Gila is a Rust microkernel OS, inspired by the Xinu embedded OS, as well as Linux. I aim to implement multitasking and different users for processes, and eventually a filesystem. I do not aim to make it POSIX-compatible, but it will likely end up sharing many features with POSIX operating systems.
|
||||
|
||||
## Work In Progress
|
||||
|
||||
|
@ -1,5 +1,6 @@
|
||||
use core::arch::asm;
|
||||
|
||||
#[allow(clippy::missing_safety_doc)]
|
||||
pub unsafe fn halt() {
|
||||
unsafe {
|
||||
asm!("wfi");
|
||||
|
@ -1,5 +1,6 @@
|
||||
use core::arch::asm;
|
||||
|
||||
#[allow(clippy::missing_safety_doc)]
|
||||
pub unsafe fn halt() {
|
||||
unsafe {
|
||||
asm!("idle 0");
|
||||
|
@ -1,5 +1,6 @@
|
||||
use core::arch::asm;
|
||||
|
||||
#[allow(clippy::missing_safety_doc)]
|
||||
pub unsafe fn halt() {
|
||||
unsafe {
|
||||
asm!("wfi");
|
||||
|
@ -1,5 +1,6 @@
|
||||
use core::arch::asm;
|
||||
|
||||
#[allow(clippy::missing_safety_doc)]
|
||||
pub unsafe fn halt() {
|
||||
unsafe {
|
||||
asm!("hlt");
|
||||
|
@ -10,6 +10,12 @@ pub struct TextDisplay {
|
||||
row: usize,
|
||||
}
|
||||
|
||||
impl Default for TextDisplay {
|
||||
fn default() -> Self {
|
||||
Self::new()
|
||||
}
|
||||
}
|
||||
|
||||
impl TextDisplay {
|
||||
pub const fn new() -> Self {
|
||||
TextDisplay {
|
||||
|
@ -21,6 +21,12 @@ pub trait LogSubscriber {
|
||||
fn write(&self, msg: &str);
|
||||
}
|
||||
|
||||
impl Default for Logger {
|
||||
fn default() -> Self {
|
||||
Self::new()
|
||||
}
|
||||
}
|
||||
|
||||
impl Logger {
|
||||
pub const fn new() -> Self {
|
||||
Logger {
|
||||
|
17
src/main.rs
17
src/main.rs
@ -72,11 +72,20 @@ unsafe extern "C" fn main() -> ! {
|
||||
let _smp_response = SMP_REQUEST.get_response();
|
||||
|
||||
match _smp_response {
|
||||
None => log(LogLevel::ERROR, "SMP response not received. Multiprocessing is disabled."),
|
||||
None => log(
|
||||
LogLevel::ERROR,
|
||||
"SMP response not received. Multiprocessing is disabled.",
|
||||
),
|
||||
Some(resp) => {
|
||||
log(LogLevel::INFO, "SMP response received. Multiprocessing enabled.");
|
||||
log(LogLevel::INFO, &format!("{} CPUs found.", resp.cpus().len()));
|
||||
},
|
||||
log(
|
||||
LogLevel::INFO,
|
||||
"SMP response received. Multiprocessing enabled.",
|
||||
);
|
||||
log(
|
||||
LogLevel::INFO,
|
||||
&format!("{} CPUs found.", resp.cpus().len()),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
loop {
|
||||
|
Loading…
Reference in New Issue
Block a user