Searched refs:max_mem_slots (Results 1 – 2 of 2) sorted by relevance
/linux/tools/testing/selftests/kvm/ |
H A D | set_memory_region_test.c | 413 uint32_t max_mem_slots; in test_add_max_memory_regions() local 425 max_mem_slots = kvm_check_cap(KVM_CAP_NR_MEMSLOTS); in test_add_max_memory_regions() 426 TEST_ASSERT(max_mem_slots > 0, in test_add_max_memory_regions() 428 pr_info("Allowed number of memory slots: %i\n", max_mem_slots); in test_add_max_memory_regions() 434 (max_mem_slots - 1), MEM_REGION_SIZE >> 10); in test_add_max_memory_regions() 436 mem = mmap(NULL, (size_t)max_mem_slots * MEM_REGION_SIZE + alignment, in test_add_max_memory_regions() 442 for (slot = 0; slot < max_mem_slots; slot++) in test_add_max_memory_regions() 453 ret = __vm_set_user_memory_region(vm, max_mem_slots, 0, in test_add_max_memory_regions() 454 (uint64_t)max_mem_slots * MEM_REGION_SIZE, in test_add_max_memory_regions() 459 munmap(mem, (size_t)max_mem_slots * MEM_REGION_SIZE + alignment); in test_add_max_memory_regions()
|
H A D | memslot_perf_test.c | 963 uint32_t max_mem_slots; in parse_args() 1022 max_mem_slots = kvm_check_cap(KVM_CAP_NR_MEMSLOTS); in parse_args() 1023 if (max_mem_slots <= 1) { in parse_args() 1030 targs->nslots = max_mem_slots - 1; in parse_args() 1032 targs->nslots = min_t(int, targs->nslots, max_mem_slots) - 1; in parse_args() 959 uint32_t max_mem_slots; parse_args() local
|