Message ID | 1478105438-20883-3-git-send-email-prasanna.kalever@redhat.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On 11/02/2016 11:50 AM, Prasanna Kumar Kalever wrote: > 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 <eblake@redhat.com> > Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com> > --- > block/nfs.c | 4 ++-- > qapi/block-core.json | 4 ++-- > 2 files changed, 4 insertions(+), 4 deletions(-) > > +++ 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 This is the first release of this struct. We WANT to avoid making future name changes, as well as to avoid silly inconsistencies between different drivers. So this is definitely 2.8 material. Apologies for not flagging this thread sooner as needing to go in to one of the earlier release candidates. Reviewed-by: Eric Blake <eblake@redhat.com>
diff --git a/block/nfs.c b/block/nfs.c index 55c4e0b..21f3c8c 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 a569cfb..804da61 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
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 <eblake@redhat.com> Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com> --- block/nfs.c | 4 ++-- qapi/block-core.json | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)