[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240831095840.4173362-4-lihongbo22@huawei.com>
Date: Sat, 31 Aug 2024 17:58:39 +0800
From: Hongbo Li <lihongbo22@...wei.com>
To: <kees@...nel.org>, <andy@...nel.org>, <willemdebruijn.kernel@...il.com>,
<jasowang@...hat.com>, <davem@...emloft.net>, <edumazet@...gle.com>,
<kuba@...nel.org>, <pabeni@...hat.com>, <akpm@...ux-foundation.org>
CC: <linux-hardening@...r.kernel.org>, <netdev@...r.kernel.org>,
<linux-mm@...ck.org>, <lihongbo22@...wei.com>
Subject: [PATCH -next 3/4] mm: page_alloc: Make use of str_off_on helper
The helper str_off_on is introduced to reback "off/on"
string literal. We can use str_off_on() helper instead
of open coding the same.
Signed-off-by: Hongbo Li <lihongbo22@...wei.com>
---
mm/page_alloc.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/mm/page_alloc.c b/mm/page_alloc.c
index 04a90dfbce09..8adda0b67253 100644
--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
@@ -5517,10 +5517,9 @@ void __ref build_all_zonelists(pg_data_t *pgdat)
page_group_by_mobility_disabled = 1;
else
page_group_by_mobility_disabled = 0;
-
pr_info("Built %u zonelists, mobility grouping %s. Total pages: %ld\n",
nr_online_nodes,
- page_group_by_mobility_disabled ? "off" : "on",
+ str_off_on(page_group_by_mobility_disabled),
vm_total_pages);
#ifdef CONFIG_NUMA
pr_info("Policy zone: %s\n", zone_names[policy_zone]);
--
2.34.1
Powered by blists - more mailing lists