diff options
author | Wojtek Kosior <kwojtus@protonmail.com> | 2019-12-28 15:55:29 +0100 |
---|---|---|
committer | Wojtek Kosior <kwojtus@protonmail.com> | 2019-12-28 15:55:29 +0100 |
commit | c374eaacbc0d16983bbd1112fefa74dbe88e1e53 (patch) | |
tree | c6930675e0200a4aed724fd65947853f2b4f274f /libkernel.c | |
parent | 7062b101197c03c7f4806d83b8d79cf34d3b6a42 (diff) | |
download | rpi-MMU-example-c374eaacbc0d16983bbd1112fefa74dbe88e1e53.tar.gz rpi-MMU-example-c374eaacbc0d16983bbd1112fefa74dbe88e1e53.zip |
use ldm instruction instead of libkernel for entering user mode; get rid of libkernel (no longer needed)
Diffstat (limited to 'libkernel.c')
-rw-r--r-- | libkernel.c | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/libkernel.c b/libkernel.c deleted file mode 100644 index 0955e0e..0000000 --- a/libkernel.c +++ /dev/null @@ -1,12 +0,0 @@ -// This is the privileged code, that gets placed somewhere in -// unprivileged process' address space. It's compiled as relocatable, -// so it can be loaded at different address for different processes. - -void call_unprivileged(void (*address) (void)) { - // switch to PL0 - asm("cps #0b10000\n\r" - "isb" ::: "memory"); - - // jump to that unprivileged code - address(); -} |