Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp31278pxf; Wed, 17 Mar 2021 14:29:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyIw4TU09n56aN+btd2OkJtg7N4TCflu0xeSdLCmgS0pQo+dZ8p0AjkT9LWD36heyzE0wR2 X-Received: by 2002:a05:6402:510b:: with SMTP id m11mr44808506edd.103.1616016560120; Wed, 17 Mar 2021 14:29:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616016560; cv=none; d=google.com; s=arc-20160816; b=s7Bddb+2Nll9O8y/qDtq+u3H+hO3OAc6L5rxJYG6AN4sEffoZ0XKJeqwTM6WgUeAIP 3XcJtn4zZEibFYzTETcp8XoO/6K8j21Wri333uLsfhSfM6D7hGQLq1QL5bTCMf3dOvpY V7SpBaVN1EZCSXYU3V+Ub3X7g8zbWM7h4qkINQOp2FT/SccuwhJrGR3LNJvF/9JFCi93 i257Ndl4hGCyB8jVbAc+Ugk8iXSVyO854EiKW8eJ4zb4n0zI7Q+wWWQefThDP3N6EEoq rSYC1E/4QzjVVPrR282wIXYmTnuOxDtUMlbLtM25uCZHQHwdfrNdE7EyJ9ypM/5o2xeQ /mtA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=VjkGq4o46IxCddXbjgtdiOkMjQXv081kHe8HpX/+37w=; b=X3I0wTdAGTsxcFXQyMT4TlDIyYxfzjFUH6BgekcvEOLGsU9441SCZs9C3cSdrjmA9m uL+bFy7JbGzuJ7zb03N1kRrRc4wolm1nk/A3lD+qEWO0oUo9uDYOSJiTA0XoFjZxPmZu jsTzRtOVoOOC4ZIlmXtSE3+zrrWjbW1bNd2oMB3S+kDgNba5p6hUHyaIg31q4cIA+3SM Aoxngs5WAwQi8Lc0QpeF/tY69TB9NEJZyj/S/Tm+2ZoXHDMSbmQ3Xr/RG6KFiid0+g3Y b9/09L/6WueKFbJ7QF4SogzoVcPjDTRx31VbO9H5F8dOh58mDmCzUL8N+v00vfUm5bg3 1VRw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=HJm1s168; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j13si17221529edn.369.2021.03.17.14.28.57; Wed, 17 Mar 2021 14:29:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=HJm1s168; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230084AbhCQRYA (ORCPT + 99 others); Wed, 17 Mar 2021 13:24:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36366 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229508AbhCQRXb (ORCPT ); Wed, 17 Mar 2021 13:23:31 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 79AB3C06174A; Wed, 17 Mar 2021 10:23:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.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; bh=VjkGq4o46IxCddXbjgtdiOkMjQXv081kHe8HpX/+37w=; b=HJm1s168ZeLvCNM3qnX/wxZG8s 43QF+GVdGN0kE+jnx2c2YOIPhv45wW1TvVJgoURgFHfqeMQNw76wq5X4ZozcldmEOgD33lKSijtvq tivBwk8FGh42lXlvePWyX7rU1szy8DFUEbwr1TybVTtgym8Tanz1RCWu+RBpTma368SrSyNuNRUrB rseV7pQGseXOazr77yDUHyk/at1/gkNX3AswAzIr+YO5SumGy2WZ2itocLpmJdp4lpm5HbNQoY1l2 6J+c4QZBNNeVCedTleRbFUokI3fcd4vjujT4iNyVljRhZsm8mCsIKRFWGNnsAB2ZTfMz+qT5uYUD3 4io5ZVzQ==; Received: from [2001:4bb8:18c:bb3:e3eb:4a4b:ba2f:224b] (helo=localhost) by casper.infradead.org with esmtpsa (Exim 4.94 #2 (Red Hat Linux)) id 1lMZsX-001uHN-Og; Wed, 17 Mar 2021 17:22:52 +0000 Date: Wed, 17 Mar 2021 18:22:40 +0100 From: Christoph Hellwig To: Andrew Morton Cc: "Matthew Wilcox (Oracle)" , linux-mm@kvack.org, linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org Subject: Re: [PATCH v4 09/25] mm: Add folio_index, folio_page and folio_contains Message-ID: References: <20210305041901.2396498-1-willy@infradead.org> <20210305041901.2396498-10-willy@infradead.org> <20210313123716.a4f9403e9f6ebbd719dac2a8@linux-foundation.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210313123716.a4f9403e9f6ebbd719dac2a8@linux-foundation.org> X-SRS-Rewrite: SMTP reverse-path rewritten from by casper.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Mar 13, 2021 at 12:37:16PM -0800, Andrew Morton wrote: > On Fri, 5 Mar 2021 04:18:45 +0000 "Matthew Wilcox (Oracle)" wrote: > > > folio_index() is the equivalent of page_index() for folios. folio_page() > > finds the page in a folio for a page cache index. folio_contains() > > tells you whether a folio contains a particular page cache index. > > > > copy-paste changelog into each function's covering comment? Yes, I think documenting all these helpers would be very useful. The lack of good commens on some of the page related existing helpers has driven me insane sometimes.