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 C12A8C4167E for ; Tue, 18 Oct 2022 08:39:58 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 0BC546B0072; Tue, 18 Oct 2022 04:39:58 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 06C886B0075; Tue, 18 Oct 2022 04:39:58 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id E76556B0078; Tue, 18 Oct 2022 04:39:57 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id D5D816B0072 for ; Tue, 18 Oct 2022 04:39:57 -0400 (EDT) Received: from smtpin14.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id A932180F10 for ; Tue, 18 Oct 2022 08:39:57 +0000 (UTC) X-FDA: 80033422434.14.88A202E Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by imf08.hostedemail.com (Postfix) with ESMTP id 2BD1B160037 for ; Tue, 18 Oct 2022 08:39:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1666082396; x=1697618396; h=from:to:cc:subject:references:date:in-reply-to: message-id:mime-version; bh=yRwREJZ6WW5Zu2uLpSYw5X7MeZzm/Wb7ut6LwZ5B140=; b=BXIQ9ShSnpOjRrdkn7YJSt/dU2YtZK3JQ4lSw+nHm+ibbWmh/n55Tcru cZNlhr8XmbTy5V4RNBYiWaVBCAyJnLa6mHm6jPXRN+eSs5DfQb8lKm5f5 fnL39ypBLxvJLtkiAYnBEz4Txk/GfIMuYliOtV5hbw7Rm+bATKXqXp0st QZefrX5K6dYeyG0fLJi23li1Ir8jaZqIUoyU30RARh4nuCcOqkz0Lb8mz d/ML3ey6kPCwYCFzRXNcT+sr9grf6efvBg2QPecI4Tl/AnpHTKp9zFhRY LpcgnRUhmFmMQopVC96hl/qPVttVgJ2+XWMjDgX/e6m0xBdQZzMYwaOCs w==; X-IronPort-AV: E=McAfee;i="6500,9779,10503"; a="332580772" X-IronPort-AV: E=Sophos;i="5.95,193,1661842800"; d="scan'208";a="332580772" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Oct 2022 01:39:54 -0700 X-IronPort-AV: E=McAfee;i="6500,9779,10503"; a="957674218" X-IronPort-AV: E=Sophos;i="5.95,193,1661842800"; d="scan'208";a="957674218" Received: from yhuang6-desk2.sh.intel.com (HELO yhuang6-desk2.ccr.corp.intel.com) ([10.238.208.55]) by fmsmga005-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Oct 2022 01:39:50 -0700 From: "Huang, Ying" To: Wei Xu Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrew Morton , "Aneesh Kumar K . V" , Alistair Popple , Bharata B Rao , Dan Williams , Dave Hansen , Davidlohr Bueso , Hesham Almatary , Jagdish Gediya , Johannes Weiner , Jonathan Cameron , Michal Hocko , Tim Chen , Yang Shi Subject: Re: [RFC] memory tier, sysfs: rename attribute "nodes" to "nodes_list" References: <20221018052541.265708-1-ying.huang@intel.com> Date: Tue, 18 Oct 2022 16:39:11 +0800 In-Reply-To: (Wei Xu's message of "Mon, 17 Oct 2022 23:27:18 -0700") Message-ID: <8735blsez4.fsf@yhuang6-desk2.ccr.corp.intel.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=ascii ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1666082396; a=rsa-sha256; cv=none; b=f3t2r3RE/O51czhtbnXGo5asUQPZGrb5qlAXibwDtsuYkwgrYN6MYOgAJGy2lVfkSLakhn WJtKWLskt+oIjfAalV+2YZjYBA+RxVULkobt4kFPVFBMdUE9u3AtiW99menAy6+IbbXPaN w5bZLn5ilQlpUcovohbDUNV5UUFsq1w= ARC-Authentication-Results: i=1; imf08.hostedemail.com; dkim=none ("invalid DKIM record") header.d=intel.com header.s=Intel header.b=BXIQ9ShS; spf=pass (imf08.hostedemail.com: domain of ying.huang@intel.com designates 192.55.52.88 as permitted sender) smtp.mailfrom=ying.huang@intel.com; dmarc=pass (policy=none) header.from=intel.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1666082396; 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: in-reply-to:in-reply-to:references:references:dkim-signature; bh=LTz3cbIlJP93OymT7wn0Z45fvxgse9b+O/w1XC3C51g=; b=3MQ37Je+e2j6C6ZqsUPICF/Xg0cUN4p4yBZekGN8D+C/msADX6DM2p2UvRThGgzIeTUZPI 9axoSqkL/MXWKFOZ59a4Au4IRJ5ANEnh0MKFrB2jF+a/XHgGKiacqRWLa004P2x0L/pvj/ QSg2xh58c8wRLzizNU9Bv3QL3/CMxIU= X-Rspam-User: Authentication-Results: imf08.hostedemail.com; dkim=none ("invalid DKIM record") header.d=intel.com header.s=Intel header.b=BXIQ9ShS; spf=pass (imf08.hostedemail.com: domain of ying.huang@intel.com designates 192.55.52.88 as permitted sender) smtp.mailfrom=ying.huang@intel.com; dmarc=pass (policy=none) header.from=intel.com X-Stat-Signature: dcnxweft6zs3yt111nnmwf88icy8s1d3 X-Rspamd-Queue-Id: 2BD1B160037 X-Rspamd-Server: rspam10 X-HE-Tag: 1666082395-729892 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: Wei Xu writes: > How about "nodelist", instead of "nodes_list"? It is more concise and > follows the convention of: > > /sys/devices/system/nodes/node0/cpulist Sounds good to me. It seems that cpumap/cpulist is another pair of mask/list. /sys/devices/system/node/node0/cpumap /sys/devices/system/node/node0/cpulist /sys/devices/system/cpu/cpu0/cache/index1/shared_cpu_map /sys/devices/system/cpu/cpu0/cache/index1/shared_cpu_list Best Regards, Huang, Ying > On Mon, Oct 17, 2022 at 10:26 PM Huang Ying wrote: >> >> In sysfs, we use attribute name "cpus" for cpu mask and "cpus_list" >> for cpu list. For example, in my system, >> >> $ cat /sys/devices/system/cpu/cpu2/topology/core_cpus >> 0,00100004 >> $ cat /sys/devices/system/cpu/cpu2/topology/core_cpus_list >> 2,20 >> >> It looks reasonable to use "nodes" for node mask and "nodes_list" for >> node list. So, rename the attribute to follow the naming convention. >> >> Signed-off-by: "Huang, Ying" >> Cc: Aneesh Kumar K.V >> Cc: Alistair Popple >> Cc: Bharata B Rao >> Cc: Dan Williams >> Cc: Dave Hansen >> Cc: Davidlohr Bueso >> Cc: Hesham Almatary >> Cc: Jagdish Gediya >> Cc: Johannes Weiner >> Cc: Jonathan Cameron >> Cc: Michal Hocko >> Cc: Tim Chen >> Cc: Wei Xu >> Cc: Yang Shi >> --- >> Documentation/ABI/testing/sysfs-kernel-mm-memory-tiers | 4 ++-- >> mm/memory-tiers.c | 8 ++++---- >> 2 files changed, 6 insertions(+), 6 deletions(-) >> >> diff --git a/Documentation/ABI/testing/sysfs-kernel-mm-memory-tiers b/Documentation/ABI/testing/sysfs-kernel-mm-memory-tiers >> index 45985e411f13..af07e166f559 100644 >> --- a/Documentation/ABI/testing/sysfs-kernel-mm-memory-tiers >> +++ b/Documentation/ABI/testing/sysfs-kernel-mm-memory-tiers >> @@ -10,7 +10,7 @@ Description: A collection of all the memory tiers allocated. >> >> >> What: /sys/devices/virtual/memory_tiering/memory_tierN/ >> - /sys/devices/virtual/memory_tiering/memory_tierN/nodes >> + /sys/devices/virtual/memory_tiering/memory_tierN/nodes_list >> Date: August 2022 >> Contact: Linux memory management mailing list >> Description: Directory with details of a specific memory tier >> @@ -21,5 +21,5 @@ Description: Directory with details of a specific memory tier >> A smaller value of N implies a higher (faster) memory tier in the >> hierarchy. >> >> - nodes: NUMA nodes that are part of this memory tier. >> + nodes_list: NUMA nodes that are part of this memory tier. >> >> diff --git a/mm/memory-tiers.c b/mm/memory-tiers.c >> index f116b7b6333e..8dbfe9ec87d5 100644 >> --- a/mm/memory-tiers.c >> +++ b/mm/memory-tiers.c >> @@ -131,8 +131,8 @@ static void memory_tier_device_release(struct device *dev) >> kfree(tier); >> } >> >> -static ssize_t nodes_show(struct device *dev, >> - struct device_attribute *attr, char *buf) >> +static ssize_t nodes_list_show(struct device *dev, >> + struct device_attribute *attr, char *buf) >> { >> int ret; >> nodemask_t nmask; >> @@ -143,10 +143,10 @@ static ssize_t nodes_show(struct device *dev, >> mutex_unlock(&memory_tier_lock); >> return ret; >> } >> -static DEVICE_ATTR_RO(nodes); >> +static DEVICE_ATTR_RO(nodes_list); >> >> static struct attribute *memtier_dev_attrs[] = { >> - &dev_attr_nodes.attr, >> + &dev_attr_nodes_list.attr, >> NULL >> }; >> >> -- >> 2.35.1 >>