diff options
author | Avi Kivity <avi@qumranet.com> | 2007-01-05 19:36:51 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.osdl.org> | 2007-01-06 02:55:26 -0500 |
commit | 3bb65a22a4502067f8cd3cb4c923ffa70be62091 (patch) | |
tree | b8ee904c9a4b99f0c8f58e93b257f653222e3ba0 /drivers/kvm/kvm.h | |
parent | 86a5ba025d0a0b251817d0efbeaf7037d4175d21 (diff) |
[PATCH] KVM: MMU: Never free a shadow page actively serving as a root
We always need cr3 to point to something valid, so if we detect that we're
freeing a root page, simply push it back to the top of the active list.
Signed-off-by: Avi Kivity <avi@qumranet.com>
Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/kvm/kvm.h')
-rw-r--r-- | drivers/kvm/kvm.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/kvm/kvm.h b/drivers/kvm/kvm.h index 201b2735ca91..b24a86e1f434 100644 --- a/drivers/kvm/kvm.h +++ b/drivers/kvm/kvm.h | |||
@@ -134,6 +134,7 @@ struct kvm_mmu_page { | |||
134 | */ | 134 | */ |
135 | int global; /* Set if all ptes in this page are global */ | 135 | int global; /* Set if all ptes in this page are global */ |
136 | int multimapped; /* More than one parent_pte? */ | 136 | int multimapped; /* More than one parent_pte? */ |
137 | int root_count; /* Currently serving as active root */ | ||
137 | union { | 138 | union { |
138 | u64 *parent_pte; /* !multimapped */ | 139 | u64 *parent_pte; /* !multimapped */ |
139 | struct hlist_head parent_ptes; /* multimapped, kvm_pte_chain */ | 140 | struct hlist_head parent_ptes; /* multimapped, kvm_pte_chain */ |