[libvirt] [PATCH V3 1/2] util: Allow to query the presence of host CPU bitmaps

John Ferlan jferlan at redhat.com
Tue Dec 13 23:27:41 UTC 2016



On 11/25/2016 08:57 AM, Viktor Mihajlovski wrote:
> The functions to retrieve online and present host CPU information
> are only supported on Linux for the time being.
> 
> This leads to runtime errors if these function are used on other
> platforms. To avoid that, code in higher levels using the functions
> must replicate the conditional compilation in higher level which
> is error prone (and is plainly spoken ugly).
> 
> Adding a function virHostCPUHasBitmap that can be used to check
> for host CPU bitmap support.
> 
> NB: There are other functions including the host CPU count that
> are lacking support on all platforms, but they are too essential
> in order to be bypassed.
> 
> Signed-off-by: Viktor Mihajlovski <mihajlov at linux.vnet.ibm.com>
> ---
>  src/libvirt_private.syms |  1 +
>  src/util/virhostcpu.c    | 10 ++++++++++
>  src/util/virhostcpu.h    |  1 +
>  3 files changed, 12 insertions(+)
> 

ACK

John




More information about the libvir-list mailing list