From 9d041559d1e74855f6a6ff959eca2cf56fb04936 Mon Sep 17 00:00:00 2001 Message-Id: <9d041559d1e74855f6a6ff959eca2cf56fb04936.1367947969.git.minovotn@redhat.com> In-Reply-To: <707b9b97153063374d2530e72c49b1499fc21af9.1367947969.git.minovotn@redhat.com> References: <707b9b97153063374d2530e72c49b1499fc21af9.1367947969.git.minovotn@redhat.com> From: Michal Novotny Date: Tue, 7 May 2013 18:36:36 +0200 Subject: [PATCH 015/114] Revert "qga: implement qmp_guest_set_vcpus() for Linux with sysfs" This reverts commit 4241c895e33f85424df06cadfa37b337a244a09b. Reverting as asked by Laszlo in message <51892739.2030807@redhat.com> because of the ordering issue (most likely) related to supersed testing. Signed-off-by: Michal Novotny --- qga/commands-posix.c | 38 ++++++-------------------------------- 1 file changed, 6 insertions(+), 32 deletions(-) diff --git a/qga/commands-posix.c b/qga/commands-posix.c index b252402..2045bef 100644 --- a/qga/commands-posix.c +++ b/qga/commands-posix.c @@ -1244,32 +1244,6 @@ GuestLogicalProcessorList *qmp_guest_get_vcpus(Error **errp) return NULL; } -int64_t qmp_guest_set_vcpus(GuestLogicalProcessorList *vcpus, Error **errp) -{ - int64_t processed; - Error *local_err = NULL; - - processed = 0; - while (vcpus != NULL) { - transfer_vcpu(vcpus->value, false, &local_err); - if (local_err != NULL) { - break; - } - ++processed; - vcpus = vcpus->next; - } - - if (local_err != NULL) { - if (processed == 0) { - error_propagate(errp, local_err); - } else { - error_free(local_err); - } - } - - return processed; -} - #else /* defined(__linux__) */ void qmp_guest_suspend_disk(Error **err) @@ -1299,12 +1273,6 @@ GuestLogicalProcessorList *qmp_guest_get_vcpus(Error **errp) return NULL; } -int64_t qmp_guest_set_vcpus(GuestLogicalProcessorList *vcpus, Error **errp) -{ - error_set(errp, QERR_UNSUPPORTED); - return -1; -} - #endif #if !defined(CONFIG_FSFREEZE) @@ -1338,6 +1306,12 @@ void qmp_guest_fstrim(bool has_minimum, int64_t minimum, Error **err) } #endif +int64_t qmp_guest_set_vcpus(GuestLogicalProcessorList *vcpus, Error **errp) +{ + error_set(errp, QERR_UNSUPPORTED); + return -1; +} + /* register init/cleanup routines for stateful command groups */ void ga_command_state_init(GAState *s, GACommandState *cs) { -- 1.7.11.7