summaryrefslogtreecommitdiffstats
path: root/arch/x86/um/tls_64.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86/um/tls_64.c')
-rw-r--r--arch/x86/um/tls_64.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/arch/x86/um/tls_64.c b/arch/x86/um/tls_64.c
new file mode 100644
index 000000000..ebd3855d9
--- /dev/null
+++ b/arch/x86/um/tls_64.c
@@ -0,0 +1,18 @@
+// SPDX-License-Identifier: GPL-2.0
+#include <linux/sched.h>
+#include <asm/ptrace-abi.h>
+
+void clear_flushed_tls(struct task_struct *task)
+{
+}
+
+int arch_set_tls(struct task_struct *t, unsigned long tls)
+{
+ /*
+ * If CLONE_SETTLS is set, we need to save the thread id
+ * so it can be set during context switches.
+ */
+ t->thread.arch.fs = tls;
+
+ return 0;
+}