diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-16 18:36:00 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-10-16 18:36:00 -0400 |
commit | 08d19f51f05a68ce89a289320ce4ed96e757df72 (patch) | |
tree | 31c5d718d0aeaff5083fe533cd6e1f9fbbe846bb /arch/powerpc/include | |
parent | 1c95e1b69073cff5ff179e592fa1a1e182c78a17 (diff) | |
parent | 2381ad241d0bea1253a37f314b270848067640bb (diff) |
Merge branch 'kvm-updates/2.6.28' of git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm
* 'kvm-updates/2.6.28' of git://git.kernel.org/pub/scm/linux/kernel/git/avi/kvm: (134 commits)
KVM: ia64: Add intel iommu support for guests.
KVM: ia64: add directed mmio range support for kvm guests
KVM: ia64: Make pmt table be able to hold physical mmio entries.
KVM: Move irqchip_in_kernel() from ioapic.h to irq.h
KVM: Separate irq ack notification out of arch/x86/kvm/irq.c
KVM: Change is_mmio_pfn to kvm_is_mmio_pfn, and make it common for all archs
KVM: Move device assignment logic to common code
KVM: Device Assignment: Move vtd.c from arch/x86/kvm/ to virt/kvm/
KVM: VMX: enable invlpg exiting if EPT is disabled
KVM: x86: Silence various LAPIC-related host kernel messages
KVM: Device Assignment: Map mmio pages into VT-d page table
KVM: PIC: enhance IPI avoidance
KVM: MMU: add "oos_shadow" parameter to disable oos
KVM: MMU: speed up mmu_unsync_walk
KVM: MMU: out of sync shadow core
KVM: MMU: mmu_convert_notrap helper
KVM: MMU: awareness of new kvm_mmu_zap_page behaviour
KVM: MMU: mmu_parent_walk
KVM: x86: trap invlpg
KVM: MMU: sync roots on mmu reload
...
Diffstat (limited to 'arch/powerpc/include')
-rw-r--r-- | arch/powerpc/include/asm/kvm_host.h | 14 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kvm_ppc.h | 12 |
2 files changed, 24 insertions, 2 deletions
diff --git a/arch/powerpc/include/asm/kvm_host.h b/arch/powerpc/include/asm/kvm_host.h index 2655e2a4831e..34b52b7180cd 100644 --- a/arch/powerpc/include/asm/kvm_host.h +++ b/arch/powerpc/include/asm/kvm_host.h | |||
@@ -81,11 +81,17 @@ struct kvm_vcpu_arch { | |||
81 | struct tlbe shadow_tlb[PPC44x_TLB_SIZE]; | 81 | struct tlbe shadow_tlb[PPC44x_TLB_SIZE]; |
82 | /* Pages which are referenced in the shadow TLB. */ | 82 | /* Pages which are referenced in the shadow TLB. */ |
83 | struct page *shadow_pages[PPC44x_TLB_SIZE]; | 83 | struct page *shadow_pages[PPC44x_TLB_SIZE]; |
84 | /* Copy of the host's TLB. */ | 84 | |
85 | struct tlbe host_tlb[PPC44x_TLB_SIZE]; | 85 | /* Track which TLB entries we've modified in the current exit. */ |
86 | u8 shadow_tlb_mod[PPC44x_TLB_SIZE]; | ||
86 | 87 | ||
87 | u32 host_stack; | 88 | u32 host_stack; |
88 | u32 host_pid; | 89 | u32 host_pid; |
90 | u32 host_dbcr0; | ||
91 | u32 host_dbcr1; | ||
92 | u32 host_dbcr2; | ||
93 | u32 host_iac[4]; | ||
94 | u32 host_msr; | ||
89 | 95 | ||
90 | u64 fpr[32]; | 96 | u64 fpr[32]; |
91 | u32 gpr[32]; | 97 | u32 gpr[32]; |
@@ -123,7 +129,11 @@ struct kvm_vcpu_arch { | |||
123 | u32 ivor[16]; | 129 | u32 ivor[16]; |
124 | u32 ivpr; | 130 | u32 ivpr; |
125 | u32 pir; | 131 | u32 pir; |
132 | |||
133 | u32 shadow_pid; | ||
126 | u32 pid; | 134 | u32 pid; |
135 | u32 swap_pid; | ||
136 | |||
127 | u32 pvr; | 137 | u32 pvr; |
128 | u32 ccr0; | 138 | u32 ccr0; |
129 | u32 ccr1; | 139 | u32 ccr1; |
diff --git a/arch/powerpc/include/asm/kvm_ppc.h b/arch/powerpc/include/asm/kvm_ppc.h index a8b068792260..8931ba729d2b 100644 --- a/arch/powerpc/include/asm/kvm_ppc.h +++ b/arch/powerpc/include/asm/kvm_ppc.h | |||
@@ -64,6 +64,10 @@ extern void kvmppc_mmu_map(struct kvm_vcpu *vcpu, u64 gvaddr, gfn_t gfn, | |||
64 | extern void kvmppc_mmu_invalidate(struct kvm_vcpu *vcpu, gva_t eaddr, | 64 | extern void kvmppc_mmu_invalidate(struct kvm_vcpu *vcpu, gva_t eaddr, |
65 | gva_t eend, u32 asid); | 65 | gva_t eend, u32 asid); |
66 | extern void kvmppc_mmu_priv_switch(struct kvm_vcpu *vcpu, int usermode); | 66 | extern void kvmppc_mmu_priv_switch(struct kvm_vcpu *vcpu, int usermode); |
67 | extern void kvmppc_mmu_switch_pid(struct kvm_vcpu *vcpu, u32 pid); | ||
68 | |||
69 | /* XXX Book E specific */ | ||
70 | extern void kvmppc_tlbe_set_modified(struct kvm_vcpu *vcpu, unsigned int i); | ||
67 | 71 | ||
68 | extern void kvmppc_check_and_deliver_interrupts(struct kvm_vcpu *vcpu); | 72 | extern void kvmppc_check_and_deliver_interrupts(struct kvm_vcpu *vcpu); |
69 | 73 | ||
@@ -92,4 +96,12 @@ static inline void kvmppc_set_msr(struct kvm_vcpu *vcpu, u32 new_msr) | |||
92 | kvm_vcpu_block(vcpu); | 96 | kvm_vcpu_block(vcpu); |
93 | } | 97 | } |
94 | 98 | ||
99 | static inline void kvmppc_set_pid(struct kvm_vcpu *vcpu, u32 new_pid) | ||
100 | { | ||
101 | if (vcpu->arch.pid != new_pid) { | ||
102 | vcpu->arch.pid = new_pid; | ||
103 | vcpu->arch.swap_pid = 1; | ||
104 | } | ||
105 | } | ||
106 | |||
95 | #endif /* __POWERPC_KVM_PPC_H__ */ | 107 | #endif /* __POWERPC_KVM_PPC_H__ */ |