Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NXaFY-0008Mj-CS for qemu-devel@nongnu.org; Wed, 20 Jan 2010 08:05:32 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NXaFT-0008MW-J9 for qemu-devel@nongnu.org; Wed, 20 Jan 2010 08:05:31 -0500 Received: from [199.232.76.173] (port=51762 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NXaFT-0008MT-AJ for qemu-devel@nongnu.org; Wed, 20 Jan 2010 08:05:27 -0500 Received: from mx1.redhat.com ([209.132.183.28]:22570) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NXaFS-0005E5-R1 for qemu-devel@nongnu.org; Wed, 20 Jan 2010 08:05:27 -0500 From: Markus Armbruster Subject: Re: [Qemu-devel] Re: [PATCH v2 2/4] Clean-up a little bit the RW related bits of BDRV_O_FLAGS. BDRV_O_RDONLY gone (and so is BDRV_O_ACCESS). Default value for bdrv_flags (0/zero) is READ-ONLY. Need to explicitly request READ-WRITE. References: <1263739695-13043-1-git-send-email-nsprei@redhat.com> <1263739695-13043-2-git-send-email-nsprei@redhat.com> <1263739695-13043-3-git-send-email-nsprei@redhat.com> <20100117153202.GC3420@redhat.com> <20100118104816.GC5874@redhat.com> <20100120020543.GG11920@shareable.org> <20100120103248.GA22941@redhat.com> <20100120122532.GB9850@redhat.com> Date: Wed, 20 Jan 2010 14:05:23 +0100 In-Reply-To: <20100120122532.GB9850@redhat.com> (Michael S. Tsirkin's message of "Wed, 20 Jan 2010 14:25:32 +0200") Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Michael S. Tsirkin" Cc: Naphtali Sprei , qemu-devel@nongnu.org "Michael S. Tsirkin" writes: > On Wed, Jan 20, 2010 at 01:09:29PM +0100, Markus Armbruster wrote: >> "Michael S. Tsirkin" writes: >> >> > On Wed, Jan 20, 2010 at 08:26:56AM +0100, Markus Armbruster wrote: >> >> Jamie Lokier writes: >> >> >> >> > Michael S. Tsirkin wrote: >> >> >> On Mon, Jan 18, 2010 at 11:34:59AM +0100, Markus Armbruster wrote: >> >> >> > BDRV_O_RDWR is a flag, just like BDRV_SNAPSHOT. We don't have >> >> >> > BDRV_DONT_SNAPSHOT, either. >> >> >> >> >> >> Well, this just mirros the file access macros: we have RDONLY, WRONLY >> >> >> and RDRW. I assume this similarity is just historical? >> >> > >> >> > To avoid confusion, why don't we just call the flag BDRV_O_WRITABLE. >> >> > Then it's obvious what clearing that flag means. >> >> >> >> Sounds good to me. >> > >> > Won't it be confused with WRONLY? >> >> I doubt it. "Writable" implies "write-only" no more than "readable" >> implies "read-only". > > Yes :) But what I am saying is that the disk is readable as well. "Writable" doesn't imply "not readable" either :)