From patchwork Mon Apr 5 20:33:56 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luiz Capitulino X-Patchwork-Id: 49455 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 0381FB7D13 for ; Tue, 6 Apr 2010 08:07:09 +1000 (EST) Received: from localhost ([127.0.0.1]:39386 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NytFC-0005L6-Eq for incoming@patchwork.ozlabs.org; Mon, 05 Apr 2010 16:50:02 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Nyt1b-0001rV-Jd for qemu-devel@nongnu.org; Mon, 05 Apr 2010 16:35:59 -0400 Received: from [140.186.70.92] (port=49520 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Nyt1Y-0001ZR-Lh for qemu-devel@nongnu.org; Mon, 05 Apr 2010 16:35:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Nyt0S-0001eG-NS for qemu-devel@nongnu.org; Mon, 05 Apr 2010 16:34:51 -0400 Received: from mx1.redhat.com ([209.132.183.28]:17517) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nyt0S-0001eA-FB for qemu-devel@nongnu.org; Mon, 05 Apr 2010 16:34:48 -0400 Received: from int-mx05.intmail.prod.int.phx2.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.18]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o35KYl71029974 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 5 Apr 2010 16:34:47 -0400 Received: from localhost (vpn-8-191.rdu.redhat.com [10.11.8.191]) by int-mx05.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o35KYjQW001619; Mon, 5 Apr 2010 16:34:46 -0400 From: Luiz Capitulino To: aliguori@us.ibm.com Date: Mon, 5 Apr 2010 17:33:56 -0300 Message-Id: <1270499642-31543-16-git-send-email-lcapitulino@redhat.com> In-Reply-To: <1270499642-31543-1-git-send-email-lcapitulino@redhat.com> References: <1270499642-31543-1-git-send-email-lcapitulino@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.18 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. Cc: Luiz Capitulino , qemu-devel@nongnu.org, Markus Armbruster Subject: [Qemu-devel] [PATCH 15/21] monitor: Rename argument type 'b' to 'f' 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 From: Markus Armbruster To make 'b' available for boolean argument. Signed-off-by: Markus Armbruster Signed-off-by: Luiz Capitulino --- monitor.c | 8 ++++---- qemu-monitor.hx | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/monitor.c b/monitor.c index 792c8ce..d3b360c 100644 --- a/monitor.c +++ b/monitor.c @@ -74,7 +74,7 @@ * 'l' target long (32 or 64 bit) * 'M' just like 'l', except in user mode the value is * multiplied by 2^20 (think Mebibyte) - * 'b' double + * 'f' double * user mode accepts an optional G, g, M, m, K, k suffix, * which multiplies the value by 2^30 for suffixes G and * g, 2^20 for M and m, 2^10 for K and k @@ -3799,7 +3799,7 @@ static const mon_cmd_t *monitor_parse_command(Monitor *mon, qdict_put(qdict, key, qint_from_int(val)); } break; - case 'b': + case 'f': case 'T': { double val; @@ -3815,7 +3815,7 @@ static const mon_cmd_t *monitor_parse_command(Monitor *mon, if (get_double(mon, &val, &p) < 0) { goto fail; } - if (c == 'b' && *p) { + if (c == 'f' && *p) { switch (*p) { case 'K': case 'k': val *= 1 << 10; p++; break; @@ -4316,7 +4316,7 @@ static int check_arg(const CmdArgs *cmd_args, QDict *args) return -1; } break; - case 'b': + case 'f': case 'T': if (qobject_type(value) != QTYPE_QINT && qobject_type(value) != QTYPE_QFLOAT) { qerror_report(QERR_INVALID_PARAMETER_TYPE, name, "number"); diff --git a/qemu-monitor.hx b/qemu-monitor.hx index 31087bd..8c9a41c 100644 --- a/qemu-monitor.hx +++ b/qemu-monitor.hx @@ -804,7 +804,7 @@ ETEXI { .name = "migrate_set_speed", - .args_type = "value:b", + .args_type = "value:f", .params = "value", .help = "set maximum speed (in bytes) for migrations", .user_print = monitor_user_noop,