summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/amd64/amd64/mp_machdep.c2
-rw-r--r--sys/amd64/amd64/mptable.c2
-rw-r--r--sys/amd64/amd64/sys_machdep.c4
-rw-r--r--sys/amd64/include/mptable.h2
-rw-r--r--sys/i386/i386/mp_machdep.c2
-rw-r--r--sys/i386/i386/mptable.c2
-rw-r--r--sys/i386/i386/sys_machdep.c4
-rw-r--r--sys/i386/include/mptable.h2
-rw-r--r--sys/kern/subr_smp.c2
9 files changed, 11 insertions, 11 deletions
diff --git a/sys/amd64/amd64/mp_machdep.c b/sys/amd64/amd64/mp_machdep.c
index 95b5759f9e66..67422b2be086 100644
--- a/sys/amd64/amd64/mp_machdep.c
+++ b/sys/amd64/amd64/mp_machdep.c
@@ -480,7 +480,7 @@ init_secondary(void)
lldt(_default_ldt);
#ifdef USER_LDT
- currentldt = _default_ldt;
+ PCPU_SET(currentldt, _default_ldt);
#endif
gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);
diff --git a/sys/amd64/amd64/mptable.c b/sys/amd64/amd64/mptable.c
index 95b5759f9e66..67422b2be086 100644
--- a/sys/amd64/amd64/mptable.c
+++ b/sys/amd64/amd64/mptable.c
@@ -480,7 +480,7 @@ init_secondary(void)
lldt(_default_ldt);
#ifdef USER_LDT
- currentldt = _default_ldt;
+ PCPU_SET(currentldt, _default_ldt);
#endif
gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);
diff --git a/sys/amd64/amd64/sys_machdep.c b/sys/amd64/amd64/sys_machdep.c
index 081d28c93b2c..bd7f0d8cc0d9 100644
--- a/sys/amd64/amd64/sys_machdep.c
+++ b/sys/amd64/amd64/sys_machdep.c
@@ -263,7 +263,7 @@ set_user_ldt(struct pcb *pcb)
gdt[GUSERLDT_SEL].sd = pcb_ldt->ldt_sd;
#endif
lldt(GSEL(GUSERLDT_SEL, SEL_KPL));
- currentldt = GSEL(GUSERLDT_SEL, SEL_KPL);
+ PCPU_SET(currentldt, GSEL(GUSERLDT_SEL, SEL_KPL));
}
struct pcb_ldt *
@@ -311,7 +311,7 @@ user_ldt_free(struct pcb *pcb)
if (pcb == curpcb) {
lldt(_default_ldt);
- currentldt = _default_ldt;
+ PCPU_SET(currentldt, _default_ldt);
}
if (--pcb_ldt->ldt_refcnt == 0) {
diff --git a/sys/amd64/include/mptable.h b/sys/amd64/include/mptable.h
index 95b5759f9e66..67422b2be086 100644
--- a/sys/amd64/include/mptable.h
+++ b/sys/amd64/include/mptable.h
@@ -480,7 +480,7 @@ init_secondary(void)
lldt(_default_ldt);
#ifdef USER_LDT
- currentldt = _default_ldt;
+ PCPU_SET(currentldt, _default_ldt);
#endif
gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);
diff --git a/sys/i386/i386/mp_machdep.c b/sys/i386/i386/mp_machdep.c
index 95b5759f9e66..67422b2be086 100644
--- a/sys/i386/i386/mp_machdep.c
+++ b/sys/i386/i386/mp_machdep.c
@@ -480,7 +480,7 @@ init_secondary(void)
lldt(_default_ldt);
#ifdef USER_LDT
- currentldt = _default_ldt;
+ PCPU_SET(currentldt, _default_ldt);
#endif
gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);
diff --git a/sys/i386/i386/mptable.c b/sys/i386/i386/mptable.c
index 95b5759f9e66..67422b2be086 100644
--- a/sys/i386/i386/mptable.c
+++ b/sys/i386/i386/mptable.c
@@ -480,7 +480,7 @@ init_secondary(void)
lldt(_default_ldt);
#ifdef USER_LDT
- currentldt = _default_ldt;
+ PCPU_SET(currentldt, _default_ldt);
#endif
gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);
diff --git a/sys/i386/i386/sys_machdep.c b/sys/i386/i386/sys_machdep.c
index 081d28c93b2c..bd7f0d8cc0d9 100644
--- a/sys/i386/i386/sys_machdep.c
+++ b/sys/i386/i386/sys_machdep.c
@@ -263,7 +263,7 @@ set_user_ldt(struct pcb *pcb)
gdt[GUSERLDT_SEL].sd = pcb_ldt->ldt_sd;
#endif
lldt(GSEL(GUSERLDT_SEL, SEL_KPL));
- currentldt = GSEL(GUSERLDT_SEL, SEL_KPL);
+ PCPU_SET(currentldt, GSEL(GUSERLDT_SEL, SEL_KPL));
}
struct pcb_ldt *
@@ -311,7 +311,7 @@ user_ldt_free(struct pcb *pcb)
if (pcb == curpcb) {
lldt(_default_ldt);
- currentldt = _default_ldt;
+ PCPU_SET(currentldt, _default_ldt);
}
if (--pcb_ldt->ldt_refcnt == 0) {
diff --git a/sys/i386/include/mptable.h b/sys/i386/include/mptable.h
index 95b5759f9e66..67422b2be086 100644
--- a/sys/i386/include/mptable.h
+++ b/sys/i386/include/mptable.h
@@ -480,7 +480,7 @@ init_secondary(void)
lldt(_default_ldt);
#ifdef USER_LDT
- currentldt = _default_ldt;
+ PCPU_SET(currentldt, _default_ldt);
#endif
gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);
diff --git a/sys/kern/subr_smp.c b/sys/kern/subr_smp.c
index 95b5759f9e66..67422b2be086 100644
--- a/sys/kern/subr_smp.c
+++ b/sys/kern/subr_smp.c
@@ -480,7 +480,7 @@ init_secondary(void)
lldt(_default_ldt);
#ifdef USER_LDT
- currentldt = _default_ldt;
+ PCPU_SET(currentldt, _default_ldt);
#endif
gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);