From: Kevin Wolf <kwolf@redhat.com>
To: Eric Blake <eblake@redhat.com>
Cc: nbd-general@lists.sourceforge.net, xieyingtai@huawei.com,
subo7@huawei.com, qemu-block@nongnu.org, eric.fangyi@huawei.com,
qemu-devel@nongnu.org, pbonzini@redhat.com
Subject: Re: [Qemu-devel] [Qemu-block] [PATCH] doc: Propose NBD_FLAG_INIT_ZEROES extension
Date: Tue, 6 Dec 2016 10:25:23 +0100 [thread overview]
Message-ID: <20161206092523.GA4990@noname.str.redhat.com> (raw)
In-Reply-To: <20161205234235.5728-1-eblake@redhat.com>
Am 06.12.2016 um 00:42 hat Eric Blake geschrieben:
> While not directly related to NBD_CMD_WRITE_ZEROES, the qemu
> team discovered that it is useful if a server can advertise
> whether an export is in a known-all-zeroes state at the time
> the client connects.
Does a server usually have the information to set this flag, other than
querying the block status of all blocks at startup? If so, the client
could just query this by itself.
The patch that was originally sent to qemu-devel just forwarded qemu's
.bdrv_has_zero_init() call to the server. However, what this function
returns is not a known-all-zeroes state on open, but just a
known-all-zeroes state immediately after bdrv_create(), i.e. creating a
new image. Then it becomes information that is easy to get and doesn't
involve querying all blocks (e.g. true for COW image formats, true for
raw on regular files, false for raw on block devices).
This is useful for 'qemu-img convert', which creates an image and then
writes the whole contents, but I'm not sure if this property is
applicable for NBD, which I think doesn't even have a create operation.
Kevin
next prev parent reply other threads:[~2016-12-06 9:25 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-05 23:42 [Qemu-devel] [PATCH] doc: Propose NBD_FLAG_INIT_ZEROES extension Eric Blake
2016-12-06 8:46 ` [Qemu-devel] [Nbd] " Alex Bligh
2016-12-06 10:30 ` Alex Bligh
2016-12-06 9:25 ` Kevin Wolf [this message]
2016-12-06 10:29 ` [Qemu-devel] [Nbd] [Qemu-block] " Alex Bligh
2016-12-06 15:21 ` [Qemu-devel] " Eric Blake
2016-12-07 10:44 ` Kevin Wolf
2016-12-07 15:50 ` Eric Blake
2016-12-07 16:35 ` Kevin Wolf
2016-12-06 10:18 ` [Qemu-devel] " Stefan Hajnoczi
2016-12-12 18:12 ` [Qemu-devel] [Nbd] " Wouter Verhelst
2016-12-13 7:38 ` [Qemu-devel] [Qemu-block] " Kevin Wolf
2016-12-13 12:18 ` [Qemu-devel] [Nbd] [Qemu-block] " Wouter Verhelst
2016-12-13 13:19 ` Alex Bligh
2016-12-13 22:36 ` Eric Blake
2016-12-14 8:22 ` Wouter Verhelst
2016-12-14 16:37 ` Eric Blake
2016-12-14 16:54 ` Alex Bligh
2016-12-14 19:58 ` Wouter Verhelst
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=20161206092523.GA4990@noname.str.redhat.com \
--to=kwolf@redhat.com \
--cc=eblake@redhat.com \
--cc=eric.fangyi@huawei.com \
--cc=nbd-general@lists.sourceforge.net \
--cc=pbonzini@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=subo7@huawei.com \
--cc=xieyingtai@huawei.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).