The original code was incorrect and never tested because at the time of
implementing it the cgroup file `io.weight` was not available.
Resolves: https://issues.redhat.com/browse/RHEL-45185
Introduced-by: 9c1693eff427661616ce1bd2795688f87288a412
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Jiri Denemark <jdenemar@redhat.com>
if (group->unitName) {
GVariant *value = NULL;
- value = g_variant_new_parsed("[(%s, uint64 %u)]", path, weight);
+ value = g_variant_new_parsed("[(%s, %t)]", path, weight);
return virCgroupSetValueDBus(group->unitName, "BlockIODeviceWeight", value);
} else {
if (group->unitName) {
GVariant *value = NULL;
- value = g_variant_new_parsed("[(%s, uint64 %u)]", path, weight);
+ value = g_variant_new_parsed("[(%s, %t)]", path, weight);
return virCgroupSetValueDBus(group->unitName, "IODeviceWeight", value);
} else {