Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F111616595
D31969.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
810 B
Referenced Files
None
Subscribers
None
D31969.diff
View Options
diff --git a/sys/arm64/include/cpu.h b/sys/arm64/include/cpu.h
--- a/sys/arm64/include/cpu.h
+++ b/sys/arm64/include/cpu.h
@@ -45,7 +45,7 @@
#include <machine/frame.h>
#include <machine/armreg.h>
-#define TRAPF_PC(tfp) ((tfp)->tf_lr)
+#define TRAPF_PC(tfp) ((tfp)->tf_elr)
#define TRAPF_USERMODE(tfp) (((tfp)->tf_spsr & PSR_M_MASK) == PSR_M_EL0t)
#define cpu_getstack(td) ((td)->td_frame->tf_sp)
diff --git a/sys/riscv/include/cpu.h b/sys/riscv/include/cpu.h
--- a/sys/riscv/include/cpu.h
+++ b/sys/riscv/include/cpu.h
@@ -41,7 +41,7 @@
#include <machine/cpufunc.h>
#include <machine/frame.h>
-#define TRAPF_PC(tfp) ((tfp)->tf_ra)
+#define TRAPF_PC(tfp) ((tfp)->tf_sepc)
#define TRAPF_USERMODE(tfp) (((tfp)->tf_sstatus & SSTATUS_SPP) == 0)
#define cpu_getstack(td) ((td)->td_frame->tf_sp)
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Mar 7, 1:40 AM (12 h, 39 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
17023087
Default Alt Text
D31969.diff (810 B)
Attached To
Mode
D31969: arm64, riscv: Fix TRAF_PC() to return the PC, not the return address.
Attached
Detach File
Event Timeline
Log In to Comment