]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/libvirt.git/commitdiff
qemu: fix the error cover issue in SetMemoryParameters
authorLuyao Huang <lhuang@redhat.com>
Wed, 22 Jul 2015 07:35:14 +0000 (15:35 +0800)
committerMartin Kletzander <mkletzan@redhat.com>
Wed, 22 Jul 2015 09:02:17 +0000 (11:02 +0200)
https://bugzilla.redhat.com/show_bug.cgi?id=1245476

We won't return the errno after commit 0d7f45ae, and
the more clearly error will be set in the code in vircgroup*.
Also We will always report error "Operation not permitted",
because the return is -1.

Signed-off-by: Luyao Huang <lhuang@redhat.com>
src/qemu/qemu_driver.c

index 61a7a7cc2c686ba6b4be30a58f44f5c16f42c574..40c882c4ba88ff109b9d09cd6ff594440b8f9d5c 100644 (file)
@@ -9809,12 +9809,8 @@ qemuDomainSetMemoryParameters(virDomainPtr dom,
 #define QEMU_SET_MEM_PARAMETER(FUNC, VALUE)                                     \
     if (set_ ## VALUE) {                                                        \
         if (flags & VIR_DOMAIN_AFFECT_LIVE) {                                   \
-            if ((rc = FUNC(priv->cgroup, VALUE)) < 0) {                         \
-                virReportSystemError(-rc, _("unable to set memory %s tunable"), \
-                                     #VALUE);                                   \
-                                                                                \
-                goto endjob;                                                   \
-            }                                                                   \
+            if ((rc = FUNC(priv->cgroup, VALUE)) < 0)                           \
+                goto endjob;                                                    \
             vm->def->mem.VALUE = VALUE;                                         \
         }                                                                       \
                                                                                 \