Commit 96f113c4 authored by Sean Christopherson's avatar Sean Christopherson Committed by Paolo Bonzini

KVM: selftests: Drop a duplicate TEST_ASSERT() in vm_nr_pages_required()

Remove a duplicate TEST_ASSERT() on the number of runnable vCPUs in
vm_nr_pages_required() that snuck in during a rebase gone bad.
Reported-by: default avatarAndrew Jones <drjones@redhat.com>
Fixes: 6e1d13bf ("KVM: selftests: Move per-VM/per-vCPU nr pages calculation to __vm_create()")
Signed-off-by: default avatarSean Christopherson <seanjc@google.com>
Message-Id: <20220613161942.1586791-4-seanjc@google.com>
Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
parent ad125f30
...@@ -284,10 +284,6 @@ static uint64_t vm_nr_pages_required(enum vm_guest_mode mode, ...@@ -284,10 +284,6 @@ static uint64_t vm_nr_pages_required(enum vm_guest_mode mode,
*/ */
nr_pages += (nr_pages + extra_mem_pages) / PTES_PER_MIN_PAGE * 2; nr_pages += (nr_pages + extra_mem_pages) / PTES_PER_MIN_PAGE * 2;
TEST_ASSERT(nr_runnable_vcpus <= kvm_check_cap(KVM_CAP_MAX_VCPUS),
"Host doesn't support %d vCPUs, max-vcpus = %d",
nr_runnable_vcpus, kvm_check_cap(KVM_CAP_MAX_VCPUS));
return vm_adjust_num_guest_pages(mode, nr_pages); return vm_adjust_num_guest_pages(mode, nr_pages);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment