Re: [PATCH] kvm tools: Limit CPU count by KVM_CAP_NR_VCPUS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



* Pekka Enberg <penberg@xxxxxxxxxx> wrote:

> +int kvm__max_cpus(struct kvm *self)
> +{
> +	int ret;
> +
> +	ret = ioctl(self->sys_fd, KVM_CHECK_EXTENSION, KVM_CAP_NR_VCPUS);
> +	if (ret < 0)
> +		die_perror("KVM_CAP_NR_VCPUS");
> +
> +	return ret;
> +}

I double checked, and KVM_CAP_NR_VCPUS was available even with the very first 
KVM version, so this should work on all KVM versions, old and new alike.

Thanks,

	Ingo
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux