diff options
author | Christian Cunningham <cc@localhost> | 2022-08-17 22:22:56 -0700 |
---|---|---|
committer | Christian Cunningham <cc@localhost> | 2022-08-17 22:22:56 -0700 |
commit | 5494645e2607706655f8e3466f3ec858db303061 (patch) | |
tree | 6f56fd19eca7cefa65fb083a566a0a95033892ee /src/kernel.rs | |
parent | 91d0ae783e51062f77b120b05c97cd352b9b86d5 (diff) |
Fix template
Diffstat (limited to 'src/kernel.rs')
-rw-r--r-- | src/kernel.rs | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/kernel.rs b/src/kernel.rs new file mode 100644 index 0000000..9697ca8 --- /dev/null +++ b/src/kernel.rs @@ -0,0 +1,29 @@ +//! Kernel Code + +#![allow(non_snake_case)] +#![allow(clippy::upper_case_acronyms,dead_code)] +#![feature(format_args_nl)] +#![feature(panic_info_message)] +#![feature(trait_alias)] +#![feature(exclusive_range_pattern)] +#![no_main] +#![no_std] + +mod cpu; +mod panic_wait; +mod uart; +use crate::uart::*; + +/// Initialization Code +unsafe fn kernel_init() -> ! { + uart_init(); + + kernel_main() +} + +fn kernel_main() -> ! { + write_char(b'a'); + write_char(b'b'); + loop { + } +} |