From patchwork Mon Dec 7 20:37:04 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Markus Armbruster X-Patchwork-Id: 40537 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 6892AB6F07 for ; Tue, 8 Dec 2009 08:16:29 +1100 (EST) Received: from localhost ([127.0.0.1]:58667 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NHkwU-0005c6-Cj for incoming@patchwork.ozlabs.org; Mon, 07 Dec 2009 16:16:26 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NHkKt-00031r-P8 for qemu-devel@nongnu.org; Mon, 07 Dec 2009 15:37:39 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NHkKk-0002wS-Br for qemu-devel@nongnu.org; Mon, 07 Dec 2009 15:37:31 -0500 Received: from [199.232.76.173] (port=46524 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NHkKk-0002w0-1a for qemu-devel@nongnu.org; Mon, 07 Dec 2009 15:37:26 -0500 Received: from oxygen.pond.sub.org ([213.239.205.148]:47573) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NHkKf-0001S4-Da for qemu-devel@nongnu.org; Mon, 07 Dec 2009 15:37:22 -0500 Received: from crossbow.pond.sub.org (pD9E38C82.dip.t-dialin.net [217.227.140.130]) by oxygen.pond.sub.org (Postfix) with ESMTPA id 3D5A3276D58 for ; Mon, 7 Dec 2009 21:37:18 +0100 (CET) Received: by crossbow.pond.sub.org (Postfix, from userid 500) id E1F6120BE7; Mon, 7 Dec 2009 21:37:16 +0100 (CET) From: Markus Armbruster To: qemu-devel@nongnu.org Date: Mon, 7 Dec 2009 21:37:04 +0100 Message-Id: <1260218236-22143-7-git-send-email-armbru@redhat.com> X-Mailer: git-send-email 1.6.2.5 In-Reply-To: <1260218236-22143-1-git-send-email-armbru@redhat.com> References: <1260218236-22143-1-git-send-email-armbru@redhat.com> X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Cc: lcapitulino@redhat.com Subject: [Qemu-devel] [FOR 0.12 PATCH 06/18] QError: New QERR_DEVICE_NOT_REMOVABLE X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Signed-off-by: Markus Armbruster --- qerror.c | 4 ++++ qerror.h | 3 +++ 2 files changed, 7 insertions(+), 0 deletions(-) diff --git a/qerror.c b/qerror.c index 37e8072..17532b0 100644 --- a/qerror.c +++ b/qerror.c @@ -61,6 +61,10 @@ static const QErrorStringTable qerror_table[] = { .desc = "The %(device) device has not been found", }, { + .error_fmt = QERR_DEVICE_NOT_REMOVABLE, + .desc = "Device %(device) is not removable", + }, + { .error_fmt = QERR_INVALID_PARAMETER_TYPE, .desc = "Invalid parameter type, expected: %(expected)", }, diff --git a/qerror.h b/qerror.h index be6cd68..2abff1e 100644 --- a/qerror.h +++ b/qerror.h @@ -53,6 +53,9 @@ QError *qobject_to_qerror(const QObject *obj); #define QERR_DEVICE_NOT_FOUND \ "{ 'class': 'DeviceNotFound', 'data': { 'device': %s } }" +#define QERR_DEVICE_NOT_REMOVABLE \ + "{ 'class': 'DeviceNotRemovable', 'data': { 'device': %s } }" + #define QERR_INVALID_PARAMETER_TYPE \ "{ 'class': 'InvalidParameterType', 'data': { 'name': %s,'expected': %s } }"