From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:58331) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RYyxZ-0004eU-2j for qemu-devel@nongnu.org; Fri, 09 Dec 2011 06:49:50 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RYyxY-0008UV-0j for qemu-devel@nongnu.org; Fri, 09 Dec 2011 06:49:49 -0500 Received: from mx1.redhat.com ([209.132.183.28]:56332) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RYyxX-0008UO-P7 for qemu-devel@nongnu.org; Fri, 09 Dec 2011 06:49:47 -0500 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id pB9BnkjX005456 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 9 Dec 2011 06:49:46 -0500 From: Amit Shah Date: Fri, 9 Dec 2011 17:19:35 +0530 Message-Id: Subject: [Qemu-devel] [PATCH 0/3] balloon: error if guest driver is not initialised List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu list Cc: Amit Shah , Markus Armbruster , Luiz Capitulino Hello, These patches make qemu generate an error on failure in setting a balloon value: (qemu) balloon 400 Device 'balloon' has not been activated This can happen when the guest hasn't yet loaded a balloon driver. Previously, such a ballooning attempt didn't produce an error, but the virtio-balloon driver remembered the value nevertheless, causing a module load in the guest using the attempted balloon value originally. This may not be the desired course of action. I've re-used the QERR_DEVICE_NOT_ACTIVE error message, I think it fits in this case too. If not, let me know and I'll change it to something else. Please review and apply. Amit Shah (3): balloon: Make functions return 0 on OK, -1 on error. balloon: report error if ballooning operation fails virtio-balloon: report error if balloon driver in guest not available balloon.c | 19 ++++++++++++------- balloon.h | 2 +- hw/virtio-balloon.c | 6 +++++- 3 files changed, 18 insertions(+), 9 deletions(-) -- 1.7.7.3