summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/mips/mips/vm_machdep.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/sys/mips/mips/vm_machdep.c b/sys/mips/mips/vm_machdep.c
index 34dcea8..cbbe990 100644
--- a/sys/mips/mips/vm_machdep.c
+++ b/sys/mips/mips/vm_machdep.c
@@ -618,14 +618,18 @@ cpu_set_user_tls(struct thread *td, void *tls_base)
#ifdef __mips_n64
#ifdef COMPAT_FREEBSD32
- if (SV_PROC_FLAG(td->td_proc, SV_ILP32))
- td->td_md.md_tls = (char*)tls_base + 0x7008;
+ if (!SV_PROC_FLAG(td->td_proc, SV_ILP32)) {
#endif
- td->td_md.md_tls = (char*)tls_base + 0x7010;
-#else
- td->td_md.md_tls = (char*)tls_base + 0x7008;
+ td->td_md.md_tls = (char*)tls_base + 0x7010;
+ return (0);
+#ifdef COMPAT_FREEBSD32
+ }
#endif
+#endif
+#if !defined(__mips_n64) || defined(COMPAT_FREEBSD32)
+ td->td_md.md_tls = (char*)tls_base + 0x7008;
return (0);
+#endif
}
#ifdef DDB
OpenPOWER on IntegriCloud