From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Nz4zS-0001U5-5F for qemu-devel@nongnu.org; Tue, 06 Apr 2010 05:22:34 -0400 Received: from [140.186.70.92] (port=53056 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Nz4zQ-0001SJ-Bn for qemu-devel@nongnu.org; Tue, 06 Apr 2010 05:22:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Nz4zO-00071R-Iq for qemu-devel@nongnu.org; Tue, 06 Apr 2010 05:22:32 -0400 Received: from mx1.redhat.com ([209.132.183.28]:23101) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nz4zO-00071K-Aq for qemu-devel@nongnu.org; Tue, 06 Apr 2010 05:22:30 -0400 Message-ID: <4BBAFD2B.6010105@redhat.com> Date: Tue, 06 Apr 2010 11:21:47 +0200 From: Kevin Wolf MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH]: block: get rid of the BDRV_O_FILE flag References: <20100405145357.GA25954@lst.de> In-Reply-To: <20100405145357.GA25954@lst.de> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Christoph Hellwig Cc: qemu-devel@nongnu.org Am 05.04.2010 16:53, schrieb Christoph Hellwig: > BDRV_O_FILE is only used to communicate between bdrv_file_open and bdrv_open. > It affects two things: first bdrv_open only searches for protocols using > find_protocol instead of all image formats and host drivers. We can easily > move that to the caller and pass the found driver to bdrv_open. Second > it is used to not force a read-write open of a snapshot file. But we never > use bdrv_file_open to open snapshots and this behaviour doesn't make sense > to start with. > > qemu-io abused the BDRV_O_FILE for it's growable option, switch it to > using bdrv_file_open to make sure we only open files as growable were > we can actually support that. > > This patch requires Kevin's "[PATCH] Replace calls of old bdrv_open" to > be applied first. > > Signed-off-by: Christoph Hellwig Looks like a step in the right direction. Acked-by: Kevin Wolf