aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Hogan <james.hogan@imgtec.com>2015-04-27 10:07:16 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-07-10 12:49:36 -0400
commit4f3d3bc20372afb29708307608946e2bb56a5a64 (patch)
treef231bd6ef803d60d95ecbdb1fdfc1a6ba5d8f993
parentdff1316f4f15d9c3ff3ff9c11f2c92e0a2040a49 (diff)
MIPS: Fix KVM guest fixmap address
commit 8e748c8d09a9314eedb5c6367d9acfaacddcdc88 upstream. KVM guest kernels for trap & emulate run in user mode, with a modified set of kernel memory segments. However the fixmap address is still in the normal KSeg3 region at 0xfffe0000 regardless, causing problems when cache alias handling makes use of them when handling copy on write. Therefore define FIXADDR_TOP as 0x7ffe0000 in the guest kernel mapped region when CONFIG_KVM_GUEST is defined. Signed-off-by: James Hogan <james.hogan@imgtec.com> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/9887/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--arch/mips/include/asm/mach-generic/spaces.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/mips/include/asm/mach-generic/spaces.h b/arch/mips/include/asm/mach-generic/spaces.h
index 9488fa5f8866..afc96ecb9004 100644
--- a/arch/mips/include/asm/mach-generic/spaces.h
+++ b/arch/mips/include/asm/mach-generic/spaces.h
@@ -94,7 +94,11 @@
94#endif 94#endif
95 95
96#ifndef FIXADDR_TOP 96#ifndef FIXADDR_TOP
97#ifdef CONFIG_KVM_GUEST
98#define FIXADDR_TOP ((unsigned long)(long)(int)0x7ffe0000)
99#else
97#define FIXADDR_TOP ((unsigned long)(long)(int)0xfffe0000) 100#define FIXADDR_TOP ((unsigned long)(long)(int)0xfffe0000)
98#endif 101#endif
102#endif
99 103
100#endif /* __ASM_MACH_GENERIC_SPACES_H */ 104#endif /* __ASM_MACH_GENERIC_SPACES_H */