From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Jyb10-0008Jp-9x for qemu-devel@nongnu.org; Tue, 20 May 2008 19:13:06 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Jyb0z-0008JX-5N for qemu-devel@nongnu.org; Tue, 20 May 2008 19:13:05 -0400 Received: from [199.232.76.173] (port=50570 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Jyb0z-0008JQ-2k for qemu-devel@nongnu.org; Tue, 20 May 2008 19:13:05 -0400 Received: from mail2.shareable.org ([80.68.89.115]:49286) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Jyb0y-0007JT-Mx for qemu-devel@nongnu.org; Tue, 20 May 2008 19:13:04 -0400 Date: Wed, 21 May 2008 00:13:03 +0100 From: Jamie Lokier Subject: Re: [Qemu-devel] Re: [PATCH][v2] Align file accesses with cache=off (O_DIRECT) Message-ID: <20080520231303.GJ27853@shareable.org> References: <1211283126.4314.70.camel@frecb07144> <48332AB9.3010707@codemonkey.ws> <20080520223602.GE27853@shareable.org> <1211324687.4217.8.camel@frecb07144> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1211324687.4217.8.camel@frecb07144> Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Laurent Vivier Cc: Blue Swirl , qemu-devel@nongnu.org, Kevin Wolf Laurent Vivier wrote: > Sector unaligned guest offset are converted to sector aligned offset. The guest cannot give a sector unaligned offset. How can it? It specifies offset in sectors, through the IDE or SCSI interfaces. > Sector aligned guest offset are written as is. > > And as we use O_DIRECT and aligned offset and data count I think we > increase disk integrity (regarding the case without O_DIRECT and without > aligned access...), so we should document the case without O_DIRECT use, > not the case with O_DIRECT use... That's fine, for direct-mapped formats. I'm thinking of qcow format etc. where guest aligned writes are sometimes translated to unaligned (is this even true?). -- Jamie