Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F102663146
D40584.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D40584.diff
View Options
diff --git a/sys/riscv/riscv/intr_machdep.c b/sys/riscv/riscv/intr_machdep.c
--- a/sys/riscv/riscv/intr_machdep.c
+++ b/sys/riscv/riscv/intr_machdep.c
@@ -163,6 +163,9 @@
active_irq = frame->tf_scause & SCAUSE_CODE;
+ CTR3(KTR_TRAP, "%s: irq=%d, umode=%d", __func__, active_irq,
+ TRAPF_USERMODE(frame));
+
switch (active_irq) {
case IRQ_SOFTWARE_USER:
case IRQ_SOFTWARE_SUPERVISOR:
diff --git a/sys/riscv/riscv/trap.c b/sys/riscv/riscv/trap.c
--- a/sys/riscv/riscv/trap.c
+++ b/sys/riscv/riscv/trap.c
@@ -291,8 +291,8 @@
return;
#endif
- CTR3(KTR_TRAP, "do_trap_supervisor: curthread: %p, sepc: %lx, frame: %p",
- curthread, frame->tf_sepc, frame);
+ CTR4(KTR_TRAP, "%s: exception=%lu, sepc=%lx, stval=%lx", __func__,
+ exception, frame->tf_sepc, frame->tf_stval);
switch (exception) {
case SCAUSE_LOAD_ACCESS_FAULT:
@@ -365,8 +365,8 @@
}
intr_enable();
- CTR3(KTR_TRAP, "do_trap_user: curthread: %p, sepc: %lx, frame: %p",
- curthread, frame->tf_sepc, frame);
+ CTR4(KTR_TRAP, "%s: exception=%lu, sepc=%lx, stval=%lx", __func__,
+ exception, frame->tf_sepc, frame->tf_stval);
switch (exception) {
case SCAUSE_LOAD_ACCESS_FAULT:
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Nov 16, 1:01 PM (21 h, 9 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14659049
Default Alt Text
D40584.diff (1 KB)
Attached To
Mode
D40584: riscv: improve KTR_TRAP trace entries
Attached
Detach File
Event Timeline
Log In to Comment