diff options
author | Alexander Graf <agraf@suse.de> | 2010-06-21 09:25:40 -0400 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2010-08-01 03:47:12 -0400 |
commit | a576f7a29481438db0fa6f3d9ed6939019c441d3 (patch) | |
tree | 22134adb19a1f5ba4f3a06e934384e4a0c1c0f21 /arch/powerpc/kvm | |
parent | bbeb34062fbad287c949a945a516a0c15b179993 (diff) |
KVM: PPC: Remove obsolete kvmppc_mmu_find_pte
Initially we had to search for pte entries to invalidate them. Since
the logic has improved since then, we can just get rid of the search
function.
Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/powerpc/kvm')
-rw-r--r-- | arch/powerpc/kvm/book3s_32_mmu_host.c | 20 | ||||
-rw-r--r-- | arch/powerpc/kvm/book3s_64_mmu_host.c | 20 |
2 files changed, 0 insertions, 40 deletions
diff --git a/arch/powerpc/kvm/book3s_32_mmu_host.c b/arch/powerpc/kvm/book3s_32_mmu_host.c index 0bb66005338f..81ca9dba4098 100644 --- a/arch/powerpc/kvm/book3s_32_mmu_host.c +++ b/arch/powerpc/kvm/book3s_32_mmu_host.c | |||
@@ -150,26 +150,6 @@ void kvmppc_mmu_pte_pflush(struct kvm_vcpu *vcpu, ulong pa_start, ulong pa_end) | |||
150 | } | 150 | } |
151 | } | 151 | } |
152 | 152 | ||
153 | struct kvmppc_pte *kvmppc_mmu_find_pte(struct kvm_vcpu *vcpu, u64 ea, bool data) | ||
154 | { | ||
155 | int i; | ||
156 | u64 guest_vp; | ||
157 | |||
158 | guest_vp = vcpu->arch.mmu.ea_to_vp(vcpu, ea, false); | ||
159 | for (i=0; i<vcpu->arch.hpte_cache_offset; i++) { | ||
160 | struct hpte_cache *pte; | ||
161 | |||
162 | pte = &vcpu->arch.hpte_cache[i]; | ||
163 | if (!pte->host_va) | ||
164 | continue; | ||
165 | |||
166 | if (pte->pte.vpage == guest_vp) | ||
167 | return &pte->pte; | ||
168 | } | ||
169 | |||
170 | return NULL; | ||
171 | } | ||
172 | |||
173 | static int kvmppc_mmu_hpte_cache_next(struct kvm_vcpu *vcpu) | 153 | static int kvmppc_mmu_hpte_cache_next(struct kvm_vcpu *vcpu) |
174 | { | 154 | { |
175 | if (vcpu->arch.hpte_cache_offset == HPTEG_CACHE_NUM) | 155 | if (vcpu->arch.hpte_cache_offset == HPTEG_CACHE_NUM) |
diff --git a/arch/powerpc/kvm/book3s_64_mmu_host.c b/arch/powerpc/kvm/book3s_64_mmu_host.c index e4b5744977f6..eb1d26b64714 100644 --- a/arch/powerpc/kvm/book3s_64_mmu_host.c +++ b/arch/powerpc/kvm/book3s_64_mmu_host.c | |||
@@ -132,26 +132,6 @@ void kvmppc_mmu_pte_pflush(struct kvm_vcpu *vcpu, ulong pa_start, ulong pa_end) | |||
132 | } | 132 | } |
133 | } | 133 | } |
134 | 134 | ||
135 | struct kvmppc_pte *kvmppc_mmu_find_pte(struct kvm_vcpu *vcpu, u64 ea, bool data) | ||
136 | { | ||
137 | int i; | ||
138 | u64 guest_vp; | ||
139 | |||
140 | guest_vp = vcpu->arch.mmu.ea_to_vp(vcpu, ea, false); | ||
141 | for (i=0; i<vcpu->arch.hpte_cache_offset; i++) { | ||
142 | struct hpte_cache *pte; | ||
143 | |||
144 | pte = &vcpu->arch.hpte_cache[i]; | ||
145 | if (!pte->host_va) | ||
146 | continue; | ||
147 | |||
148 | if (pte->pte.vpage == guest_vp) | ||
149 | return &pte->pte; | ||
150 | } | ||
151 | |||
152 | return NULL; | ||
153 | } | ||
154 | |||
155 | static int kvmppc_mmu_hpte_cache_next(struct kvm_vcpu *vcpu) | 135 | static int kvmppc_mmu_hpte_cache_next(struct kvm_vcpu *vcpu) |
156 | { | 136 | { |
157 | if (vcpu->arch.hpte_cache_offset == HPTEG_CACHE_NUM) | 137 | if (vcpu->arch.hpte_cache_offset == HPTEG_CACHE_NUM) |