Skip to content

Commit 344315e

Browse files
committed
KVM: x86: Drop double-underscores from __kvm_set_memory_region()
Now that there's no outer wrapper for __kvm_set_memory_region() and it's static, drop its double-underscore prefix. No functional change intended. Cc: Tao Su <tao1.su@linux.intel.com> Reviewed-by: Xiaoyao Li <xiaoyao.li@intel.com> Reviewed-by: Claudio Imbrenda <imbrenda@linux.ibm.com> Acked-by: Christoph Schlameuss <schlameuss@linux.ibm.com> Link: https://lore.kernel.org/r/20250111002022.1230573-5-seanjc@google.com Signed-off-by: Sean Christopherson <seanjc@google.com>
1 parent 156bffd commit 344315e

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

arch/x86/kvm/x86.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12928,7 +12928,7 @@ static int kvm_alloc_memslot_metadata(struct kvm *kvm,
1292812928

1292912929
/*
1293012930
* Clear out the previous array pointers for the KVM_MR_MOVE case. The
12931-
* old arrays will be freed by __kvm_set_memory_region() if installing
12931+
* old arrays will be freed by kvm_set_memory_region() if installing
1293212932
* the new memslot is successful.
1293312933
*/
1293412934
memset(&slot->arch, 0, sizeof(slot->arch));

include/linux/kvm_host.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1183,7 +1183,7 @@ struct kvm_memory_slot *kvm_vcpu_gfn_to_memslot(struct kvm_vcpu *vcpu, gfn_t gfn
11831183
* -- just change its flags
11841184
*
11851185
* Since flags can be changed by some of these operations, the following
1186-
* differentiation is the best we can do for __kvm_set_memory_region():
1186+
* differentiation is the best we can do for kvm_set_memory_region():
11871187
*/
11881188
enum kvm_mr_change {
11891189
KVM_MR_CREATE,

virt/kvm/kvm_main.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1926,8 +1926,8 @@ static bool kvm_check_memslot_overlap(struct kvm_memslots *slots, int id,
19261926
return false;
19271927
}
19281928

1929-
static int __kvm_set_memory_region(struct kvm *kvm,
1930-
const struct kvm_userspace_memory_region2 *mem)
1929+
static int kvm_set_memory_region(struct kvm *kvm,
1930+
const struct kvm_userspace_memory_region2 *mem)
19311931
{
19321932
struct kvm_memory_slot *old, *new;
19331933
struct kvm_memslots *slots;
@@ -2057,7 +2057,7 @@ int kvm_set_internal_memslot(struct kvm *kvm,
20572057
if (WARN_ON_ONCE(mem->slot < KVM_USER_MEM_SLOTS))
20582058
return -EINVAL;
20592059

2060-
return __kvm_set_memory_region(kvm, mem);
2060+
return kvm_set_memory_region(kvm, mem);
20612061
}
20622062
EXPORT_SYMBOL_GPL(kvm_set_internal_memslot);
20632063

@@ -2068,7 +2068,7 @@ static int kvm_vm_ioctl_set_memory_region(struct kvm *kvm,
20682068
return -EINVAL;
20692069

20702070
guard(mutex)(&kvm->slots_lock);
2071-
return __kvm_set_memory_region(kvm, mem);
2071+
return kvm_set_memory_region(kvm, mem);
20722072
}
20732073

20742074
#ifndef CONFIG_KVM_GENERIC_DIRTYLOG_READ_PROTECT

0 commit comments

Comments
 (0)