Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp4196826pxb; Tue, 17 Nov 2020 14:06:36 -0800 (PST) X-Google-Smtp-Source: ABdhPJyWXmMo60q6GjhU2WbwJjxB2ZOU5ia2Gzot9Uv5pQVda9GzqkuORrdo1B8mu7ABgpw4NDyE X-Received: by 2002:a05:6402:1ca6:: with SMTP id cz6mr22376247edb.129.1605650796579; Tue, 17 Nov 2020 14:06:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605650796; cv=none; d=google.com; s=arc-20160816; b=qiFCG6VK6ToBT7otVNq8IfiW2VxC520Cd8QyLHm/TVQUOjzTXK/jhDW4RlSzTyMfIc Nbl8qudjaUX0b2kqQjZkriV9Ub/IC9xSrQsiIxAGdCWMP4fSoMr/iAH1p//4S4hlTOmm vz2/swZ3FUc0nXjGbL8lZxJN3Vyfx3jc2IQ5Zzz3RA7ad7brsmkaA7xaKNmjbJsqu4AI yp6werWKjEooxzxJgcfyc9HzjhM92rv5Jg9ahx/9rpizZpiYDMFvGcHLlJa65vAj2R1d NLX6yNBX+rHvewrsQHZ/ApZ147youCk9DRdTkTOtfwQE1ZG34AWNexFU3M+8ryuIC3l+ Jv+A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:ironport-sdr:ironport-sdr; bh=XsqJiOglDwoN5qu5RtymSnQ6eLarXzW3BP4kl/sKVfk=; b=lTAMgjUNDwa8orVm8TDd3roK0VOMXVmTceGOPv9kn2zu49J4ZH2YxaJvUy7exX+ng1 3uO22Uu1jvPVRKJZ0de3vESYDhYadhvFlxE1bHCcVRr+XXmjqalCREbrLMOLu+8C4mpn +JrJ4btnhxNN28zogmfBJo7v7u0rnapoh6d/jz+Kt6EvIsYlSt3/1IwnzjThsYEiQNEH b9E2ae1PlWCw9Glz/XFbZsjAm6WqHQ2IYdeXVERy4AFWfTvc8QkuqAJgvFVNAAtLOonP NgfFUiT26DTvJxL0CYTlAgNXucNfiXraqGHiMWxAdclqUJzPB24yAjSVQnhxeST64XQC 2TdA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q23si7695241edb.184.2020.11.17.14.06.14; Tue, 17 Nov 2020 14:06:36 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728411AbgKQWEe (ORCPT + 99 others); Tue, 17 Nov 2020 17:04:34 -0500 Received: from mga04.intel.com ([192.55.52.120]:45084 "EHLO mga04.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726498AbgKQWEe (ORCPT ); Tue, 17 Nov 2020 17:04:34 -0500 IronPort-SDR: nxFfyr/0MkUGw5U/y2m6u60BZas5n9MdE5q+eh41WiNembKZ+ekCKz0/q11/i0PTe+oSTxnJgv UNQEIzQ5EAmA== X-IronPort-AV: E=McAfee;i="6000,8403,9808"; a="168449692" X-IronPort-AV: E=Sophos;i="5.77,486,1596524400"; d="scan'208";a="168449692" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Nov 2020 14:04:33 -0800 IronPort-SDR: bbizNljBmwqoOwvQ9PCE3yCIfYsp8o1XBVMRhgfWUd7IkgM/UfthgaecuZ9AqA2+sG55yXHIDt 50ffQ+21VmMw== X-IronPort-AV: E=Sophos;i="5.77,486,1596524400"; d="scan'208";a="430602888" Received: from rchatre-mobl3.amr.corp.intel.com (HELO [10.212.24.101]) ([10.212.24.101]) by fmsmga001-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Nov 2020 14:04:30 -0800 Subject: Re: [PATCH 06/24] x86/resctrl: Store the effective num_closid in the schema To: James Morse , x86@kernel.org, linux-kernel@vger.kernel.org Cc: Fenghua Yu , Thomas Gleixner , Ingo Molnar , Borislav Petkov , shameerali.kolothum.thodi@huawei.com, Jamie Iles , D Scott Phillips OS References: <20201030161120.227225-1-james.morse@arm.com> <20201030161120.227225-7-james.morse@arm.com> From: Reinette Chatre Message-ID: <14fa276a-ce44-07f4-203e-d1c8f5967b0b@intel.com> Date: Tue, 17 Nov 2020 14:04:29 -0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.4.3 MIME-Version: 1.0 In-Reply-To: <20201030161120.227225-7-james.morse@arm.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi James, On 10/30/2020 9:11 AM, James Morse wrote: > resctrl_schema holds properties that vary with the style of configuration > that resctrl applies to a resource. > > Once the arch code has a single resource per cache that can be configured, > resctrl will need to keep track of the num_closid itself. > > Add num_closid to resctrl_schema. Change callers like > rdtgroup_schemata_show() to walk the schema instead. This is a significant patch in that it introduces a second num_closid available for code to use. Even so, the commit message is treating it quite nonchalantly ... essentially stating that "here is a new closid and change some code to use it". Could you please elaborate how the callers needing to "walk the schema instead" were chosen? This seems almost a revert of the earlier patch that introduced the helper and I wonder if it may not make this easier to understand if these areas do not receive the temporary change to use that helper. > > Signed-off-by: James Morse > --- > arch/x86/kernel/cpu/resctrl/ctrlmondata.c | 13 ++++++++----- > arch/x86/kernel/cpu/resctrl/rdtgroup.c | 11 +++++------ > include/linux/resctrl.h | 2 ++ > 3 files changed, 15 insertions(+), 11 deletions(-) > ... > diff --git a/include/linux/resctrl.h b/include/linux/resctrl.h > index de6cbc725753..b32152968bca 100644 > --- a/include/linux/resctrl.h > +++ b/include/linux/resctrl.h > @@ -166,10 +166,12 @@ struct rdt_resource { > /** > * @list: Member of resctrl's schema list > * @res: The rdt_resource for this entry > + * @num_closid Number of CLOSIDs available for this resource Missing a ":"? > */ > struct resctrl_schema { > struct list_head list; > struct rdt_resource *res; > + u32 num_closid; > }; > > /* The number of closid supported by this resource regardless of CDP */ > Reinette