mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-18 08:52:45 +00:00
refer cache flush to hal version
This commit is contained in:
parent
4fbae4969b
commit
508c38cfdd
2 changed files with 2 additions and 32 deletions
|
|
@ -361,7 +361,7 @@ pub fn process_update(perclk: u32) {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
progress_bar(&mut sh1107, 100);
|
progress_bar(&mut sh1107, 100);
|
||||||
cache_flush();
|
cramium_hal::cache_flush();
|
||||||
crate::println!(
|
crate::println!(
|
||||||
"data after: {:x?} .. {:x?}",
|
"data after: {:x?} .. {:x?}",
|
||||||
&check_slice[..32],
|
&check_slice[..32],
|
||||||
|
|
@ -621,18 +621,3 @@ pub fn write_rram(mbox: &mut Mbox, data: &[u32]) -> Result<usize, MboxError> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline(always)]
|
|
||||||
fn cache_flush() {
|
|
||||||
unsafe {
|
|
||||||
#[rustfmt::skip]
|
|
||||||
core::arch::asm!(
|
|
||||||
".word 0x500F",
|
|
||||||
"nop",
|
|
||||||
"nop",
|
|
||||||
"nop",
|
|
||||||
"nop",
|
|
||||||
"nop",
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
|
||||||
|
|
@ -340,7 +340,7 @@ impl<'a> ShellCmdApi<'a> for Mbox {
|
||||||
.ok();
|
.ok();
|
||||||
} else {
|
} else {
|
||||||
log::info!("Wrote {} bytes", rx_pkt.data[0]);
|
log::info!("Wrote {} bytes", rx_pkt.data[0]);
|
||||||
cache_flush();
|
cramium_hal::cache_flush();
|
||||||
let flash_slice: &[u8] = unsafe { self.flash_window.as_slice() };
|
let flash_slice: &[u8] = unsafe { self.flash_window.as_slice() };
|
||||||
log::info!("Data values before writing: {:x?}", &orig_data[..16]);
|
log::info!("Data values before writing: {:x?}", &orig_data[..16]);
|
||||||
log::info!("Data values after writing: {:x?}", &flash_slice[..16]);
|
log::info!("Data values after writing: {:x?}", &flash_slice[..16]);
|
||||||
|
|
@ -516,18 +516,3 @@ impl<'a> ShellCmdApi<'a> for Mbox {
|
||||||
Ok(Some(ret))
|
Ok(Some(ret))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline(always)]
|
|
||||||
fn cache_flush() {
|
|
||||||
unsafe {
|
|
||||||
#[rustfmt::skip]
|
|
||||||
core::arch::asm!(
|
|
||||||
".word 0x500F",
|
|
||||||
"nop",
|
|
||||||
"nop",
|
|
||||||
"nop",
|
|
||||||
"nop",
|
|
||||||
"nop",
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue