Commit 2459ee86 authored by Andy Lutomirski's avatar Andy Lutomirski Committed by Thomas Gleixner
Browse files

x86/vm86: Set thread.vm86 to NULL on fork/clone

thread.vm86 points to per-task information -- the pointer should not
be copied on clone.

Fixes: d4ce0f26

 ("x86/vm86: Move fields from 'struct kernel_vm86_struct' to 'struct vm86'")
Signed-off-by: default avatarAndy Lutomirski <>
Cc: Brian Gerst <>
Cc: Linus Torvalds <>
Cc: Borislav Petkov <>
Cc: Stas Sergeev <>

Signed-off-by: default avatarThomas Gleixner <>
parent 226f1f72
......@@ -84,6 +84,9 @@ EXPORT_SYMBOL_GPL(idle_notifier_unregister);
int arch_dup_task_struct(struct task_struct *dst, struct task_struct *src)
memcpy(dst, src, arch_task_struct_size);
#ifdef CONFIG_VM86
dst->thread.vm86 = NULL;
return fpu__copy(&dst->thread.fpu, &src->thread.fpu);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment