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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 976DFCD98EA for ; Wed, 11 Oct 2023 03:03:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1344930AbjJKDD1 (ORCPT ); Tue, 10 Oct 2023 23:03:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44368 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1344935AbjJKDDY (ORCPT ); Tue, 10 Oct 2023 23:03:24 -0400 Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 08085B8 for ; Tue, 10 Oct 2023 20:03:23 -0700 (PDT) Received: from dggpemm100001.china.huawei.com (unknown [172.30.72.54]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4S4yCv4zFDzkY8D; Wed, 11 Oct 2023 10:59:23 +0800 (CST) Received: from [10.174.177.243] (10.174.177.243) by dggpemm100001.china.huawei.com (7.185.36.93) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.31; Wed, 11 Oct 2023 11:03:20 +0800 Message-ID: <8fe8c652-b5c6-4e24-9847-7c3bb01279c0@huawei.com> Date: Wed, 11 Oct 2023 11:03:20 +0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH -next 4/7] mm: convert xchg_page_access_time to xchg_folio_access_time() Content-Language: en-US To: Matthew Wilcox CC: Andrew Morton , , , , , Zi Yan References: <20231010064544.4162286-1-wangkefeng.wang@huawei.com> <20231010064544.4162286-5-wangkefeng.wang@huawei.com> From: Kefeng Wang In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.174.177.243] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To dggpemm100001.china.huawei.com (7.185.36.93) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2023/10/10 20:27, Matthew Wilcox wrote: > On Tue, Oct 10, 2023 at 02:45:41PM +0800, Kefeng Wang wrote: >> Make xchg_page_access_time to take a folio, and rename it to >> xchg_folio_access_time() since all callers with a folio. > > You're doing this the hard way, which makes life hard for the reviewrs. > > patch 1. Introduce folio->_last_cpupid > patch 2: Add > > static inline int folio_xchg_access_time(struct folio *folio, int time) > { > return xchg_page_access_time(&folio->page, time); > } > > patch 3-n: Convert callers > Patch n+1: Remove xchg_page_access_time(), folding it into > folio_xchg_access_time(). Ok, I will follow this way, thanks for your advise. > > Similarly for page_cpupid_xchg_last / folio_cpupid_xchg_last(). > (why is this not called folio_xchg_last_cpupid?) Fine with me, will update. Thanks. > >