aboutsummaryrefslogtreecommitdiff
path: root/kernel/memory/paging/page.sats
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/memory/paging/page.sats')
-rw-r--r--kernel/memory/paging/page.sats18
1 files changed, 18 insertions, 0 deletions
diff --git a/kernel/memory/paging/page.sats b/kernel/memory/paging/page.sats
new file mode 100644
index 0000000..1de50c6
--- /dev/null
+++ b/kernel/memory/paging/page.sats
@@ -0,0 +1,18 @@
+staload FRAME = "kernel/memory/frame.sats"
+
+staload "lib/SATS/valid.sats"
+staload "./entry.sats"
+
+typedef vaddr = Ptr0
+
+typedef page_t = @{
+ num = size_t
+}
+
+fn translate(vaddr) : Valid $FRAME.paddr
+
+fn containing_address(vaddr) : page_t
+
+fn map_to{n:nat}(page_t,$FRAME.frame_t,&(@[entry_flag][n]),size : size_t n): void
+
+fn map{n:nat}(page_t,&(@[entry_flag][n]),size : size_t n) : void