Skeleton for architecture-specific things

This commit is contained in:
Erin 2022-11-07 21:21:16 +01:00 committed by ondra05
parent 4812e59c09
commit f396c3642d
5 changed files with 20 additions and 0 deletions

View file

@ -0,0 +1 @@
//!

16
kernel/src/arch/mod.rs Normal file
View file

@ -0,0 +1,16 @@
//! Architecture specific code
macro_rules! arch_cond {
($($arch:ident: $str:literal),* $(,)?) => {$(
#[cfg(target_arch = $str)]
pub mod $arch;
#[cfg(target_arch = $str)]
pub use $arch::*;
)*};
}
arch_cond!(
aarch64: "aarch64",
riscv64: "riscv64",
x86_64: "x86_64",
);

View file

@ -0,0 +1 @@
//!

View file

@ -0,0 +1 @@
//!

View file

@ -7,6 +7,7 @@
extern crate alloc;
pub mod allocator;
pub mod arch;
pub mod task;
use versioning::Version;