From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeff Garzik Subject: Re: [ANNOUNCE] Native Linux KVM tool v2 Date: Fri, 17 Jun 2011 03:21:56 -0400 Message-ID: <4DFB0094.7010605@garzik.org> References: <7A30A509-47AA-4E72-ABF3-937005900F9D@suse.de> <4DF93010.1040006@codemonkey.ws> <4DF935C1.4020000@codemonkey.ws> <20110616092429.GA5484@infradead.org> <20110616094810.GA19965@infradead.org> <20110616100239.GA29262@infradead.org> <20110616112230.GD26110@elte.hu> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Christoph Hellwig , Pekka Enberg , Anthony Liguori , Alexander Graf , Prasad Joshi , Avi Kivity , linux-kernel@vger.kernel.org, kvm@vger.kernel.org, Andrew Morton , Linus Torvalds , Sasha Levin , Cyrill Gorcunov , Asias He , Jens Axboe To: Ingo Molnar Return-path: In-Reply-To: <20110616112230.GD26110@elte.hu> Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On 06/16/2011 07:22 AM, Ingo Molnar wrote: > > * Christoph Hellwig wrote: > >> On Thu, Jun 16, 2011 at 12:57:36PM +0300, Pekka Enberg wrote: >>> Uh-oh. Someone needs to apply this patch to sync_file_range(): >> >> There actually are a few cases where using it makes sense. [...] > > Such as? I don't think apps can actually know whether disk blocks > have been 'instantiated' by a particular filesystem or not, so the > manpage: > > Some details > None of these operations write out the file=E2=80=99s metada= ta. Therefore, unless the appli- > cation is strictly performing overwrites of already-instantia= ted disk blocks, there > are no guarantees that the data will be available after a cra= sh. > > is rather misleading. This is a dangerous (and rather pointless) > syscall and this should be made much clearer in the manpage. Not pointless at all -- see Linus's sync_file_range() examples in "Re:=20 Unexpected splice "always copy" behavior observed" thread from May 2010= =2E Apps like MythTV may use it for streaming data to disk, basically=20 shoving the VM out of the way to give the app more fine-grained writeou= t=20 control. Just don't mistake sync_file_range() for a data integrity syscall. Jeff