On 07/02/2015 04:30 AM, Michal Privoznik wrote: > Some drivers don't expose available huge page sizes in the > capabilities XML. For instance, LXC driver is one of those. > This has a downside that when virsh is trying to get > aggregated info on free pages per all NUMA nodes, it fails. > The problem is that the virNodeGetFreePages() API expects > caller to pass an array of page sizes he is interested in. > In virsh, this array is filled from the capabilities from > '/capabilities/host/cpu/pages' XPath. As said, in LXC > there's no such XPath and therefore virsh fails currently. > But hey, we can fallback: the page sizes are exposed under > '/capabilities/host/topology/cells/cell/pages'. The page > size can be collected from there, and voilà the command > works again. But now we must make sure that there are no > duplicates in the array passed to the public API. Otherwise > we won't get as beautiful output as we are getting now. > > Signed-off-by: Michal Privoznik <mprivozn@xxxxxxxxxx> > --- > tools/virsh-host.c | 37 ++++++++++++++++++++++++++++++++++--- > 1 file changed, 34 insertions(+), 3 deletions(-) > Seems reasonable... ACK John -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list