Skip to content

Commit e0a99a2

Browse files
Fuad TabbaMarc Zyngier
authored andcommitted
KVM: selftests: Fix typos and stale comments in kvm_util
Fix minor documentation errors in `kvm_util.h` and `kvm_util.c`. - Correct the argument description for `vcpu_args_set` in `kvm_util.h`, which incorrectly listed `vm` instead of `vcpu`. - Fix a typo in the comment for `kvm_selftest_arch_init` ("exeucting" -> "executing"). - Correct the return value description for `vm_vaddr_unused_gap` in `kvm_util.c` to match the implementation, which returns an address "at or above" `vaddr_min`, not "at or below". No functional change intended. Reviewed-by: Andrew Jones <andrew.jones@linux.dev> Signed-off-by: Fuad Tabba <tabba@google.com> Link: https://patch.msgid.link/20260109082218.3236580-6-tabba@google.com Signed-off-by: Marc Zyngier <maz@kernel.org>
1 parent de00d07 commit e0a99a2

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

tools/testing/selftests/kvm/include/kvm_util.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -939,7 +939,7 @@ void *vcpu_map_dirty_ring(struct kvm_vcpu *vcpu);
939939
* VM VCPU Args Set
940940
*
941941
* Input Args:
942-
* vm - Virtual Machine
942+
* vcpu - vCPU
943943
* num - number of arguments
944944
* ... - arguments, each of type uint64_t
945945
*
@@ -1264,7 +1264,7 @@ static inline uint64_t vm_page_align(struct kvm_vm *vm, uint64_t v)
12641264
}
12651265

12661266
/*
1267-
* Arch hook that is invoked via a constructor, i.e. before exeucting main(),
1267+
* Arch hook that is invoked via a constructor, i.e. before executing main(),
12681268
* to allow for arch-specific setup that is common to all tests, e.g. computing
12691269
* the default guest "mode".
12701270
*/

tools/testing/selftests/kvm/lib/kvm_util.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1351,7 +1351,7 @@ struct kvm_vcpu *__vm_vcpu_add(struct kvm_vm *vm, uint32_t vcpu_id)
13511351
* Output Args: None
13521352
*
13531353
* Return:
1354-
* Lowest virtual address at or below vaddr_min, with at least
1354+
* Lowest virtual address at or above vaddr_min, with at least
13551355
* sz unused bytes. TEST_ASSERT failure if no area of at least
13561356
* size sz is available.
13571357
*

0 commit comments

Comments
 (0)