From patchwork Fri Nov 17 16:39:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Liang, Kan" X-Patchwork-Id: 166263 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9910:0:b0:403:3b70:6f57 with SMTP id i16csp659003vqn; Fri, 17 Nov 2023 08:40:10 -0800 (PST) X-Google-Smtp-Source: AGHT+IE1plaGzO12QhpmDB5o6rP2nto9SmWwpQZQwUjoAECd3TdKxhLS4WpdxRVdfORMyGtOADRf X-Received: by 2002:a05:6a00:1b57:b0:692:b429:390 with SMTP id o23-20020a056a001b5700b00692b4290390mr19711809pfv.29.1700239209735; Fri, 17 Nov 2023 08:40:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700239209; cv=none; d=google.com; s=arc-20160816; b=QNSkrwEQvi5PV+dsnK2mSOthpfW1K2XaBG9EJb9WHOYh+T+kCO99JCJvs589muQX2O fKMNmF4RX8zITk75Y0O5DBvFWUG2s9KSZ04OeFI5NFSCn5XGWCGshdR4B6nmKXd3Hfq9 jGrQEiyPQlhGyYxgFLE7zHKSAq9FxF6567ifDc2MNx9QLX4SNmCUhbS99gp75icGRL14 NnfWCI+HiWLVMoO7xW4Ppx27JCb/+eefxLsB3BTfDqWEx3ZEFA5XNtqjHjNNhPqcdTSj e/n4Ox/7Q1IilEGnmaOshNi2gOgFeNJwUPScoinXnRA6riYtqEYgVCdVbvM20x2kJSS2 wvTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=DonSi3WiPYR0KjzGtKg8i5oPYfZMFddizHiIczJaaJ0=; fh=YWpyLXfdRGAJiuvXavk0et/t8St88Eq5hJrEDig/S6s=; b=BVH4GEkvawtK4bIXwnXTK67kHBSa3BztJMD2cOsJOFlzIcW0qSpAns+uODVDVR0WRQ nCtEUEwp45VbmwMBONFkbsCKZHrra/j/OLj6y/BSB6ABZwD0kKm/m3N9IOnvz7gJOM2Y KGH74IO/cXmp8PDh/zbhsp5mfHQZyhJR8NsJMjrReGtwY0KwanpFQLvz77bLLgXXjagr bEmYgvesMW0baBzDO2ZGsthAlBdmb2sjcnzfxfQjH4XeKu+VTIHbDoGbT5QjnapqtYLv zPFijQ93fT794VMlcvg6Kur2dazjbQ0S6bGgob9Rd76lURV0maeOUIBlNWEE60s50Zhp IY5A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=bGRx4AXO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from snail.vger.email (snail.vger.email. [23.128.96.37]) by mx.google.com with ESMTPS id q17-20020a056a00089100b006b69f056508si2307731pfj.149.2023.11.17.08.40.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 Nov 2023 08:40:09 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) client-ip=23.128.96.37; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=bGRx4AXO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.37 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 858478288C87; Fri, 17 Nov 2023 08:40:08 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346156AbjKQQkD (ORCPT + 30 others); Fri, 17 Nov 2023 11:40:03 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39884 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346122AbjKQQj4 (ORCPT ); Fri, 17 Nov 2023 11:39:56 -0500 Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.120]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5E341D50 for ; Fri, 17 Nov 2023 08:39:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1700239193; x=1731775193; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=JasvbIs1uMFFus2bJjh62TF9c26P45idXBsuIb9qiJY=; b=bGRx4AXO3yurptGcWbqxI6/S60zpPTemPmG62YiWMV4J+HOD7ssZGcJz a4TQGQIffCcuDvNZByhDxh3VwD5KrQFtQmYPmsQNO6wz54AQySYv8pPcs Dd1AKWJu6ZWKgOeiOFQ3XkGBpmOwub51/ZDzRnwLE8+pT4yVhKlMtUN1x 96t9ZTtj7MNYnDPySQKRCmFAj2P+FqBYgNsXlUASunYhZ0Q3wEPvH7Pz3 SQj62S0D439kwVCfYb84mGN3RMl94Nt0vohQBSeX+7xdGW98sRUthWzna GshhfgYIPVgbnpykTmI2FoMocrujWJLaaR9aLOmrOQPWXAN4kafbprm/t A==; X-IronPort-AV: E=McAfee;i="6600,9927,10897"; a="390185897" X-IronPort-AV: E=Sophos;i="6.04,206,1695711600"; d="scan'208";a="390185897" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Nov 2023 08:39:51 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10897"; a="1097146214" X-IronPort-AV: E=Sophos;i="6.04,206,1695711600"; d="scan'208";a="1097146214" Received: from kanliang-dev.jf.intel.com ([10.165.154.102]) by fmsmga005.fm.intel.com with ESMTP; 17 Nov 2023 08:39:50 -0800 From: kan.liang@linux.intel.com To: peterz@infradead.org, mingo@redhat.com, linux-kernel@vger.kernel.org Cc: eranian@google.com, ak@linux.intel.com, Kan Liang , Ammy Yi Subject: [PATCH V2 5/5] perf/x86/intel/uncore: Support Sierra Forest and Grand Ridge Date: Fri, 17 Nov 2023 08:39:39 -0800 Message-Id: <20231117163939.2468007-5-kan.liang@linux.intel.com> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20231117163939.2468007-1-kan.liang@linux.intel.com> References: <20231117163939.2468007-1-kan.liang@linux.intel.com> MIME-Version: 1.0 X-Spam-Status: No, score=-4.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Fri, 17 Nov 2023 08:40:08 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1782830029543443953 X-GMAIL-MSGID: 1782830029543443953 From: Kan Liang The same as Granite Rapids, the Sierra Forest and Grand Ridge also supports the discovery table feature and the same type of the uncore units. The difference of the available units and counters can be retrieved from the discovery table automatically. Just add the CPU model ID. Tested-by: Ammy Yi Signed-off-by: Kan Liang --- Changes since V1: - Add Tested-by tag arch/x86/events/intel/uncore.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/x86/events/intel/uncore.c b/arch/x86/events/intel/uncore.c index 7fb1c54c9879..7927c0b832fa 100644 --- a/arch/x86/events/intel/uncore.c +++ b/arch/x86/events/intel/uncore.c @@ -1877,6 +1877,8 @@ static const struct x86_cpu_id intel_uncore_match[] __initconst = { X86_MATCH_INTEL_FAM6_MODEL(GRANITERAPIDS_D, &gnr_uncore_init), X86_MATCH_INTEL_FAM6_MODEL(ATOM_TREMONT_D, &snr_uncore_init), X86_MATCH_INTEL_FAM6_MODEL(ATOM_GRACEMONT, &adl_uncore_init), + X86_MATCH_INTEL_FAM6_MODEL(ATOM_CRESTMONT_X, &gnr_uncore_init), + X86_MATCH_INTEL_FAM6_MODEL(ATOM_CRESTMONT, &gnr_uncore_init), {}, }; MODULE_DEVICE_TABLE(x86cpu, intel_uncore_match);