We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 073b032 commit 5ce6160Copy full SHA for 5ce6160
src/aero_kernel/src/userland/vm.rs
@@ -27,6 +27,7 @@ use xmas_elf::header::*;
27
use xmas_elf::program::*;
28
use xmas_elf::*;
29
30
+use crate::arch::controlregs;
31
use crate::arch::task::userland_last_address;
32
use crate::fs;
33
use crate::fs::cache::DirCacheItem;
@@ -385,7 +386,7 @@ impl Mapping {
385
386
let new_slice = new_frame.as_slice_mut::<u8>();
387
388
// Copy the contents from the old frame to the newly allocated frame.
- new_slice.copy_from_slice(old_slice);
389
+ controlregs::with_userspace_access(||new_slice.copy_from_slice(old_slice));
390
391
// Re-map the page to the newly allocated frame and with the provided
392
// protection flags.
0 commit comments