From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NSQcG-0005fM-PR for qemu-devel@nongnu.org; Wed, 06 Jan 2010 02:47:40 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NSQcB-0005fA-O1 for qemu-devel@nongnu.org; Wed, 06 Jan 2010 02:47:40 -0500 Received: from [199.232.76.173] (port=46056 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NSQcB-0005f7-DP for qemu-devel@nongnu.org; Wed, 06 Jan 2010 02:47:35 -0500 Received: from mx20.gnu.org ([199.232.41.8]:62390) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NSQcA-0007ZP-Un for qemu-devel@nongnu.org; Wed, 06 Jan 2010 02:47:35 -0500 Received: from mx1.redhat.com ([209.132.183.28]) by mx20.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NSQc9-0001qL-19 for qemu-devel@nongnu.org; Wed, 06 Jan 2010 02:47:33 -0500 Message-ID: <4B44400C.6050507@redhat.com> Date: Wed, 06 Jan 2010 09:47:24 +0200 From: Naphtali Sprei MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH] Added 'access' option to -drive flag References: <4B320927.8020702@redhat.com> <4B42543C.4060506@codemonkey.ws> <20100106001950.GA25683@shareable.org> In-Reply-To: <20100106001950.GA25683@shareable.org> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jamie Lokier Cc: Markus Armbruster , qemu-devel@nongnu.org Jamie Lokier wrote: > Anthony Liguori wrote: >> On 12/24/2009 03:09 AM, Markus Armbruster wrote: >>> Naphtali Sprei writes: >>> >>>> Added 'access' option to -drive flag >>>> >>>> The new option is: access=[rw|ro|auto] >>>> rw: open the drive's file with Read and Write permission, don't continue >>>> if failed >>>> ro: open the file only with Read permission >>>> auto: open the file with Read and Write permission, if failed, try only >>>> Read permision >>>> >>>> For compatibility reasons, the default is 'auto'. Should be changed later >>>> on. >>>> >>>> This option is to replace the 'readonly' options added lately. >>> Can we take the readonly parameter away? It's undocumented, for >>> whatever that's worth... >> readonly made 0.12. Semantics, readonly makes it to the disk emulation >> whereas this effects how the file is opened. I'm not sure I understand this semantic difference. The implementation of both versions (readonly and access) affects both the disk emulation and the file access/open. I did meant that 'access' to replace the 'readonly', and I do understand that I did it in bad timing. > > With readonly in 0.12, if you _don't specify readonly, and the file is > opened readonly because it applies qemu's fallback behaviour - does > *that* read-only property make it to the disk emulation? Or do guests > still see unexplained I/O errors in that case? The implementation of both 'readonly' and 'access' pass the information to the Guest, through the device API. Indeed, only for supporting devices. > > Btw, wasn't the access=[rw|ro|auto] option supposed to affect disk > emulation too? > > -- Jamie