From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:60477) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qz8Hw-0005pd-5O for qemu-devel@nongnu.org; Thu, 01 Sep 2011 10:30:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qz8Hu-0000Io-7s for qemu-devel@nongnu.org; Thu, 01 Sep 2011 10:30:40 -0400 Received: from mx1.redhat.com ([209.132.183.28]:55645) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qz8Ht-0000IA-Ub for qemu-devel@nongnu.org; Thu, 01 Sep 2011 10:30:38 -0400 Date: Thu, 1 Sep 2011 15:30:34 +0100 From: "Daniel P. Berrange" Message-ID: <20110901143034.GJ14462@redhat.com> References: <20110901132755.GG14462@redhat.com> <20110901140526.GA9388@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20110901140526.GA9388@lst.de> Subject: Re: [Qemu-devel] QEMU online guest disk resize wrt host block devices Reply-To: "Daniel P. Berrange" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Christoph Hellwig Cc: qemu-devel@nongnu.org On Thu, Sep 01, 2011 at 04:05:26PM +0200, Christoph Hellwig wrote: > On Thu, Sep 01, 2011 at 02:27:55PM +0100, Daniel P. Berrange wrote: > > I see two likely approaches: > > > > 1. Add a parameter to the existing 'block_resize' command > > 'refreshonly=true|false' > > > > 2. Add a separate command 'block_refresh' > > I think all that you need is a to implement a bdrv_truncate method > for host devices that simply checks if the new size smaller or equal > to the device size, and return 0 in that case or an error otherwise. Hmm, yes that is another option. I'll see if I can cook up a patch for doing that. 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 :|