From patchwork Thu Jul 28 12:19:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Miaohe Lin X-Patchwork-Id: 12931193 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 E5E3BC19F29 for ; Thu, 28 Jul 2022 12:20:11 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 45CFF8E0002; Thu, 28 Jul 2022 08:20:10 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 38EAA6B0075; Thu, 28 Jul 2022 08:20:10 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0D0626B0071; Thu, 28 Jul 2022 08:20:10 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id DFF576B0072 for ; Thu, 28 Jul 2022 08:20:09 -0400 (EDT) Received: from smtpin11.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id B21DB160F28 for ; Thu, 28 Jul 2022 12:20:09 +0000 (UTC) X-FDA: 79736415738.11.E065C05 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by imf31.hostedemail.com (Postfix) with ESMTP id D616E200AC for ; Thu, 28 Jul 2022 12:20:08 +0000 (UTC) Received: from canpemm500002.china.huawei.com (unknown [172.30.72.55]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4LtqRn5VSZzmVJh; Thu, 28 Jul 2022 20:18:13 +0800 (CST) Received: from huawei.com (10.175.124.27) by canpemm500002.china.huawei.com (7.192.104.244) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Thu, 28 Jul 2022 20:20:04 +0800 From: Miaohe Lin To: CC: , , , , Subject: [PATCH 0/6] A few cleanup patches for hugetlb_cgroup Date: Thu, 28 Jul 2022 20:19:43 +0800 Message-ID: <20220728121949.20985-1-linmiaohe@huawei.com> X-Mailer: git-send-email 2.23.0 MIME-Version: 1.0 X-Originating-IP: [10.175.124.27] X-ClientProxiedBy: dggems703-chm.china.huawei.com (10.3.19.180) To canpemm500002.china.huawei.com (7.192.104.244) X-CFilter-Loop: Reflected ARC-Authentication-Results: i=1; imf31.hostedemail.com; dkim=none; spf=pass (imf31.hostedemail.com: domain of linmiaohe@huawei.com designates 45.249.212.187 as permitted sender) smtp.mailfrom=linmiaohe@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1659010809; a=rsa-sha256; cv=none; b=gLPXo1UUvOftH9gpFcmi3cgpfUlQ9t90GgDJmI7iV7lCPzvMfk1JR6P9vniKcYNdKTV/MD S80GWIFMm45MbcAtwxBhxJLPEJV4/IDnp7zBgxXazPsfYUQd8DDqpTqp8lkIoXTlJkeYqu Cl8DjETYXGCEWWVrGEzbq0URJFqq/hk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1659010809; 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: references; bh=Pxj6UGCsqN35zeTwljI4uizhjsVfablpmXEMgMxXUa0=; b=ZzWcDlzKNva3ykWCqAixBU9bIDSQNtqODbi1YVIG6UJTzt17uATVyG5By0o81oO+scy0Hy BX1siCnoXnWGILYbbOvUSiO5Vj70RHxI/APNHGSfnuobg0BOfQBLfWDpT4Brfg5vBrl/Z8 LZwHkfyxbL+dZ4w1JSyNdjZgsK9N1lQ= Authentication-Results: imf31.hostedemail.com; dkim=none; spf=pass (imf31.hostedemail.com: domain of linmiaohe@huawei.com designates 45.249.212.187 as permitted sender) smtp.mailfrom=linmiaohe@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com X-Rspam-User: X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: D616E200AC X-Stat-Signature: gfebrfh7x9hcbgkkaobfdqhyet5zhc3w X-HE-Tag: 1659010808-756863 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: Hi everyone, This series contains a few cleaup patches to remove unneeded header file, use helper macro, remove unneeded return value and so on. More details can be found in the respective changelogs. Thanks! Miaohe Lin (6): hugetlb_cgroup: remove unneeded nr_pages > 0 check hugetlb_cgroup: remove unneeded header file hugetlb_cgroup: hugetlbfs: use helper macro SZ_1{K,M,G} hugetlb_cgroup: remove unneeded return value hugetlb_cgroup: use helper macro NUMA_NO_NODE hugetlb_cgroup: use helper for_each_hstate and hstate_index include/linux/hugetlb_cgroup.h | 19 ++++++++----------- mm/hugetlb_cgroup.c | 28 ++++++++++++---------------- 2 files changed, 20 insertions(+), 27 deletions(-)