Skip to content

Commit bc07eea

Browse files
Dr. David Alan Gilbertbonzini
authored andcommitted
KVM: Remove unused kvm_vcpu_gfn_to_pfn_atomic
The last use of kvm_vcpu_gfn_to_pfn_atomic was removed by commit 1bbc60d ("KVM: x86/mmu: Remove MMU auditing") Remove it. Signed-off-by: Dr. David Alan Gilbert <[email protected]> Message-ID: <[email protected]> [Adjust Documentation/virt/kvm/locking.rst. - Paolo] Signed-off-by: Paolo Bonzini <[email protected]>
1 parent 88a387c commit bc07eea

File tree

3 files changed

+1
-8
lines changed

3 files changed

+1
-8
lines changed

Documentation/virt/kvm/locking.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ For direct sp, we can easily avoid it since the spte of direct sp is fixed
136136
to gfn. For indirect sp, we disabled fast page fault for simplicity.
137137

138138
A solution for indirect sp could be to pin the gfn, for example via
139-
kvm_vcpu_gfn_to_pfn_atomic, before the cmpxchg. After the pinning:
139+
gfn_to_pfn_memslot_atomic, before the cmpxchg. After the pinning:
140140

141141
- We have held the refcount of pfn; that means the pfn can not be freed and
142142
be reused for another gfn.

include/linux/kvm_host.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1313,7 +1313,6 @@ void mark_page_dirty(struct kvm *kvm, gfn_t gfn);
13131313

13141314
struct kvm_memslots *kvm_vcpu_memslots(struct kvm_vcpu *vcpu);
13151315
struct kvm_memory_slot *kvm_vcpu_gfn_to_memslot(struct kvm_vcpu *vcpu, gfn_t gfn);
1316-
kvm_pfn_t kvm_vcpu_gfn_to_pfn_atomic(struct kvm_vcpu *vcpu, gfn_t gfn);
13171316
int kvm_vcpu_map(struct kvm_vcpu *vcpu, gpa_t gpa, struct kvm_host_map *map);
13181317
void kvm_vcpu_unmap(struct kvm_vcpu *vcpu, struct kvm_host_map *map, bool dirty);
13191318
unsigned long kvm_vcpu_gfn_to_hva(struct kvm_vcpu *vcpu, gfn_t gfn);

virt/kvm/kvm_main.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3035,12 +3035,6 @@ kvm_pfn_t gfn_to_pfn_memslot_atomic(const struct kvm_memory_slot *slot, gfn_t gf
30353035
}
30363036
EXPORT_SYMBOL_GPL(gfn_to_pfn_memslot_atomic);
30373037

3038-
kvm_pfn_t kvm_vcpu_gfn_to_pfn_atomic(struct kvm_vcpu *vcpu, gfn_t gfn)
3039-
{
3040-
return gfn_to_pfn_memslot_atomic(kvm_vcpu_gfn_to_memslot(vcpu, gfn), gfn);
3041-
}
3042-
EXPORT_SYMBOL_GPL(kvm_vcpu_gfn_to_pfn_atomic);
3043-
30443038
kvm_pfn_t gfn_to_pfn(struct kvm *kvm, gfn_t gfn)
30453039
{
30463040
return gfn_to_pfn_memslot(gfn_to_memslot(kvm, gfn), gfn);

0 commit comments

Comments
 (0)