std: xous: pass entire memory range to flag updater
When updating memory flags via `update_memory_flags()`, ensure we multiply the slice length by the element size to get the full memory size. Signed-off-by: Sean Cross <sean@xobs.io>
This commit is contained in:
parent
626926f073
commit
f732d2bfe2
1 changed files with 1 additions and 1 deletions
|
@ -452,7 +452,7 @@ pub(crate) unsafe fn update_memory_flags<T>(
|
|||
) -> Result<(), Error> {
|
||||
let mut a0 = Syscall::UpdateMemoryFlags as usize;
|
||||
let mut a1 = range.as_mut_ptr() as usize;
|
||||
let a2 = range.len();
|
||||
let a2 = range.len() * core::mem::size_of::<T>();
|
||||
let a3 = new_flags.bits();
|
||||
let a4 = 0; // Process ID is currently None
|
||||
let a5 = 0;
|
||||
|
|
Loading…
Add table
Reference in a new issue