Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp5963301pxb; Tue, 16 Feb 2021 12:01:59 -0800 (PST) X-Google-Smtp-Source: ABdhPJz9L6X8GCwFyRTiuCe8T06RaezXSFcpJpy2l6AEdNUZdwTCKjNHDYfoAg9+0mai2hJi3dD7 X-Received: by 2002:a05:6402:2053:: with SMTP id bc19mr22201087edb.230.1613505718985; Tue, 16 Feb 2021 12:01:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1613505718; cv=none; d=google.com; s=arc-20160816; b=jcw2KdvBWCGh/+xTX2+h/DBL5TLA/t/W4i+DseMhF2KKOPk85+37KcenwMBINJANyd B5WhLn0UXHeFUqZBnRsZReV7HTKexd9pdn+fWyBrpKzXnthifTIs5oG9dvJ+jc/4nOz8 R/tfioAonv85NqLzA92pfhl2heM0AhjkDFmUBBt8UyvVkkldF3uw9mpeNHpymR5lIoQq QaFX0ZKg3p/vfCKKg6fl4WI+fxhmkLpx2YzuORoxcmOQFoJJkpTXhCBvuuHuZ7wepE2O tLpHB8x9F0XF3aKuZcyCqge0eqGadhHGdeikt3a7F3WncwRbvQ7TT6ZapTMTXvJnmPd3 +xqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from:ironport-sdr :ironport-sdr; bh=gDf+5xbJ1MU90cQ71xYXMiWnqMxMAF8hyDlFxOsVLaI=; b=hDESd/QHQ2TZFoeb0UgDWGlXo1BJjmzcoap9CLFevzE9cvRc3sTUlNBIN+uZ6p8NTU w104z0QnxqH1fYJV6OCFosxwNbWxvbVGAuT9A4uJAI/FJZEv7InoT765lwzSFaVWbsxp hTVOWj0NoGXAOyrsGDBOdFio8V6086XW3UMBaI+MNAgipiiyQyZNx9tU8loCSd+17/cf zDDDDFeTs1uStrxfTnxtgE15Lagz6VLnMj+1eb1kLZpP7+IKtX9mr+wnyeN6UHcpUoGM KTT8vSa1qC3qAh3vtU7zVkF25CNhvAukEmG/onhWXUAkIjK3N1Jou0NMAWl1yICq2LJo NjPA== 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 e13si15655069edj.425.2021.02.16.12.01.33; Tue, 16 Feb 2021 12:01:58 -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 S230248AbhBPT5w (ORCPT + 99 others); Tue, 16 Feb 2021 14:57:52 -0500 Received: from mga14.intel.com ([192.55.52.115]:21236 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230194AbhBPT5k (ORCPT ); Tue, 16 Feb 2021 14:57:40 -0500 IronPort-SDR: TSPOaWnP0lL/r8oGlCl4CyeHvNJZMme1K32BEWarGkTXopsjHDhCTCogqwJID6LYWiLO0Ap6Ab eRgHecTo/HuQ== X-IronPort-AV: E=McAfee;i="6000,8403,9897"; a="182222446" X-IronPort-AV: E=Sophos;i="5.81,184,1610438400"; d="scan'208";a="182222446" Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Feb 2021 11:56:59 -0800 IronPort-SDR: 7w1Xe08TozeRRlR2SYslWv0RZhPmpYWNakOvaZIi8JvJN5ePshHCBUyY/uOFpQokcoTzo/bPbo lR4UQurtlUTg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.81,184,1610438400"; d="scan'208";a="439064751" Received: from alison-desk.jf.intel.com (HELO alison-desk) ([10.54.74.53]) by orsmga001.jf.intel.com with ESMTP; 16 Feb 2021 11:56:59 -0800 From: Alison Schofield To: Thomas Gleixner , Ingo Molnar , Borislav Petkov Cc: Alison Schofield , x86@kernel.org, linux-kernel@vger.kernel.org, Dave Hansen , Tony Luck , Tim Chen , "H. Peter Anvin" , Peter Zijlstra , David Rientjes , Igor Mammedov , Prarit Bhargava , brice.goglin@gmail.com Subject: [PATCH v2] x86,sched: Update the Intel SNC CPU list that allows shared LLCs Date: Tue, 16 Feb 2021 11:58:04 -0800 Message-Id: <20210216195804.24204-1-alison.schofield@intel.com> X-Mailer: git-send-email 2.17.1 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit 1340ccfa9a9a ("x86,sched: Allow topologies where NUMA nodes share an LLC") added a vendor and model specific check to never call topology_sane() for systems where NUMA nodes share an LLC. Intel's Ice Lake and Sapphire Rapids CPUs exhibit this same topology. They enumerate an LLC that is shared by multiple NUMA nodes. The LLC on these CPUs is shared for off-package data access but private to the NUMA node for on-package access. Since its CPUID can only enumerate the cache as shared or unshared, add these CPUs to the list of allowable topologies (snc_cpu[]). In SNC mode, Ice Lake and Sapphire Rapids servers will no longer emit this warning: sched: CPU #3's llc-sibling CPU #0 is not on the same node! [node: 1 != 0]. Ignoring dependency. Acked-by: Dave Hansen Signed-off-by: Alison Schofield Cc: Dave Hansen Cc: Tony Luck Cc: Tim Chen Cc: "H. Peter Anvin" Cc: Borislav Petkov Cc: Peter Zijlstra (Intel) Cc: David Rientjes Cc: Igor Mammedov Cc: Prarit Bhargava Cc: brice.goglin@gmail.com --- Changes v1->v2: - Implemented the minimal required change of adding the new models to the existing vendor and model specific check. - Side effect of going minimalist: no longer labelled an X86_BUG (TonyL) - Considered PeterZ suggestion of checking for COD CPUs, rather than SNC CPUs. That meant this snc_cpu list would go away, and so it never needs updating. That ups the stakes for this patch wrt LOC changed and testing needed. It actually drove me back to this simplest soln. - Considered DaveH suggestion to remove the check altogether and recognize these topologies as sane. Not running with that further here. This patch is what is needed now. The broader discussion of sane topologies can carry on independent of this update. - Updated commit message and log. arch/x86/kernel/smpboot.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c index 02813a7f3a7c..de8c598dc3b9 100644 --- a/arch/x86/kernel/smpboot.c +++ b/arch/x86/kernel/smpboot.c @@ -475,6 +475,8 @@ static bool match_smt(struct cpuinfo_x86 *c, struct cpuinfo_x86 *o) static const struct x86_cpu_id snc_cpu[] = { X86_MATCH_INTEL_FAM6_MODEL(SKYLAKE_X, NULL), + X86_MATCH_INTEL_FAM6_MODEL(ICELAKE_X, NULL), + X86_MATCH_INTEL_FAM6_MODEL(SAPPHIRERAPIDS_X, NULL), {} }; -- 2.20.1