From patchwork Mon Dec 5 21:32:00 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeff Cody X-Patchwork-Id: 9461523 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 7462F60236 for ; Mon, 5 Dec 2016 21:33:09 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 664B5280CF for ; Mon, 5 Dec 2016 21:33:09 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5B0C72811C; Mon, 5 Dec 2016 21:33:09 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 084B4280CF for ; Mon, 5 Dec 2016 21:33:09 +0000 (UTC) Received: from localhost ([::1]:44439 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cE0sm-0007cx-3h for patchwork-qemu-devel@patchwork.kernel.org; Mon, 05 Dec 2016 16:33:08 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58854) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cE0rv-0007Zp-M3 for qemu-devel@nongnu.org; Mon, 05 Dec 2016 16:32:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cE0rr-0005p8-0z for qemu-devel@nongnu.org; Mon, 05 Dec 2016 16:32:15 -0500 Received: from mx1.redhat.com ([209.132.183.28]:42140) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cE0ro-0005o0-Ib; Mon, 05 Dec 2016 16:32:08 -0500 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 9A44C19CFF0; Mon, 5 Dec 2016 21:32:07 +0000 (UTC) Received: from localhost (ovpn-112-60.phx2.redhat.com [10.3.112.60]) by int-mx14.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id uB5LW62h013776 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 5 Dec 2016 16:32:07 -0500 From: Jeff Cody To: qemu-block@nongnu.org Date: Mon, 5 Dec 2016 16:32:00 -0500 Message-Id: <1480973521-28945-3-git-send-email-jcody@redhat.com> In-Reply-To: <1480973521-28945-1-git-send-email-jcody@redhat.com> References: <1480973521-28945-1-git-send-email-jcody@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.27 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.29]); Mon, 05 Dec 2016 21:32:07 +0000 (UTC) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PULL for-2.8 2/3] block/nfs: fix QMP to match debug option X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: peter.maydell@linaro.org, jcody@redhat.com, qemu-devel@nongnu.org, stefanha@redhat.com Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Prasanna Kumar Kalever The QMP definition of BlockdevOptionsNfs: { 'struct': 'BlockdevOptionsNfs', 'data': { 'server': 'NFSServer', 'path': 'str', '*user': 'int', '*group': 'int', '*tcp-syn-count': 'int', '*readahead-size': 'int', '*page-cache-size': 'int', '*debug-level': 'int' } } To make this consistent with other block protocols like gluster, lets change s/debug-level/debug/ Suggested-by: Eric Blake Signed-off-by: Prasanna Kumar Kalever Reviewed-by: Eric Blake Signed-off-by: Jeff Cody --- block/nfs.c | 4 ++-- qapi/block-core.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/block/nfs.c b/block/nfs.c index d082783..a490660 100644 --- a/block/nfs.c +++ b/block/nfs.c @@ -134,7 +134,7 @@ static int nfs_parse_uri(const char *filename, QDict *options, Error **errp) qdict_put(options, "page-cache-size", qstring_from_str(qp->p[i].value)); } else if (!strcmp(qp->p[i].name, "debug")) { - qdict_put(options, "debug-level", + qdict_put(options, "debug", qstring_from_str(qp->p[i].value)); } else { error_setg(errp, "Unknown NFS parameter name: %s", @@ -165,7 +165,7 @@ static bool nfs_has_filename_options_conflict(QDict *options, Error **errp) !strcmp(qe->key, "tcp-syn-count") || !strcmp(qe->key, "readahead-size") || !strcmp(qe->key, "page-cache-size") || - !strcmp(qe->key, "debug-level") || + !strcmp(qe->key, "debug") || strstart(qe->key, "server.", NULL)) { error_setg(errp, "Option %s cannot be used with a filename", diff --git a/qapi/block-core.json b/qapi/block-core.json index 03b19f1..f22ed2a 100644 --- a/qapi/block-core.json +++ b/qapi/block-core.json @@ -2292,7 +2292,7 @@ # @page-cache-size: #optional set the pagecache size in bytes (defaults # to libnfs default) # -# @debug-level: #optional set the NFS debug level (max 2) (defaults +# @debug: #optional set the NFS debug level (max 2) (defaults # to libnfs default) # # Since 2.8 @@ -2305,7 +2305,7 @@ '*tcp-syn-count': 'int', '*readahead-size': 'int', '*page-cache-size': 'int', - '*debug-level': 'int' } } + '*debug': 'int' } } ## # @BlockdevOptionsCurl