Received: by 2002:ab2:6d45:0:b0:1fb:d597:ff75 with SMTP id d5csp125650lqr; Wed, 5 Jun 2024 00:32:46 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUYa+BpvxdI0KDORDxi3lN44iXqxdqOkC+W0jQjz66fMWC1PDWgOWh31hc+LudUqG/UZ4UmeKz26IiO/aM4Y7YADpZH0Z626O1JeXgVqA== X-Google-Smtp-Source: AGHT+IGEOz70cZvIqPzp1V735Zt6PzHG6dyD+hgMw3+rp2kx+CLUOUNT8aiO2oO0haFbhlmMCR4f X-Received: by 2002:a05:6a20:8404:b0:1af:cfc2:8069 with SMTP id adf61e73a8af0-1b2b6ecb7ecmr2030023637.4.1717572766115; Wed, 05 Jun 2024 00:32:46 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717572766; cv=pass; d=google.com; s=arc-20160816; b=M4/RdKUDtv+m7MC9xH3wPNCZYiZ6yeoz0spkWD29qj/sHjvVeVVVtQi5+BeTcGef24 yUNY7YKuD6Owd3j14o1rSiq0Rr9KXC01febb41k9gwNmTSuS517qCJ7d9x1u3Ht26ShC OwJoPIibhSV5ERaQiaXENlbyD2zT/YfsYUb5sMgSTq7bxZ5e8Sm1s5KvSzhMCNy+UpN8 5SvSd3HJvWv03qdiFOFDGXs2cdqHkaU8E6NQvxyVUnKuDTWShL9LoLkS4n097K70SkOM 2Q5WOBIm5BikDW3e20/IsLfiCEMSVplMJzN6uAnnxcDX25rqCiXpEpR2x2knhWzkuFGq MpfQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from; bh=3QA1pxpJcoTB9AAzfnCBB2q2/7a69Rn/JMbWt7qcJ5Y=; fh=TgsdcG+EnP0bZGRdmPJBfZxaEjhDIWRwATd+8h9YUAE=; b=bzUAN+h2wdmo/oojjQIqRxecrrs/f8yy2QjD+9hDZIE9b4gm/CIAgtqYRe4LeSgdqp GdPaLDAjOlZLCD0aHd/tO43XNtcd4IANsSHgTqznGlF+bmBHLa6tTqhujGPomP+aA5w5 JVLeo7830OCVpp47utuY4gRPE524u1HzRD36+UW9lBlShvhXjJBk+k3DUicZPOmkDKSb z+T6ewgwxHNODjqEq8Ucj/Q0uvFX641d8Ec/1P7MLaCcEgh9dZISufGWDBdTH9XsaWUS BZtk48Ww2WmrGC7JJqEjAGvdu1vsWj8HdvdVyVkFHGtHzhzmdQDJXmLEABgEBsk3Bi39 DtBA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-201840-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-201840-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id 41be03b00d2f7-6c35c17d1d6si2053413a12.641.2024.06.05.00.32.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 05 Jun 2024 00:32:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-201840-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-201840-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-201840-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 92B54B29535 for ; Wed, 5 Jun 2024 07:09:19 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B6CD218C32E; Wed, 5 Jun 2024 07:09:12 +0000 (UTC) Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 81E4C190490 for ; Wed, 5 Jun 2024 07:09:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.187 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717571352; cv=none; b=tNRqwb4h9TF1xfasK5noOsGCjl3w+LoR2dZdc2jcPg///WGOqjAZKbOHt7r5g5VRXL+cwF4HjHMVgDh+XFNbGugakaDWcI5JRDM3HIR7/4bT/cqTIPB2gJ6MJRBO+ashCq5oEqlI5M2cT3HCy/imfjj7pfH3MJ5Vt/rXhIQ6WWA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717571352; c=relaxed/simple; bh=CfJUbCNxbSlksYpJxwKjszpSqNrdUgSd7FuWLKh1Jzw=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=usIArgfaadDIC70UZArziS1zSzK4YymNOaa2Iu538nbsfKUJuzarCLUcP4oATz6lucp4QzNQUPYcg3BxAdVMLI5T15QiWFqLIMc3wkAKP99/F77vB6rZFiW3krs/ivazgJNciwyWi3hxvKqQZKIqG99OfwnpTiAAaf38v7TTses= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com; spf=pass smtp.mailfrom=huawei.com; arc=none smtp.client-ip=45.249.212.187 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Received: from mail.maildlp.com (unknown [172.19.163.174]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4VvJPg0mhTzwRQQ; Wed, 5 Jun 2024 15:05:11 +0800 (CST) Received: from dggpeml500023.china.huawei.com (unknown [7.185.36.114]) by mail.maildlp.com (Postfix) with ESMTPS id 8DCFA140428; Wed, 5 Jun 2024 15:09:07 +0800 (CST) Received: from hulk-vt.huawei.com (10.67.174.26) by dggpeml500023.china.huawei.com (7.185.36.114) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Wed, 5 Jun 2024 15:09:07 +0800 From: Xiu Jianfeng To: , CC: , Subject: [PATCH v2 -next 0/3] mm/hugetlb_cgroup: rework on cftypes Date: Wed, 5 Jun 2024 07:01:30 +0000 Message-ID: <20240605070133.1941677-1-xiujianfeng@huawei.com> X-Mailer: git-send-email 2.34.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To dggpeml500023.china.huawei.com (7.185.36.114) Hi, This patchset provides an intuitive view of the control files through static templates of cftypes, improve the readability of the code. Changes from v1: - Fix smatch warnings of 'tmpl->name' Xiu Jianfeng (3): mm/hugetlb_cgroup: identify the legacy using cgroup_subsys_on_dfl() mm/hugetlb_cgroup: prepare cftypes based on template mm/hugetlb_cgroup: switch to the new cftypes include/linux/hugetlb.h | 5 - mm/hugetlb_cgroup.c | 302 ++++++++++++++++++++++------------------ 2 files changed, 164 insertions(+), 143 deletions(-) -- 2.34.1