]> git.ipfire.org Git - thirdparty/libvirt.git/commit
util: Use default group's mask for unspecified resctrl allocations
authorMartin Kletzander <mkletzan@redhat.com>
Fri, 26 Jan 2018 17:14:49 +0000 (18:14 +0100)
committerMartin Kletzander <mkletzan@redhat.com>
Wed, 31 Jan 2018 13:51:34 +0000 (14:51 +0100)
commitc39ce914dd88c35a66d1088f0688da24fea8cfcd
treebabb88cae6b306202adae5b304f8ec1462484033
parentf6199295a9656a79e29cab9ed5694f040c266998
util: Use default group's mask for unspecified resctrl allocations

Introduce virResctrlAllocCopyMasks() and use that to initially copy the default
group schemata to the allocation before reserving any parts of the cache.  The
reason for this is that when new group is created the schemata will have unknown
data in it.  If there was previously group with the same CLoS ID, it will have
the previous valies, if not it will have all bits set.  And we need to set all
unspecified (in the XML) allocations to the same one as the default group.

Some non-Linux functions now need to be made public due to this change.

Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1289368

Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
src/util/virresctrl.c