Page MenuHomeFreeBSD

D60132.id188010.diff
No OneTemporary

D60132.id188010.diff

diff --git a/sys/riscv/include/pcpu.h b/sys/riscv/include/pcpu.h
--- a/sys/riscv/include/pcpu.h
+++ b/sys/riscv/include/pcpu.h
@@ -47,7 +47,8 @@
uint32_t pc_pending_ipis; /* IPIs pending to this CPU */ \
uint32_t pc_hart; /* Hart ID */ \
uint64_t pc_clock; \
- char __pad[48] /* Pad to factor of PAGE_SIZE */
+ uintptr_t pc_canary; \
+ char __pad[40] /* Pad to factor of PAGE_SIZE */
#ifdef _KERNEL
diff --git a/sys/riscv/include/proc.h b/sys/riscv/include/proc.h
--- a/sys/riscv/include/proc.h
+++ b/sys/riscv/include/proc.h
@@ -34,6 +34,7 @@
struct mdthread {
int md_spinlock_count; /* (k) */
register_t md_saved_sstatus_ie; /* (k) */
+ register_t md_canary; /* (k) */
};
struct mdproc {
diff --git a/sys/riscv/riscv/genassym.c b/sys/riscv/riscv/genassym.c
--- a/sys/riscv/riscv/genassym.c
+++ b/sys/riscv/riscv/genassym.c
@@ -75,6 +75,7 @@
ASSYM(PC_CURPCB, offsetof(struct pcpu, pc_curpcb));
ASSYM(PC_CURTHREAD, offsetof(struct pcpu, pc_curthread));
+ASSYM(PC_CANARY, offsetof(struct pcpu, pc_canary));
ASSYM(TD_PCB, offsetof(struct thread, td_pcb));
ASSYM(TD_FLAGS, offsetof(struct thread, td_flags));
@@ -82,6 +83,7 @@
ASSYM(TD_PROC, offsetof(struct thread, td_proc));
ASSYM(TD_FRAME, offsetof(struct thread, td_frame));
ASSYM(TD_MD, offsetof(struct thread, td_md));
+ASSYM(TD_MD_CANARY, offsetof(struct thread, td_md.md_canary));
ASSYM(TD_LOCK, offsetof(struct thread, td_lock));
ASSYM(TF_SIZE, TF_SIZE);

File Metadata

Mime Type
text/plain
Expires
Thu, Oct 1, 12:20 AM (5 h, 55 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
39975838
Default Alt Text
D60132.id188010.diff (1 KB)

Event Timeline