From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KOxI7-0005jn-73 for qemu-devel@nongnu.org; Fri, 01 Aug 2008 12:15:43 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KOxI5-0005iM-Kz for qemu-devel@nongnu.org; Fri, 01 Aug 2008 12:15:42 -0400 Received: from [199.232.76.173] (port=57591 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KOxI5-0005i6-Dd for qemu-devel@nongnu.org; Fri, 01 Aug 2008 12:15:41 -0400 Received: from mx1.redhat.com ([66.187.233.31]:50614) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KOxI4-00022V-JG for qemu-devel@nongnu.org; Fri, 01 Aug 2008 12:15:41 -0400 Date: Fri, 1 Aug 2008 17:15:29 +0100 From: "Daniel P. Berrange" Subject: Re: [Qemu-devel] PATCH: v3 Allow control over drive file open mode Message-ID: <20080801161529.GA4966@redhat.com> References: <20080801102949.GN23993@redhat.com> <48932751.5040303@codemonkey.ws> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <48932751.5040303@codemonkey.ws> Reply-To: "Daniel P. Berrange" , qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: qemu-devel@nongnu.org On Fri, Aug 01, 2008 at 10:10:09AM -0500, Anthony Liguori wrote: > Daniel P. Berrange wrote: > >This is version 3 of the patch. > > > > Allowing the user to specify what mode we use to open a file is IMHO not > a good interface for a user. A user should only be concerned with how > we expose a disk to the guest, not the underlying implementation of how > we support this. It has subtle side-effects that a user is not going to > expect unless they are intimately familiar with how QEMU is implemented > (like snapshotting breaking). So if I'm understanding you correctly, you'd be OK with a mode=ro, which would make the emulated drive itself read-only - independant of what open() flags we use for opening the file on the host ? So my next question would be, what IDE / SCSI / USB drives have a concept of 'read only' ? A CDROM clearly is clearly readonly, and floppy disks probably be to but can you mark general disks as read only ? Daniel -- |: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :| |: http://libvirt.org -o- http://virt-manager.org -o- http://ovirt.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|