diff --git a/sys/i386/i386/sys_machdep.c b/sys/i386/i386/sys_machdep.c index beffff2e1747..374690fa7a59 100644 --- a/sys/i386/i386/sys_machdep.c +++ b/sys/i386/i386/sys_machdep.c @@ -553,7 +553,7 @@ user_ldt_free(struct thread *td) return; } - if (td == PCPU_GET(curthread)) { + if (td == curthread) { #ifdef XEN i386_reset_ldt(&default_proc_ldt); PCPU_SET(currentldt, (int)&default_proc_ldt); diff --git a/sys/mips/mips/gdb_machdep.c b/sys/mips/mips/gdb_machdep.c index 780a4f18bab8..e8702f463839 100644 --- a/sys/mips/mips/gdb_machdep.c +++ b/sys/mips/mips/gdb_machdep.c @@ -116,7 +116,7 @@ gdb_cpu_getreg(int regnum, size_t *regsz) { *regsz = gdb_cpu_regsz(regnum); - if (kdb_thread == PCPU_GET(curthread)) { + if (kdb_thread == curthread) { register_t *zero_ptr = &kdb_frame->zero; return zero_ptr + regnum; } @@ -154,7 +154,7 @@ gdb_cpu_setreg(int regnum, void *val) switch (regnum) { case GDB_REG_PC: kdb_thrctx->pcb_context[10] = *(register_t *)val; - if (kdb_thread == PCPU_GET(curthread)) + if (kdb_thread == curthread) kdb_frame->pc = *(register_t *)val; } }