Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp4047913imu; Sat, 19 Jan 2019 01:03:20 -0800 (PST) X-Google-Smtp-Source: ALg8bN59As+Wl3NBGlJD1oC5UTFP4JpI48cIgfVif52skpQgvX0ubdJR82TauYum8pevLCYCZ1EF X-Received: by 2002:a17:902:e08b:: with SMTP id cb11mr9168482plb.263.1547888600234; Sat, 19 Jan 2019 01:03:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547888600; cv=none; d=google.com; s=arc-20160816; b=actm7TQbcrEOupCRRebF5fup5T4KqHu8bqsYpYhY14ZkTRv6U121u2TrfD3WqxQzaY KkPoXYNv+m9QjeWgIGH1OeNMa4LL+ZIchU44QL1MxZIOjv89/CBhw6fURvIxHYtU3DDP qyAgoLS+eVZpu9RyneVJ7eVHqw1ag1lCwG1X/KyngSeZKxs/KHHvIW5wNv/SYbpynQUK x7IB/uGhoq7IyL/rV9b7pqgFUFirjPFP6Tv49EpGxbQEMPAM7t+Chqirz54Z059R/+l6 J9xjKnHIDLyB5+Qhod3wOLw1KyulGT6jCljlhTR/unMfJHp2MxtGo5qxpLFZrgzhZcyc Tlew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=xbXvhIn/cXJxmUDL4tzjQwkeVloSqzbvF+g+6bZzRzw=; b=cY7VhRl0NJUNYJdhb7x33bt/WgGSEuPfCwcCKUj/zE1E8sWBv9h0MEbHcFiYOUdswz /tseh0MTnSsZgnGUn7XQYyffqNLlRF//T3/dIVVEWxLkJkXRPTBTatSlrsLyRKZEDdYk Car0b9z2xJI9nPHJgABTEqKAnGMldfwQkq1QvJyjGVitWIzYI0Gti9gf5doOc42+R3Tb iQsYvFMsEEN86XhRuMkI7yh2V6T97OdUFuW8tIKkzkb6VBl4KAjrOQbHOloyWJ0sP1iA d2cz1Tiw506vws1WfkXgsf6wDSC91A3ZuNZLG4xpvqo/5rtACkCsJ8wMCBLPjCmXBn+d RuIQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=UiZ27jda; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q2si6253663plr.204.2019.01.19.01.03.03; Sat, 19 Jan 2019 01:03:20 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=UiZ27jda; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727993AbfASJBf (ORCPT + 99 others); Sat, 19 Jan 2019 04:01:35 -0500 Received: from mail.kernel.org ([198.145.29.99]:52958 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727733AbfASJBe (ORCPT ); Sat, 19 Jan 2019 04:01:34 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9DD8D2086D; Sat, 19 Jan 2019 09:01:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1547888493; bh=6zgR7fa0U/P64hIkHedHMQoG4dqHI2TAlhjgQKiXG24=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=UiZ27jdac9oepbHvgd6MTRNKXsjc+7+IxIZST2JWTC9CoR6ubmuebt2EeRfMkuqp1 G9ECAP8ftdykF2IdwA1FTYY1UUtnJ4IuVBEO0skOfxMlndK9etbiiIARti+SCctVVq BIM4CDPF26HRP4mYkw7ZoNt3yWuP33meTpprDxU0= Date: Sat, 19 Jan 2019 10:01:29 +0100 From: Greg Kroah-Hartman To: Dan Williams Cc: "Rafael J. Wysocki" , Keith Busch , Linux Kernel Mailing List , ACPI Devel Maling List , Linux Memory Management List , Dave Hansen Subject: Re: [PATCHv4 05/13] Documentation/ABI: Add new node sysfs attributes Message-ID: <20190119090129.GC10836@kroah.com> References: <20190116175804.30196-1-keith.busch@intel.com> <20190116175804.30196-6-keith.busch@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.11.2 (2019-01-07) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jan 18, 2019 at 01:08:02PM -0800, Dan Williams wrote: > On Thu, Jan 17, 2019 at 3:41 AM Rafael J. Wysocki wrote: > > > > On Wed, Jan 16, 2019 at 6:59 PM Keith Busch wrote: > > > > > > Add entries for memory initiator and target node class attributes. > > > > > > Signed-off-by: Keith Busch > > > > I would recommend combining this with the previous patch, as the way > > it is now I need to look at two patches at the time. :-) > > > > > --- > > > Documentation/ABI/stable/sysfs-devices-node | 25 ++++++++++++++++++++++++- > > > 1 file changed, 24 insertions(+), 1 deletion(-) > > > > > > diff --git a/Documentation/ABI/stable/sysfs-devices-node b/Documentation/ABI/stable/sysfs-devices-node > > > index 3e90e1f3bf0a..a9c47b4b0eee 100644 > > > --- a/Documentation/ABI/stable/sysfs-devices-node > > > +++ b/Documentation/ABI/stable/sysfs-devices-node > > > @@ -90,4 +90,27 @@ Date: December 2009 > > > Contact: Lee Schermerhorn > > > Description: > > > The node's huge page size control/query attributes. > > > - See Documentation/admin-guide/mm/hugetlbpage.rst > > > \ No newline at end of file > > > + See Documentation/admin-guide/mm/hugetlbpage.rst > > > + > > > +What: /sys/devices/system/node/nodeX/classY/ > > > +Date: December 2018 > > > +Contact: Keith Busch > > > +Description: > > > + The node's relationship to other nodes for access class "Y". > > > + > > > +What: /sys/devices/system/node/nodeX/classY/initiator_nodelist > > > +Date: December 2018 > > > +Contact: Keith Busch > > > +Description: > > > + The node list of memory initiators that have class "Y" access > > > + to this node's memory. CPUs and other memory initiators in > > > + nodes not in the list accessing this node's memory may have > > > + different performance. > > > > This does not follow the general "one value per file" rule of sysfs (I > > know that there are other sysfs files with more than one value in > > them, but it is better to follow this rule as long as that makes > > sense). > > > > > + > > > +What: /sys/devices/system/node/nodeX/classY/target_nodelist > > > +Date: December 2018 > > > +Contact: Keith Busch > > > +Description: > > > + The node list of memory targets that this initiator node has > > > + class "Y" access. Memory accesses from this node to nodes not > > > + in this list may have differet performance. > > > -- > > > > Same here. > > > > And if you follow the recommendation given in the previous message > > (add "initiators" and "targets" subdirs under "classX"), you won't > > even need the two files above. > > This recommendation is in conflict with Greg's feedback about kobject > usage. If these are just "vanity" subdirs I think it's better to have > a multi-value sysfs file. This "list" style is already commonplace for > the /sys/devices/system hierarchy. If you do a subdirectory "correctly" (i.e. a name for an attribute group), that's fine. Just do not ever create a kobject just for a subdir, that will mess up userspace. And I hate the "multi-value" sysfs files, where at all possible, please do not copy past bad mistakes there. If you can make them individual files, please do that, it makes it easier to maintain and code the kernel for. thanks, greg k-h