Skip to content

Commit

Permalink
config: use MEMORY_END from mod boards #136
Browse files Browse the repository at this point in the history
  • Loading branch information
wyfcyx committed Jan 21, 2024
1 parent f046926 commit 079760a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
1 change: 1 addition & 0 deletions os/src/boards/qemu.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
//! Constants used in rCore for qemu
pub const CLOCK_FREQ: usize = 12500000;
pub const MEMORY_END: usize = 0x8800_0000;

pub const MMIO: &[(usize, usize)] = &[
(0x0010_0000, 0x00_2000), // VIRT_TEST/RTC in virt machine
Expand Down
3 changes: 1 addition & 2 deletions os/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
pub const USER_STACK_SIZE: usize = 4096 * 2;
pub const KERNEL_STACK_SIZE: usize = 4096 * 2;
pub const KERNEL_HEAP_SIZE: usize = 0x30_0000;
pub const MEMORY_END: usize = 0x80800000;
pub const PAGE_SIZE: usize = 0x1000;
pub const PAGE_SIZE_BITS: usize = 0xc;

Expand All @@ -16,4 +15,4 @@ pub fn kernel_stack_position(app_id: usize) -> (usize, usize) {
(bottom, top)
}

pub use crate::board::{CLOCK_FREQ, MMIO};
pub use crate::board::{CLOCK_FREQ, MEMORY_END, MMIO};

0 comments on commit 079760a

Please sign in to comment.