From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeff Moyer Subject: Re: [patch 1/6] mm: direct IO starvation improvement Date: Fri, 12 Dec 2008 11:04:32 -0500 Message-ID: References: <20081210072454.GB27096@wotan.suse.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Andrew Morton , linux-fsdevel@vger.kernel.org, Mikulas Patocka To: Nick Piggin Return-path: Received: from mx2.redhat.com ([66.187.237.31]:53364 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757310AbYLLQEi (ORCPT ); Fri, 12 Dec 2008 11:04:38 -0500 In-Reply-To: <20081210072454.GB27096@wotan.suse.de> (Nick Piggin's message of "Wed, 10 Dec 2008 08:24:54 +0100") Sender: linux-fsdevel-owner@vger.kernel.org List-ID: Nick Piggin writes: > Direct IO can invalidate and sync a lot of pagecache pages in the mapping. A > 4K direct IO will actually try to sync and/or invalidate the pagecache of the > entire file, for example (which might be many GB or TB large). > > Improve this by doing range syncs. Also, memory no longer has to be unmapped > to catch the dirty bits for syncing, as dirty bits would remain coherent due to > dirty mmap accounting. > > This fixes the immediate DM deadlocks when doing direct IO reads to block > device with a mounted filesystem, if only by papering over the problem somewhat > rather than addressing the fsync starvation cases. > > Signed-off-by: Nick Piggin Reviewed-by: Jeff Moyer Cheers, Jeff