On 10/08/2013 02:38 AM, Chen Hanxiao wrote:
From: Chen Hanxiao <chenhanxiao(a)cn.fujitsu.com>
kernel had changed the minimum weight of device blkio from
100 to 10 in commit df457f845e5449be2e7d96668791f789b3770ac7.
So we should to use new blkio weight range after 2.6.39.
Why not do it unconditionally, and then just have graceful error
detection when on older kernels when the input is rejected by the kernel
as out of range? That would be feature-based instead of version-check
based, which makes it more reliable even if the feature of the kernel is
backported to something that uname reports as having an older version
number.
libvirt should follow kernel according to
kernel version.
Signed-off-by: Gao feng <gaofeng(a)cn.fujitsu.com>
Signed-off-by: Chen Hanxiao <chenhanxiao(a)cn.fujitsu.com>
---
src/util/vircgroup.c | 44 +++++++++++++++++++++++++++++++++-----------
1 file changed, 33 insertions(+), 11 deletions(-)
Incomplete. You also need to touch virsh.pod and probably
formatdomain.html.in to document the larger range, and mention that
different connections may have different ranges (due to different kernel
versions on the other ends of those two connections).
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library
http://libvirt.org