context in the kernel.
Signed-off-by: Marius Hillenbrand
Inspired-by: Julian Stecklina (while jstec...@amazon.de)
Cc: Alexander Graf
Cc: David Woodhouse
---
arch/x86/include/asm/kvm_host.h | 8
arch/x86/kvm/x86.c | 24
2 files changed, 20 insertions
blocks. To
keep the changes minimal, we pass all required state as a pointer to a
single struct in process-local memory, which is hidden from other
processes.
Note that this feature is strictly opt-in. When disabled, the world
switch code remains unchanged.
Signed-off-by: Marius Hillenbrand
Inspired
that the purpose of this patch is to make the
changes in the next commit more readable. we will drop this patch when
rebasing to 5.x, since major refactoring of KVM makes it redundant.]
Signed-off-by: Marius Hillenbrand
Cc: Alexander Graf
Cc: David Woodhouse
---
arch/x86/kvm/vmx.c | 46
dundant.]
Signed-off-by: Marius Hillenbrand
Cc: Alexander Graf
Cc: David Woodhouse
---
arch/x86/kvm/vmx.c | 15 +--
1 file changed, 5 insertions(+), 10 deletions(-)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index 6f59a6ad7835..16a383635b59 100644
--- a/arch/x86/kvm/vmx.c
+++
guest state.
Signed-off-by: Marius Hillenbrand
Cc: Alexander Graf
Cc: David Woodhouse
---
arch/x86/include/asm/kvm_host.h | 9
arch/x86/kvm/Kconfig| 10 +
arch/x86/kvm/svm.c | 37 +++-
arch/x86/kvm/vmx.c | 38
address ranges.
The allocation only handles the smallest page size (i.e., 4 KiB), no
huge pages, because in our use case, the size of individual allocations
is in the order of 4 KiB.
Signed-off-by: Marius Hillenbrand
Cc: Alexander Graf
Cc: David Woodhouse
---
mm/proclocal.c | 167
may point to shared page tables for the kernel space).
Signed-off-by: Marius Hillenbrand
Inspired-by: Julian Stecklina (while jstec...@amazon.de)
Cc: Alexander Graf
Cc: David Woodhouse
---
Documentation/x86/x86_64/mm.txt | 11 +--
arch/x86/Kconfig| 1 +
arch
in debugging (e.g., to see page faults instead of silent invalid
accesses). For that purpose, use a global allocator for virtual address
ranges of process-local mappings. Note that the single centralized lock
is good enough for our use case.
Signed-off-by: Marius Hillenbrand
Cc: Alexander Graf
Cc: David
Process-local memory uses a dedicated pgd entry in kernel space and its
own page table structure. Hook mm exit functions to cleanup those
dedicated page tables. As a preparation, release any left-over
process-local allocations in the address space.
Signed-off-by: Marius Hillenbrand
Cc: Alexander
-by: Marius Hillenbrand
Cc: Alexander Graf
Cc: David Woodhouse
---
arch/x86/mm/kaslr.c | 22 ++
1 file changed, 14 insertions(+), 8 deletions(-)
diff --git a/arch/x86/mm/kaslr.c b/arch/x86/mm/kaslr.c
index 3f452ffed7e9..c455f1ffba29 100644
--- a/arch/x86/mm/kaslr.c
+++ b/arch
evaluation.
Impact on starting VMs was within measurement noise.
---
Julian Stecklina (2):
kvm, vmx: move CR2 context switch out of assembly path
kvm, vmx: move register clearing out of assembly path
Marius Hillenbrand (8):
x86/mm/kaslr: refactor to use enum indices for regions
x86/speculatio
11 matches
Mail list logo