Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp1447884ybl; Wed, 29 Jan 2020 23:27:11 -0800 (PST) X-Google-Smtp-Source: APXvYqwIg05Z/y1Nr3xikW8r0rkLDwET9Mt+4CeKFsA/9g7Fn+E6Bk46Gs0k9yXg9CW2/IcCrEc9 X-Received: by 2002:aca:5303:: with SMTP id h3mr1928237oib.109.1580369231812; Wed, 29 Jan 2020 23:27:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1580369231; cv=none; d=google.com; s=arc-20160816; b=fHcHhnXsxmgd0Sw5Xg65xIrr5Ushv8eEPfUKNn7LrrshCRiYeTgSG/t/8lvA4vJP54 YB5H6eow7xUyAFqwEtQ+et1QqaeIA5INLP9aSXruefigYls2Q9TcT8r5TiPTurFh/htS 8+7X7W9WeyPgfORMENDgM6MVDsNs5q09Wpm6uQd4yVLA5M9/mbdNaIJP9uZXXIriuOtW CIL9nzbubX2kNgEK1bRlYGLTrVNi3vw9aFNr6cQTVF6C2qzwFKqHrOzERTUTt9Bk5RZs t5Bjx4ybp+5FqoVvVd4SypYRoDQcxHizJIblxb8iiNmuCRq/HCWPuwM4JKttaNs7Qxfa UcAw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=RPPsRlIh7a3GIi8RqNtoOhkrf/5qMif620lE3PkTLu8=; b=MzuSMEisGuKepkQVzUFOWtP0MJDap9CJpwFzWjdt1hsJu5y8iti8Iw8RkfI4gTSuxP a4WY4Ub3pEHQW5cH+gFzkYCtySmGCVRDjtPLA91bG8hY9ZbmGT3bWkltvt/nG0PPxO+/ TNcoe6YNgbmAWmsuJuVaSQEcnN4U/kub8py/MyenoU4Kbdz9r4wY3trlPeh1GH6K+Ksj OKAQDFGk5nDCmq0gLvyaiK7mB6tqL9O5n9T28KFoNsEtuINkzkcYE/a91lI3f6zoJb/Q cWQZFZuXiOjKJcqp6KvMapiDZkO8wCn6t4hNg3hpbsNFYgNZdQjrYQK97dxnq5S05z0y LQNA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=FComybUB; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a7si2482454otp.11.2020.01.29.23.26.59; Wed, 29 Jan 2020 23:27:11 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=FComybUB; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726757AbgA3H0G (ORCPT + 99 others); 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-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@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.