Received: by 2002:a05:7412:d1aa:b0:fc:a2b0:25d7 with SMTP id ba42csp725639rdb; Mon, 29 Jan 2024 17:05:19 -0800 (PST) X-Google-Smtp-Source: AGHT+IGBKRna/C6Nk+Vd37WJosXtCovHZhH9zT0NqLgr0kCt8zGDvKcglR5l1XrSclV7618P2omy X-Received: by 2002:a05:6358:796:b0:178:76b3:58d8 with SMTP id n22-20020a056358079600b0017876b358d8mr3052094rwj.38.1706576719497; Mon, 29 Jan 2024 17:05:19 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706576719; cv=pass; d=google.com; s=arc-20160816; b=wJHYw+37lKmiK6+m0fDFxubwBaUw6qMQAluEqMnV+MVKnT67+fftqrFS4ZurKQqIsf QAC2JEUP26tk6I/Zj3kzGjL5J8TzTPRgeT2UnbBpctt7TwkUTKbZTmmI96b/JXLtLrOI izrAoZfyfWRGPfjhT5LzQnxVZ3tmXfhloNxMR/ioLgynWY/Lr3g5LqBW8mLj8aHLIEuz 2jn3Gxyu5+isQkV1UWfQwVvIrrWfHCQHxxJf1EDbHpQXOgt8XLqYeqVljDc14mbSjBiz rk314i51hVY7JoPdA+KecTxdjz7gIWLjukpSl++rJTeTMtpbud/cJsim/bYrG4ZV9ip9 TqGw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=bG7LWMMzQOA4pnHxVE9T5M/eEsZhCIbhOeGSUfM/lKE=; fh=HQBGY9Lm8byKtSShF4OaayowqITs7lNgsPQNlgAG6qE=; b=1FwS6GJzK46j9j/r780TynKfVuvqR3RcgC+T3EqDpiqx9uAybXilqg2a+8V+hTBJy/ Pi1sDnlpHiIA378gqB9agy1fsIGRu77IuRwgstGSJtjibW2eGPyGqtfHz4t7/WDXmKUl k3HOM3R94HXV3BMAtCPSXWTTz2qfriSFUvadtlP2JNYyd5ylE6OlsiaM2pGNqklZxJ1+ /q4fJruav/ekbH+VIF5u2acdCt7hxKi9gjXgH/ktYeeqsqw4ONRIqI9Mw5ShZcuD8lLC Ih5gAg5dc444fpWfzz5G/cbVohiIcDesln2AEbTFl/F/IcTkD0O5AWyTYMoIRfQdju4n pWtA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=VH4+r4ue; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: domain of linux-kernel+bounces-43706-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-43706-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id k66-20020a633d45000000b005cdfb96ea62si6551514pga.243.2024.01.29.17.05.19 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 29 Jan 2024 17:05:19 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-43706-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=VH4+r4ue; arc=pass (i=1 spf=pass spfdomain=intel.com dkim=pass dkdomain=intel.com dmarc=pass fromdomain=intel.com); spf=pass (google.com: domain of linux-kernel+bounces-43706-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-43706-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 27AD9284A97 for ; Tue, 30 Jan 2024 01:05:19 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id AB3102EB1A; Tue, 30 Jan 2024 01:05:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="VH4+r4ue" Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.14]) (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 4B62422083; Tue, 30 Jan 2024 01:05:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=198.175.65.14 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706576711; cv=none; b=lEEmkChvp1jzYvwdewTr6IBm90yJNdtatJ3HMo4b/exwWMLg/gEZSBMTn5GvzlBSvSzs74vE18x8C6J9TN+LqQtzaKEBhpF+r9TSBRslSDb1kY5p4oPmxjZxZFxSc0/vsaQMwdK9L7cBrLuMZiSjQBTTV491yuky7Z4zBctvW5g= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706576711; c=relaxed/simple; bh=bG7LWMMzQOA4pnHxVE9T5M/eEsZhCIbhOeGSUfM/lKE=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=AriK6cdD46Orq3gb67r0OVY/qqCQL30fkliXZa2RHSvzZw357OJAgu3H5TxLge2UJMfpcUtnWrMGBe5CoKI5aYD2C+X7LinDc7uIqs5L5YZ1LqPOBZd0fmc/5dHuDkA1iomFgUDlEAIL6IwEolTLPpWlSg5TiCfFKF5CnVtdNu4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com; spf=pass smtp.mailfrom=intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=VH4+r4ue; arc=none smtp.client-ip=198.175.65.14 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=intel.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=intel.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1706576711; x=1738112711; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=bG7LWMMzQOA4pnHxVE9T5M/eEsZhCIbhOeGSUfM/lKE=; b=VH4+r4ue2ZMNASQsQOoTk+/pQDt2Bd3s05csty7MZCeZAy6dTUA0aRci 2ZWhMBf5shCzBiIvmiSkxnzwxq2xA6REZP/b6DrwMmuMPeep/mRjub3cc x0BUqU0NwW9nJeTG51QnKr8NN8CKoMAvMKPBHklqfGX+znWZWeIfbCjL6 lnnc7bjVfea3Ac6llpgcEnd+oQ6w8YtTZAPFtSHX5GAiDalaTpPxQiiM/ qLNAirP7XOUksGl+vaye8NRThXZfdDzgfxqjDTPL2JOu+3LW1yKM3vsFt UPQSnTt+QazJAnQPKSqdoh2aerUO/716RRAS9MLLzRxdxgYEOKc0dyx9O Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10968"; a="3006761" X-IronPort-AV: E=Sophos;i="6.05,227,1701158400"; d="scan'208";a="3006761" Received: from orviesa002.jf.intel.com ([10.64.159.142]) by orvoesa106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Jan 2024 17:05:10 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.05,227,1701158400"; d="scan'208";a="29719504" Received: from agluck-desk3.sc.intel.com (HELO agluck-desk3) ([172.25.222.74]) by orviesa002-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Jan 2024 17:05:09 -0800 Date: Mon, 29 Jan 2024 17:05:08 -0800 From: Tony Luck To: Borislav Petkov Cc: Fenghua Yu , Reinette Chatre , Peter Newman , Jonathan Corbet , Shuah Khan , Shaopeng Tan , James Morse , Jamie Iles , Babu Moger , Randy Dunlap , x86@kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, patches@lists.linux.dev Subject: Re: [PATCH v14 0/8] Add support for Sub-NUMA cluster (SNC) systems Message-ID: References: <20231204185357.120501-1-tony.luck@intel.com> <20240126223837.21835-1-tony.luck@intel.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240126223837.21835-1-tony.luck@intel.com> I've been wondering whether the SNC patches were creating way too much infrastructure that isn't generally useful. Specifically the capability for a reactrl resource to have different scope for monitoring and control functions. That seems like a very strange thing. History here is that Intel CMT, MBM and L3 CAT features arrived in quick succession, closely followed by MBA and then L2 CAT. At the time it made sense for the "L3" resource to cover all of CMT, MBM and L3 CAT. That became slightly odd when MBA (another L3 scoped resource) was added. It was given its own "struct rdt_resource". AMD later added SMBA as yet another L3-scoped resource with its own "struct resource". I wondered how the SNC series would look if I went back to an approach from one of the earlier versions. In that one I created a new resource for SNC monitoring that was NODE scoped. And then made all the CMT and MBM code switch over to using that one when SNC was enabled. That was a bit hacky, and I moved from there to the dual domain lists per resource. I just tried out an approach the split the RDT_RESOURCE_L3 resource into separate resources, one for control, one for monitoring. It makes the code much simpler: 8 files changed, 235 insertions(+), 30 deletions(-) [1] vs. 9 files changed, 629 insertions(+), 282 deletions(-) Tradeoffs: The complex series (posted as v14) cleanly split the "rdt_domain" structure into two. So it no longer carried all the fields needed for both control and monitor, even though only one set was ever used. But the cost was a lot of code churn that may never be useful for anything other than SNC. On non-SNC systems the new series produces separate linked lists of domains for L3 control & monitor, even though the lists are the same, and the domain structures still carry all fields for both control and monitor functions. Question: Does anyone think that single domain with different scope for control and monitor is inherently more useful than two separate domains? While I get this sorted out, maybe Boris should take James next set of MPAM patches as they are, instead of on top of the complex SNC series. -Tony [1] I'll post this set just as soon as I can get time on and SNC machine to make sure they actually work.