
On Thu, Apr 19, 2018 at 15:45:52 +0200, Andrea Bolognani wrote:
On Thu, 2018-04-19 at 14:11 +0200, Peter Krempa wrote:
On Thu, Apr 12, 2018 at 08:47:58 +0200, Andrea Bolognani wrote:
The current private XML parsing code relies on the assumption that NUMA node IDs start from 0 and are densely allocated, neither of which is necessarily the case.
Change it so that the bitmap size is dynamically calculated by looking at NUMA node IDs instead, which ensures all nodes will be able to fit and thus the bitmap will be parsed successfully.
Update one of the test cases so that it would fail with the previous approach, but passes with the new one.
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1490158
While the patch below will fix this case, I'd also like to see that the parsing of the bitmaps is made non-fatal. If the nodesets are missing some of the reported data will be wrong, but not having this is certainly not a deal-breaker so that we should not reconnect to qemu.
Mh, that's trickier than I initially though, because virBitmapParseSeparator() calls virReportError() itself on parse failure, and changing doesn't sound feasible.
I think logging of the error is okay, we just probably should reset it. At any rate this patch can be pushed as-is ... well after it passes build checks ;)