From: Fabiano Rosas <farosas@linux.vnet.ibm.com>
To: qemu-devel@nongnu.org
Cc: qemu-block@nongnu.org, kwolf@redhat.com, mreitz@redhat.com,
Wen Congyang <wencongyang2@huawei.com>,
Xie Changlong <xiechanglong.d@gmail.com>
Subject: [Qemu-devel] [PATCH 1/5] block/replication: Remove protocol_name field
Date: Fri, 9 Mar 2018 15:21:57 -0300 [thread overview]
Message-ID: <20180309182202.31206-2-farosas@linux.vnet.ibm.com> (raw)
In-Reply-To: <20180309182202.31206-1-farosas@linux.vnet.ibm.com>
The replication driver is only selected explicitly (via
driver=replication,mode=primary,...) so it is not a protocol driver.
This patch removes the protocol_name field from the brdv_replication
structure so that attempts to invoke this driver using protocol
syntax (i.e. replication:<filename:options:...>) will fail gracefully:
$ qemu-img info replication:foo
qemu-img: Could not open 'replication:': Unknown protocol 'replication'
Buglink: https://bugs.launchpad.net/qemu/+bug/1726733
Signed-off-by: Fabiano Rosas <farosas@linux.vnet.ibm.com>
---
block/replication.c | 1 -
replication.h | 1 -
2 files changed, 2 deletions(-)
diff --git a/block/replication.c b/block/replication.c
index f98ef094b9..6c0c7186d9 100644
--- a/block/replication.c
+++ b/block/replication.c
@@ -703,7 +703,6 @@ static void replication_stop(ReplicationState *rs, bool failover, Error **errp)
BlockDriver bdrv_replication = {
.format_name = "replication",
- .protocol_name = "replication",
.instance_size = sizeof(BDRVReplicationState),
.bdrv_open = replication_open,
diff --git a/replication.h b/replication.h
index 8faefe005f..4c8354de23 100644
--- a/replication.h
+++ b/replication.h
@@ -67,7 +67,6 @@ typedef struct ReplicationState ReplicationState;
*
* BlockDriver bdrv_replication = {
* .format_name = "replication",
- * .protocol_name = "replication",
* .instance_size = sizeof(BDRVReplicationState),
*
* .bdrv_open = replication_open,
--
2.13.6
next prev parent reply other threads:[~2018-03-09 18:22 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-09 18:21 [Qemu-devel] [PATCH 0/5] block: Ensure non-protocol drivers can only be selected explicitly Fabiano Rosas
2018-03-09 18:21 ` Fabiano Rosas [this message]
2018-03-12 13:41 ` [Qemu-devel] [PATCH 1/5] block/replication: Remove protocol_name field Max Reitz
2018-03-09 18:21 ` [Qemu-devel] [PATCH 2/5] block/quorum: Remove protocol-related fields Fabiano Rosas
2018-03-12 13:44 ` Max Reitz
2018-03-09 18:21 ` [Qemu-devel] [PATCH 3/5] block/throttle: " Fabiano Rosas
2018-03-12 13:44 ` Max Reitz
2018-03-09 18:22 ` [Qemu-devel] [PATCH 4/5] block/blkreplay: " Fabiano Rosas
2018-03-12 8:05 ` Pavel Dovgalyuk
2018-03-12 13:45 ` Max Reitz
2018-03-09 18:22 ` [Qemu-devel] [PATCH 5/5] include/block/block_int: Document protocol related functions Fabiano Rosas
2018-03-12 13:50 ` Max Reitz
2018-03-12 22:26 ` Fabiano Rosas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180309182202.31206-2-farosas@linux.vnet.ibm.com \
--to=farosas@linux.vnet.ibm.com \
--cc=kwolf@redhat.com \
--cc=mreitz@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=wencongyang2@huawei.com \
--cc=xiechanglong.d@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).