From patchwork Fri Aug 4 01:25:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peng Zhang X-Patchwork-Id: 13341044 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 9B2D5C001DB for ; Fri, 4 Aug 2023 01:26:25 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 830242802B0; Thu, 3 Aug 2023 21:26:15 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 3FE562802AE; Thu, 3 Aug 2023 21:26:15 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 1669028022C; Thu, 3 Aug 2023 21:26:15 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id A485A2802AF for ; Thu, 3 Aug 2023 21:26:14 -0400 (EDT) Received: from smtpin04.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id 66B401212A1 for ; Fri, 4 Aug 2023 01:26:14 +0000 (UTC) X-FDA: 81084681468.04.290F3E5 Received: from szxga08-in.huawei.com (szxga08-in.huawei.com [45.249.212.255]) by imf20.hostedemail.com (Postfix) with ESMTP id 24EC91C0017 for ; Fri, 4 Aug 2023 01:26:11 +0000 (UTC) Authentication-Results: imf20.hostedemail.com; dkim=none; spf=pass (imf20.hostedemail.com: domain of zhangpeng362@huawei.com designates 45.249.212.255 as permitted sender) smtp.mailfrom=zhangpeng362@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1691112372; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Wce6KUcdZjC294h+qAqR9KunJTmmNBJXZjvQKoCWIv4=; b=dPnVqempVoQVXM8wg8kkY6Cx91cnk+gnyMroszZbWS7cWs+uZs7bTeoXsLyoaPuOwdallW Fed3hiOH0zsZo4RjfroV8Wq01S3RIL2kKOdwFflDUjhJDvodKYXTMWly3JhFdAcs6Qz3B5 czu5pzmjV9jN4Oe9S3Wo4jx2k+m86Tg= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1691112372; a=rsa-sha256; cv=none; b=CRPjFtlymDe/Z10giKpKSUnvXBryyiDksnVFMgBFjBPEKidacrqiXAJdnjdGmacb37PGv9 5csXRPRLXYm7tR7Xo8rhJOValOY8780vTfPla+d87qTxJEpTnpze4Xhxnmav1LqZXvYzd0 PCRyxnsFKGLF09KZnV3cHVSFi4wx9k8= ARC-Authentication-Results: i=1; imf20.hostedemail.com; dkim=none; spf=pass (imf20.hostedemail.com: domain of zhangpeng362@huawei.com designates 45.249.212.255 as permitted sender) smtp.mailfrom=zhangpeng362@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com Received: from kwepemm600020.china.huawei.com (unknown [172.30.72.53]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4RH7LS4sFtz1KCDC; Fri, 4 Aug 2023 09:25:04 +0800 (CST) Received: from localhost.localdomain (10.175.112.125) by kwepemm600020.china.huawei.com (7.193.23.147) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.27; Fri, 4 Aug 2023 09:26:08 +0800 From: Peng Zhang To: CC: , , , ZhangPeng Subject: [PATCH 4/7] mm/shmem.c: use helper macro K() Date: Fri, 4 Aug 2023 09:25:56 +0800 Message-ID: <20230804012559.2617515-5-zhangpeng362@huawei.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230804012559.2617515-1-zhangpeng362@huawei.com> References: <20230804012559.2617515-1-zhangpeng362@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.175.112.125] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To kwepemm600020.china.huawei.com (7.193.23.147) X-CFilter-Loop: Reflected X-Stat-Signature: fxiw4gkts1ify1prtudr953bptar549b X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: 24EC91C0017 X-Rspam-User: X-HE-Tag: 1691112371-43586 X-HE-Meta: U2FsdGVkX19jPxR1SrvHf05lziqqCl04igM0WkI9uElb0JDpBplSvFWGeWKcOE90QQo42Yuz9AlK0E4d1QJgto26cCrWHFvGSsTrGpjD4WjDjlKV6zTf519OwPqClfiqjvL2bJpdE4HDNeaHTeDmvvZhV9pT8GAGCpqE39gDZDRF17ijyS2+dsZwrQGRrc5WQN//byw1T/h7BmV3vSAJpsVqyr7wCpVRgrFrKKj9q8ahkoOln6pyl6Q9lfmti2DpVCb6qGWITEM4JbdheOoLLX+bEbE8wr3tTt+Mx8pxXbql8d9MVu9/S5HA+Y1rKoLhbrcdyuEYWUNq19rAUGo6GsLl3OXSbOJw5RKIILxviB2V7rcjFhQN5q2ldNfamMDBOKMDoimWggrj8C8nVUUsnxem5Nihhj4TXQptOR+LXiHayZDUxV02t0qMvEqdt1PTXOeXnKSFONnZeP33Cy0Mxa1wcF9sBfyppXtJD8HYpQgVIeZor9OHw23Hj5r37HMml5TUu2odKn/mxxlwgOpY01LkXW2NYSmkB8xHBKuxlPR0s+3t5E3MVlx26SQDxBjOWvzrjkdCrIDZRVUaEveSur3SY1st7PJrmRGYxp8XUtIGHYyx5+e9gDXf8uHRLyXlHDpLSfG2JpdLtqgrJRScBrYqxSy1+RbKaVo7n6SCZjItBzjockcxAL026AmSjtvH7Q3hurc1Wqsat2eDWgwfFMFAyJgtWbOy/B9ZZakfAWv+cSRUYGlGlKT0JtvfQVsp/6Jiq0rcjWYpXvasPdD0BZJ5W47uJAxCHWKua19a1mp9JGDKBi9aE0KAJGTIX5BEP8+9GmKhj2gZbI8EpS54Y/61isLL8Stilyo1h0aMY43xQxM/hx4Z5+JMHwQYzGWu09MOUrwktKCNNQDFgPeS4TEFMgzdWbMaomm3sG4UBOHzpNYk+aRbCka7cQ81nWzifKoDIgsw6Cz+yEyfb59 jconb122 3gqxSnCWafMPsAzYSOgmhcxbSGe9H8xgEXy1c1YwMj7lqDuxV2jGxLcdWJi8mMx/gmj3tUB7nVtyqRK3O5Gq5+p9PaFXMSQQthQzJ3p3K+NAuXHFgChT9AH8QpyApo01XmGnOi/DL/Qi85AM= 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: From: ZhangPeng Use helper macro K() to improve code readability. No functional modification involved. Signed-off-by: ZhangPeng Reviewed-by: David Hildenbrand --- mm/shmem.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/mm/shmem.c b/mm/shmem.c index 30e96dcd71a2..7a0c1e19d9f8 100644 --- a/mm/shmem.c +++ b/mm/shmem.c @@ -3881,8 +3881,7 @@ static int shmem_show_options(struct seq_file *seq, struct dentry *root) struct mempolicy *mpol; if (sbinfo->max_blocks != shmem_default_max_blocks()) - seq_printf(seq, ",size=%luk", - sbinfo->max_blocks << (PAGE_SHIFT - 10)); + seq_printf(seq, ",size=%luk", K(sbinfo->max_blocks)); if (sbinfo->max_inodes != shmem_default_max_inodes()) seq_printf(seq, ",nr_inodes=%lu", sbinfo->max_inodes); if (sbinfo->mode != (0777 | S_ISVTX))