diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2017-12-14 06:27:29 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2017-12-22 14:13:01 -0500 |
commit | c10e83f598d08046dd1ebc8360d4bb12d802d51b (patch) | |
tree | b1b8d341aefdd1869b07c33193499eb9019c09db /arch/um | |
parent | 4831b779403a836158917d59a7ca880483c67378 (diff) |
arch, mm: Allow arch_dup_mmap() to fail
In order to sanitize the LDT initialization on x86 arch_dup_mmap() must be
allowed to fail. Fix up all instances.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Andy Lutomirski <luto@kernel.org>
Cc: Andy Lutomirsky <luto@kernel.org>
Cc: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Borislav Petkov <bpetkov@suse.de>
Cc: Brian Gerst <brgerst@gmail.com>
Cc: Dave Hansen <dave.hansen@intel.com>
Cc: Dave Hansen <dave.hansen@linux.intel.com>
Cc: David Laight <David.Laight@aculab.com>
Cc: Denys Vlasenko <dvlasenk@redhat.com>
Cc: Eduardo Valentin <eduval@amazon.com>
Cc: Greg KH <gregkh@linuxfoundation.org>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: Juergen Gross <jgross@suse.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Will Deacon <will.deacon@arm.com>
Cc: aliguori@amazon.com
Cc: dan.j.williams@intel.com
Cc: hughd@google.com
Cc: keescook@google.com
Cc: kirill.shutemov@linux.intel.com
Cc: linux-mm@kvack.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch/um')
-rw-r--r-- | arch/um/include/asm/mmu_context.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/um/include/asm/mmu_context.h b/arch/um/include/asm/mmu_context.h index b668e351fd6c..fca34b2177e2 100644 --- a/arch/um/include/asm/mmu_context.h +++ b/arch/um/include/asm/mmu_context.h | |||
@@ -15,9 +15,10 @@ extern void uml_setup_stubs(struct mm_struct *mm); | |||
15 | /* | 15 | /* |
16 | * Needed since we do not use the asm-generic/mm_hooks.h: | 16 | * Needed since we do not use the asm-generic/mm_hooks.h: |
17 | */ | 17 | */ |
18 | static inline void arch_dup_mmap(struct mm_struct *oldmm, struct mm_struct *mm) | 18 | static inline int arch_dup_mmap(struct mm_struct *oldmm, struct mm_struct *mm) |
19 | { | 19 | { |
20 | uml_setup_stubs(mm); | 20 | uml_setup_stubs(mm); |
21 | return 0; | ||
21 | } | 22 | } |
22 | extern void arch_exit_mmap(struct mm_struct *mm); | 23 | extern void arch_exit_mmap(struct mm_struct *mm); |
23 | static inline void arch_unmap(struct mm_struct *mm, | 24 | static inline void arch_unmap(struct mm_struct *mm, |