Skip to content

Commit

Permalink
Merge pull request #2 from rel4team/boot_bss
Browse files Browse the repository at this point in the history
clean boot.bss problem
  • Loading branch information
ZhiyuanSue authored Aug 16, 2024
2 parents 7131e54 + 92523f4 commit 1f0b4f8
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions kernel/src/boot/mm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ static mut avail_reg: [region_t; MAX_NUM_FREEMEM_REG] =
pub static mut res_reg: [region_t; NUM_RESERVED_REGIONS] =
[region_t { start: 0, end: 0 }; NUM_RESERVED_REGIONS];

#[link_section = ".boot.bss"]
// #[link_section = ".boot.bss"]
pub static mut avail_p_regs_size: usize = 0;

#[link_section = ".boot.bss"]
// #[link_section = ".boot.bss"]
pub static mut avail_p_regs_addr: usize = 0;

pub fn rust_init_freemem(
Expand Down
2 changes: 1 addition & 1 deletion kernel/src/interrupt/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ pub static mut intStateIRQTable: [usize; maxIRQ + 1] = [0; maxIRQ + 1];
pub static mut intStateIRQNode: pptr_t = 0;

#[no_mangle]
#[link_section = ".boot.bss"]
// #[link_section = ".boot.bss"]
pub static mut active_irq: [usize; CONFIG_MAX_NUM_NODES] = [0; CONFIG_MAX_NUM_NODES];

#[cfg(feature = "ENABLE_SMP")]
Expand Down
8 changes: 4 additions & 4 deletions kernel/src/kernel/boot.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,17 @@ use sel4_cspace::interface::cte_t;
use crate::structures::{extra_caps_t, syscall_error_t};

#[no_mangle]
#[link_section = ".boot.bss"]
// #[link_section = ".boot.bss"]
pub static mut current_lookup_fault: lookup_fault_t = lookup_fault_t { words: [0; 2] };

#[no_mangle]
#[link_section = ".boot.bss"]
// #[link_section = ".boot.bss"]
pub static mut current_fault: seL4_Fault_t = seL4_Fault_t {
words: [0; seL4_Fault_t::WIDTH],
};

#[no_mangle]
#[link_section = ".boot.bss"]
// #[link_section = ".boot.bss"]
pub static mut current_syscall_error: syscall_error_t = syscall_error_t {
invalidArgumentNumber: 0,
invalidCapNumber: 0,
Expand All @@ -32,7 +32,7 @@ pub static mut current_syscall_error: syscall_error_t = syscall_error_t {
};

#[no_mangle]
#[link_section = ".boot.bss"]
// #[link_section = ".boot.bss"]
pub static mut current_extra_caps: extra_caps_t = extra_caps_t {
excaprefs: [0; seL4_MsgMaxExtraCaps],
};
Expand Down
4 changes: 2 additions & 2 deletions sel4_task/src/scheduler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,10 @@ pub static mut ksReadyQueuesL2Bitmap: [[usize; L2_BITMAP_SIZE]; CONFIG_NUM_DOMAI
pub static mut ksReadyQueuesL1Bitmap: [usize; CONFIG_NUM_DOMAINS] = [0; CONFIG_NUM_DOMAINS];

#[no_mangle]
#[link_section = ".boot.bss"]
// #[link_section = ".boot.bss"]
pub static mut ksWorkUnitsCompleted: usize = 0;

#[link_section = ".boot.bss"]
// #[link_section = ".boot.bss"]
pub static mut ksDomSchedule: [dschedule_t; ksDomScheduleLength] = [dschedule_t {
domain: 0,
length: 60,
Expand Down

0 comments on commit 1f0b4f8

Please sign in to comment.