shithub: riscv

Download patch

ref: f0ac2d01765f938a4f3656efef440cf2c1bca69d
parent: a0c756078220916db7aef3538502e1d70d4d6a77
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Sun Dec 31 21:35:13 EST 2023

sgi: fix botched conversion to stacks below Proc.

--- a/sys/src/9/sgi/l.s
+++ b/sys/src/9/sgi/l.s
@@ -442,6 +442,7 @@
 wasuser:				/* get kernel stack for this user process */
 	GETMACH	(SP)
 	MOVW	8(SP), SP		/*  m->proc */
+	SUBU	$(UREGSIZE), SP
 
 dosave:
 	MOVW	R31, 0x28(SP)