Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2287166imu; Fri, 23 Nov 2018 07:08:16 -0800 (PST) X-Google-Smtp-Source: AFSGD/VJ2WnTyymrlJsVng1YuKUxecQt1b54n/L3Exw4PGN57HUa8OHEB/MUNA/mr2keJqZ/c4Fw X-Received: by 2002:a17:902:2868:: with SMTP id e95mr14138500plb.317.1542985696733; Fri, 23 Nov 2018 07:08:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542985696; cv=none; d=google.com; s=arc-20160816; b=tsjE7rbvj93VJ81VrzvCxAUpSpaKRkiz86MMpa36CVMg1S4Ofl71Ptk2/MZ9ALYLw1 71TIvFRnZamvsmRL4nY5RZLkCmEOlsyNS4NTGrdb00Tn1W9R7JDAoda+p5SdpTSJcZpQ 36I5FugNcyW3CCmNegncw5kLdcxy45P+BtdClFChUJOc8p1d1DEZoklvQxWMBJzqJlRM HtDaJyc1tZQLcUbUmVhhnlyh3Cu2/3GSAZBmljIrUu4v67KEfTysAyGYud9mLGBkdTWO og6n/VDsBNGLqUj2kB3KVJlHXLXEvnhnJWVrBJ+dEhUnUygfkPE2wSeTmdqkACLZ/bLa e77w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=6y6D1+2Y+wH8c6rq/YgJ5JIkcFuUIska5AzEz7fabTw=; b=hFWmad9xOFLDptKn2vt+RFwds0SYzhlsOv1RAQaehddnJ/9GLLbdN9RcYg7LKhr2Uf FLywiTTgxhWGl8hUOHeItpNRqX0MwnYOuinzRxJ0eJHqi6bBRHRigYtTtZrnxABetVr0 16pf5ygd5hGW4hLDv9zXxcBdKiaDMPj8VkF+0zZzfojnLW8H8/ky/epYo+LsaYb3ULp7 cQGBmWOHaqk2L9PpSvuEVN5qzTgdBdez8qoO4oc0axERq12GeadbmYnFUTFcd+Gtgcs6 GC6+TbOKopO0jTl/007mLbIjJ0vexpVPkcFue2orhnOivJdYunfbb0RkHrct7iwwQ+bZ kGbg== ARC-Authentication-Results: i=1; mx.google.com; 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 b36si26348462pgl.596.2018.11.23.07.07.41; Fri, 23 Nov 2018 07:08:16 -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; 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 S2394980AbeKVWb0 (ORCPT + 99 others); Thu, 22 Nov 2018 17:31:26 -0500 Received: from foss.arm.com ([217.140.101.70]:46574 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730549AbeKVWbZ (ORCPT ); Thu, 22 Nov 2018 17:31:25 -0500 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id A9831361A; Thu, 22 Nov 2018 03:52:21 -0800 (PST) Received: from [10.1.26.189] (p8cg001049571a15.cambridge.arm.com [10.1.26.189]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 469653F5A0; Thu, 22 Nov 2018 03:52:20 -0800 (PST) Subject: Re: [PATCH 0/7] ACPI HMAT memory sysfs representation To: Dave Hansen , Keith Busch , linux-kernel@vger.kernel.org, linux-acpi@vger.kernel.org, linux-mm@kvack.org Cc: Greg Kroah-Hartman , Rafael Wysocki , Dan Williams References: <20181114224902.12082-1-keith.busch@intel.com> <1ed406b2-b85f-8e02-1df0-7c39aa21eca9@arm.com> <4ea6e80f-80ba-6992-8aa0-5c2d88996af7@intel.com> From: Anshuman Khandual Message-ID: Date: Thu, 22 Nov 2018 17:22:19 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/19/2018 11:07 PM, Dave Hansen wrote: > On 11/18/18 9:44 PM, Anshuman Khandual wrote: >> IIUC NUMA re-work in principle involves these functional changes >> >> 1. Enumerating compute and memory nodes in heterogeneous environment (short/medium term) > > This patch set _does_ that, though. > >> 2. Enumerating memory node attributes as seen from the compute nodes (short/medium term) > > It does that as well (a subset at least). > > It sounds like the subset that's being exposed is insufficient for yo > We did that because we think doing anything but a subset in sysfs will > just blow up sysfs: MAX_NUMNODES is as high as 1024, so if we have 4 > attributes, that's at _least_ 1024*1024*4 files if we expose *all* > combinations. Each permutation need not be a separate file inside all possible NODE X (/sys/devices/system/node/nodeX) directories. It can be a top level file enumerating various attribute values for a given (X, Y) node pair based on an offset something like /proc/pid/pagemap. > > Do we agree that sysfs is unsuitable for exposing attributes in this manner? > Yes, for individual files. But this can be worked around with an offset based access from a top level global attributes file as mentioned above. Is there any particular advantage of using individual files for each given attribute ? I was wondering that a single unsigned long (u64) will be able to pack 8 different attributes where each individual attribute values can be abstracted out in 8 bits.