From: "Daniel P. Berrange" <berrange@redhat.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: "Tomáš Golembiovský" <tgolembi@redhat.com>, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 2/2] qemu-nbd: Add --image-size option
Date: Tue, 20 Sep 2016 12:12:47 +0100 [thread overview]
Message-ID: <20160920111247.GE25490@redhat.com> (raw)
In-Reply-To: <30916fa0-a4b2-fa59-a594-38b172099fdb@redhat.com>
On Tue, Sep 20, 2016 at 11:59:28AM +0200, Paolo Bonzini wrote:
>
>
> On 20/09/2016 11:41, Tomáš Golembiovský wrote:
> > When image is part of the file it makes sense to limit the length of the
> > image in the file. Otherwise it is assumed that the image spans to the
> > end of the file. This assumption may lead to reads/writes outside of the
> > image and thus lead to errors or data corruption.
> >
> > To limit the assumed image size new option is introduced.
>
> The patch makes sense, but I think the commit message is incorrect
> because this bug is already fixed by patch 1. Also, the option in the
> help is --device-size, not --image-size; I would just call it --size.
I don't think it makes sense as a special case in qemu-nbd.
It feels like this is better done by extending the 'raw'
block driver with 'offset' and 'length' parameters. You
can then layer the 'raw' block driver over any existing
QEMU blocker driver, anywhere in QEMU / tools that accept
a block device description. No need to add extra parameters
to any of the programs.
Regards,
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
next prev parent reply other threads:[~2016-09-20 11:12 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-20 9:41 [Qemu-devel] [PATCH 2/2] qemu-nbd: Add --image-size option Tomáš Golembiovský
2016-09-20 9:59 ` Paolo Bonzini
2016-09-20 11:12 ` Daniel P. Berrange [this message]
2016-09-20 11:45 ` Paolo Bonzini
2016-10-02 19:33 ` Tomáš Golembiovský
2016-09-20 11:35 ` Tomáš Golembiovský
2016-09-20 12:45 ` Richard W.M. Jones
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=20160920111247.GE25490@redhat.com \
--to=berrange@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=tgolembi@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.