X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;ds=sidebyside;f=KernelLand%2FKernel%2Farch%2Fx86_64%2Fproc.asm;h=f3b3a28aa579a4346484cd49009af1e06e07a0e8;hb=74ea5e7e82ed3a4f7fa981907177cf55b9b88f07;hp=f540b3b630281f8700a04c8c2885bf1def96f988;hpb=48743e39650eb1ef988380e9d95f27fd40d3a9ce;p=tpg%2Facess2.git diff --git a/KernelLand/Kernel/arch/x86_64/proc.asm b/KernelLand/Kernel/arch/x86_64/proc.asm index f540b3b6..f3b3a28a 100644 --- a/KernelLand/Kernel/arch/x86_64/proc.asm +++ b/KernelLand/Kernel/arch/x86_64/proc.asm @@ -21,7 +21,7 @@ NewTaskHeader: mov rdi, [rsp+0x10] mov rax, [rsp+0x8] add rsp, 0x10 ; Reclaim stack space (thread/fcn) - xchg bx, bx + ;xchg bx, bx call rax ; Quit thread with RAX as the return code @@ -39,6 +39,8 @@ Proc_CloneInt: PUSH_GPR ; Save RSP mov [rdi], rsp + ; Call MM_Clone (with bNoUserCopy flag) + mov rdi, rdx call MM_Clone ; Save CR3 mov rsi, [rsp+0x30] ; Saved version of RSI