From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: * X-Spam-Status: No, score=1.9 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_DBL_ABUSE_MALW autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6CAAFC33C9E for ; Thu, 30 Jan 2020 07:26:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3894520661 for ; Thu, 30 Jan 2020 07:26:07 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="FComybUB" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726647AbgA3H0G (ORCPT ); Thu, 30 Jan 2020 02:26:06 -0500 Received: from bombadil.infradead.org ([198.137.202.133]:39060 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726415AbgA3H0G (ORCPT ); Thu, 30 Jan 2020 02:26:06 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=RPPsRlIh7a3GIi8RqNtoOhkrf/5qMif620lE3PkTLu8=; b=FComybUBSpIsVsPCMSjmNCnBS 9jLghFjTprEBfNjFjotn0sZjFkUk4e5TRB/GGvxDYm99qbUJ5kRnW4GEyI9GkI9uGWpiqyGnV7sA2 lqc2Ee9r0a6z21o47otyJKWgncd69lhhD4PVvN8M8lGZYX8sqZe0Y7kofXKTevE32P7oLZRCWorlO IIRq3TqCkooTcnzMioOCtxntyO1r8CU6MrNiyAJHmE+uQFB5Ytb6lvfa6+zyS8e6kqpYXl10+E8ui Er77KzutKqQDNgw32ehmvYUvxjTFbz+C1plaGsnQ/Xa5oOT0l//Xq9xZP7pjzIzDn2gq/fAlOr86o BKECudI5g==; Received: from willy by bombadil.infradead.org with local (Exim 4.92.3 #3 (Red Hat Linux)) id 1ix4DF-0001Z7-B0; Thu, 30 Jan 2020 07:26:05 +0000 Date: Wed, 29 Jan 2020 23:26:05 -0800 From: Matthew Wilcox To: Miklos Szeredi Cc: linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 11/12] fuse: Convert from readpages to readahead Message-ID: <20200130072605.GJ6615@bombadil.infradead.org> References: <20200125013553.24899-1-willy@infradead.org> <20200125013553.24899-12-willy@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On Wed, Jan 29, 2020 at 11:50:37AM +0100, Miklos Szeredi wrote: > On Sat, Jan 25, 2020 at 2:36 AM Matthew Wilcox wrote: > > > > From: "Matthew Wilcox (Oracle)" > > > > Use the new readahead operation in fuse. Switching away from the > > read_cache_pages() helper gets rid of an implicit call to put_page(), > > so we can get rid of the get_page() call in fuse_readpages_fill(). > > We can also get rid of the call to fuse_wait_on_page_writeback() as > > this page is newly allocated and so cannot be under writeback. > > Not sure. fuse_wait_on_page_writeback() waits not on the page but the > byte range indicated by the index. > > Fuse writeback goes through some hoops to prevent reclaim related > deadlocks, which means that the byte range could still be under > writeback, yet the page belonging to that range be already reclaimed. > This fuse_wait_on_page_writeback() is trying to serialize reads > against such writes. Thanks. I'll put that back in.