mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-15 08:30:02 +00:00
add a routine to print the info region
The info region is a region of RRAM that is used to configure the chip - boot security, what CPUs can run, access control lists, etc. There's no secrets in here, but it's very helpful to inspect for audits and correctness of configuration, so a routine is added to print it in boot1.
This commit is contained in:
parent
86f0b18fdc
commit
b06c124b3e
1 changed files with 9 additions and 1 deletions
|
|
@ -557,6 +557,14 @@ impl Repl {
|
|||
let mut rcurst = CSR::new(utra::sysctrl::HW_SYSCTRL_BASE as *mut u32);
|
||||
rcurst.wo(utra::sysctrl::SFR_RCURST0, 0x55AA);
|
||||
}
|
||||
"ifr" => {
|
||||
// safety: the IFR region is aligned and exists here. It is sealed by hardware in USER mode,
|
||||
// and should report as all 0's.
|
||||
let ifr = unsafe { core::slice::from_raw_parts(0x6040_0000 as *const u8, 0x400) };
|
||||
for (i, chunk) in ifr.chunks(32).enumerate() {
|
||||
crate::println!(" {:03x}: {:02x?}", i * 32, chunk);
|
||||
}
|
||||
}
|
||||
#[cfg(feature = "test-boot0-keys")]
|
||||
"publock" => {
|
||||
let rram = CSR::new(utra::rrc::HW_RRC_BASE as *mut u32);
|
||||
|
|
@ -655,7 +663,7 @@ impl Repl {
|
|||
_ => {
|
||||
crate::println!("Command not recognized: {}", cmd);
|
||||
crate::print!(
|
||||
"Commands include: reset, echo, altboot, boot, bootwait, idmode, localecho, uf2, boardtype, audit, lockdown, paranoid, self_destruct"
|
||||
"Commands include: reset, echo, altboot, boot, bootwait, idmode, localecho, uf2, boardtype, audit, lockdown, paranoid, self_destruct, ifr"
|
||||
);
|
||||
#[cfg(feature = "test-boot0-keys")]
|
||||
crate::print!(", publock");
|
||||
|
|
|
|||
Loading…
Reference in a new issue