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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5B339C433F5 for ; Mon, 23 May 2022 07:13:35 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id ED2936B0006; Mon, 23 May 2022 03:13:34 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id E82996B0007; Mon, 23 May 2022 03:13:34 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id D98286B0008; Mon, 23 May 2022 03:13:34 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id C62D96B0006 for ; Mon, 23 May 2022 03:13:34 -0400 (EDT) Received: from smtpin01.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay12.hostedemail.com (Postfix) with ESMTP id 93EEB120CCF for ; Mon, 23 May 2022 07:13:34 +0000 (UTC) X-FDA: 79496142348.01.016F0B9 Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) by imf28.hostedemail.com (Postfix) with ESMTP id 77F2EC00C3 for ; Mon, 23 May 2022 07:13:03 +0000 (UTC) Received: from dggpemm500024.china.huawei.com (unknown [172.30.72.57]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4L67pd2fl3zDqNS; Mon, 23 May 2022 15:13:29 +0800 (CST) Received: from dggpemm500001.china.huawei.com (7.185.36.107) by dggpemm500024.china.huawei.com (7.185.36.203) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Mon, 23 May 2022 15:13:30 +0800 Received: from [10.174.177.243] (10.174.177.243) by dggpemm500001.china.huawei.com (7.185.36.107) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Mon, 23 May 2022 15:13:30 +0800 Message-ID: Date: Mon, 23 May 2022 15:13:29 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.5.1 Subject: Re: [PATCH] mm: kfence: Use PAGE_ALIGNED helper Content-Language: en-US To: Muchun Song CC: Marco Elver , Alexander Potapenko , Dmitry Vyukov , Andrew Morton , , References: <20220520021833.121405-1-wangkefeng.wang@huawei.com> <20d731fd-f7f9-4c93-d851-01972dc04cb9@huawei.com> From: Kefeng Wang In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [10.174.177.243] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To dggpemm500001.china.huawei.com (7.185.36.107) X-CFilter-Loop: Reflected X-Rspam-User: X-Rspamd-Queue-Id: 77F2EC00C3 X-Stat-Signature: xxji79wfbj6f599ccoob9a4bb77wqm3h Authentication-Results: imf28.hostedemail.com; dkim=none; spf=pass (imf28.hostedemail.com: domain of wangkefeng.wang@huawei.com designates 45.249.212.189 as permitted sender) smtp.mailfrom=wangkefeng.wang@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com X-Rspamd-Server: rspam04 X-HE-Tag: 1653289983-188090 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 2022/5/23 14:46, Muchun Song wrote: > On Mon, May 23, 2022 at 02:32:59PM +0800, Kefeng Wang wrote: >> On 2022/5/20 18:26, Muchun Song wrote: >>> On Fri, May 20, 2022 at 10:18:33AM +0800, Kefeng Wang wrote: >>>> Use PAGE_ALIGNED macro instead of IS_ALIGNED and passing PAGE_SIZE. >>>> >>>> Signed-off-by: Kefeng Wang >>> Acked-by: Muchun Song >> Thanks, >>> BTW, there is a similar case in page_fixed_fake_head(), woule you like to >>> improve that as well? >> IS_ALIGNED is defined in include/linux/align.h, but PAGE_ALIGNED is in include/linux/mm.h, >> so better to keep unchanged in include/linux/page-flags.h. >> > Maybe we could move this macro to page-flags.h or align.h so that we could > reuse it? align.h is inappropriate, could be page-flags.h,  but this could affect the include of 'mm.h',so I think it is unnecessary to move the PAGE_ALIGNED(and there is a PAGE_ALIGN too, no need to move both of them). > Thanks. > .