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=-6.6 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED 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 6A65FC00A89 for ; Mon, 2 Nov 2020 19:37:42 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id BFD332225E for ; Mon, 2 Nov 2020 19:37:41 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="REv90MNn" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org BFD332225E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id E397F6B0036; Mon, 2 Nov 2020 14:37:40 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id DE8D06B005C; Mon, 2 Nov 2020 14:37:40 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CFF0D6B0068; Mon, 2 Nov 2020 14:37:40 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0036.hostedemail.com [216.40.44.36]) by kanga.kvack.org (Postfix) with ESMTP id A5A186B0036 for ; Mon, 2 Nov 2020 14:37:40 -0500 (EST) Received: from smtpin06.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 455CC180AD807 for ; Mon, 2 Nov 2020 19:37:39 +0000 (UTC) X-FDA: 77440487838.06.tail56_470c6f9272b2 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin06.hostedemail.com (Postfix) with ESMTP id BAA4C1003DAE2 for ; Mon, 2 Nov 2020 19:37:38 +0000 (UTC) X-HE-Tag: tail56_470c6f9272b2 X-Filterd-Recvd-Size: 3458 Received: from mail-qk1-f196.google.com (mail-qk1-f196.google.com [209.85.222.196]) by imf41.hostedemail.com (Postfix) with ESMTP for ; Mon, 2 Nov 2020 19:37:37 +0000 (UTC) Received: by mail-qk1-f196.google.com with SMTP id l2so12608708qkf.0 for ; Mon, 02 Nov 2020 11:37:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=fzT0RAqiMzs39m37dX/EBLpU88lzxt1fP1ZflrRv3fo=; b=REv90MNn8vH/rMHILEWe1iBlBcHaHV38kkgx1WVRe+c9Q/TTxTr8MiYTJqVffqaFXY 71T7jjlTe+wYZCabP6RtqNcdHeYIJV6DBZA+UnRuAo+9KxszzjpYRl8SN1lzh0Pjor2O z+kVNH+4dqSMZWFRUQaV8YSEQ5U1izXhHzw4uy0arRBuYwFM9D0UXPiSmMn/++vswnr5 +5qhQv2Q/7TOgX3ca/3j41naLDzzxKiRLqux2iCYOZbliZTiZZN5uh3yI+7W1Ir/yYot LrFVHotqzALjr9hwQqHUujypCUlLYRdoNcGhkjDyHkvjuWrXBtTGDTdVAQb1xI9/6B/z UGrw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=fzT0RAqiMzs39m37dX/EBLpU88lzxt1fP1ZflrRv3fo=; b=Us9Ybx36rXXbkQQUMLYGkbxxiav+3V4352Ar5aVIjKWJIp3X2er3N5FgnTsx6kbA8a UJzOCrTu1aRYflZOMuCdRvH3p7eJ1MBpfQG9lLUl23DM4yF7iuTPtdvKAnSa7+j2XTKf KmaxDkjtoCs4KC4wqhMttSqsQxnfIsYypj2BoOPKblvcED6Go8JndK3j11QrxhFNuuye UG+axo7GKhnUeifQbVptQMtxunrFssCZOKxnVlpxZNc7n6GNb1ugDpii61x3MVF0BR6I v7obZoU8OUV8y3PR4kZRm77O0ertyXO7YDk5YsKDAOAAcCjIqVTnrupf2sE5eOVRwAZ1 BlCQ== X-Gm-Message-State: AOAM530Kj3p+vkzZKqoET1Y/cJ2HiS3tYiaCANZlQ8PeWaNfgiwMbOK9 GtzOx+1yyC5uM9+3oiZr1hm50hHH9rG5 X-Google-Smtp-Source: ABdhPJyxSkcg6juHn86OWdiimWTDOgXPZQ7U33NFe/CpUGJOfwcU3FNTBKK7DZLwTuvRUqR48pqwfw== X-Received: by 2002:a37:6fc5:: with SMTP id k188mr16766947qkc.317.1604345857103; Mon, 02 Nov 2020 11:37:37 -0800 (PST) Received: from moria.home.lan (c-73-219-103-14.hsd1.vt.comcast.net. [73.219.103.14]) by smtp.gmail.com with ESMTPSA id g191sm4544455qke.86.2020.11.02.11.37.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Nov 2020 11:37:36 -0800 (PST) Date: Mon, 2 Nov 2020 14:37:35 -0500 From: Kent Overstreet To: "Matthew Wilcox (Oracle)" Cc: linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, hch@lst.de Subject: Re: [PATCH 07/17] mm/filemap: Change filemap_read_page calling conventions Message-ID: <20201102193735.GK2123636@moria.home.lan> References: <20201102184312.25926-1-willy@infradead.org> <20201102184312.25926-8-willy@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20201102184312.25926-8-willy@infradead.org> X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Mon, Nov 02, 2020 at 06:43:02PM +0000, Matthew Wilcox (Oracle) wrote: > Make this function more generic by passing the file instead of the iocb. > Check in the callers whether we should call readpage or not. Also make > it return an errno / 0 / AOP_TRUNCATED_PAGE, and make calling put_page() > the caller's responsibility. > > Signed-off-by: Matthew Wilcox (Oracle) Reviewed-by: Kent Overstreet