From e6d4e507e241c03b85d2a2cd088c44ff32d0f5db Mon Sep 17 00:00:00 2001 From: pjht Date: Tue, 19 Mar 2024 13:11:56 -0500 Subject: [PATCH] Add support for vmem_copy_to_secondary syscall --- include/syscalls.i | 2 ++ syscalls.68k | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/include/syscalls.i b/include/syscalls.i index 160777c..4f56c7f 100644 --- a/include/syscalls.i +++ b/include/syscalls.i @@ -21,4 +21,6 @@ __STD_SYSCALLS_I equ 1 xref syscall_vmem_map_free_to ; Sets the permission flags of the range of virtual pages starting at address a0 with length d1 to d0 xref syscall_vmem_set_flags +; Copies the range of page mappings at address a0 in the primary space with length d0 to the secondary space starting at address a1 + xref syscall_vmem_copy_to_secondary endif diff --git a/syscalls.68k b/syscalls.68k index a9c5525..0b56e42 100644 --- a/syscalls.68k +++ b/syscalls.68k @@ -78,3 +78,11 @@ syscall_vmem_set_flags: trap #0 move.l (a7)+, d2 rts + + public syscall_vmem_copy_to_secondary +; Copies the range of page mappings at address a0 in the primary space with length d0 to the secondary space starting at address a1 +syscall_vmem_copy_to_secondary: + move.l d0, d1 + move.l #8, d0 + trap #0 + rts