From nobody Mon Aug 26 15:21:53 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WsvXx303mz5T5y1; Mon, 26 Aug 2024 15:21:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WsvXx2QFZz4nyX; Mon, 26 Aug 2024 15:21:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1724685713; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=W/WwTFTi7wqhtE63a4F5LwGuuy7D30doaqwtPSs7y6c=; b=oL+4dRorwK9gl5fnpL+AkL0gVUV42KF9FTDk96J3Bw3gddVDP2l1jYqjyrpOi/jdqPp+2o vTke4UdgNrrKT5JV6wmpDwVULFxAVgWH8i+XvPbzogdKiEgJYkAk9H9JjX878AUYx2eps2 JttkU60gRMH4Wa6YhRMEnobNT7yAJXMU5g5M5KRlrduZ9+QwqKsXk0OPiGPa65OjwuRfG/ 8q8nX4L7eZqZR5NJsGtk955L+KBoouQAkGgn1I3f3sJptm2+1leYTr6UtE84iavAUnIoTX Djh8ADqDiA2EJ+MWQ4Tvvm91svbPLdH5UA4lZOwq7fesiuahwUDS6W7GDIDjjA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1724685713; a=rsa-sha256; cv=none; b=ntv2y+6LEBV8ubVfublUEBjnC8eZA2976WwO23X37O9SwdFej+Q98Dn+BD9EAi9bY/OgjP JCJjRFjXayfdlxAop5RV55O9+uzB4M03lhy+z0vhIaRJaxu9diaTr0iGDsKC7s8B2AkCol Mtet3s+quXPHlTL7EZYfFE5b+8HK1fpwCAj4HlWllWBDPAwwu6hx5/WbPcqnBJXXxQP8FR DwNhuDyHeYHvTFUmaV5qCJI75GtWjsTHBpjWLqhcN/gA1i+dBt/r4hJUpLMPCTD2sZDs5e D18a2GM4uW+vOR2QhSdCuUfLLrgD9/g3JEWi2zSd0ZfgebYLTd8VBWUHNqkugg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1724685713; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=W/WwTFTi7wqhtE63a4F5LwGuuy7D30doaqwtPSs7y6c=; b=yO5cbczfQubILDZJBrAK6yjCRbtH272iY+qgzMXJSt7ojK+6Xw8B63/AyWvYYk6yrQq7ni fl3IGaYFinz3YlFum7+5bSCdwxDZ/Tp9Pnt3bh25tpcj/U4JIpV7OO0vTrZnQlzjqYlPQ8 reKy7zlWirj3LlMTYLC9O2cTezHblZ/mBXLytfYeZ521lpftN8eYGSc8RCXbW6GDLACobL pdUGWk8/RWYYtzhQehZvNAslXrw1BbD+oxOz/06RFv7nzC4P8k+bQZbJHrF9AKZvMwUYTa +h1G6AJrbO5uWEvU99mjR88pjnLHnQ2ncG7Bfm6m4SERHZku6KDviR645Hsuwg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4WsvXx21gGz1BnR; Mon, 26 Aug 2024 15:21:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 47QFLrBh068201; Mon, 26 Aug 2024 15:21:53 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 47QFLrK6068198; Mon, 26 Aug 2024 15:21:53 GMT (envelope-from git) Date: Mon, 26 Aug 2024 15:21:53 GMT Message-Id: <202408261521.47QFLrK6068198@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Xin LI Subject: git: e3819923655c - releng/13.4 - amdsmn(4), amdtemp(4): add support for AMD Ryzen 7 "Phoenix" processors List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: delphij X-Git-Repository: src X-Git-Refname: refs/heads/releng/13.4 X-Git-Reftype: branch X-Git-Commit: e3819923655c544b5494293d48d19067c67eb832 Auto-Submitted: auto-generated The branch releng/13.4 has been updated by delphij: URL: https://cgit.FreeBSD.org/src/commit/?id=e3819923655c544b5494293d48d19067c67eb832 commit e3819923655c544b5494293d48d19067c67eb832 Author: Oliver Fromme AuthorDate: 2024-08-23 04:46:19 +0000 Commit: Xin LI CommitDate: 2024-08-26 15:21:13 +0000 amdsmn(4), amdtemp(4): add support for AMD Ryzen 7 "Phoenix" processors Adds support for AMD Ryzen 7 "Phoenix" processors (family 0x19, model 0x70-0x7f) to the amdsmn(4) and amdtemp(4) drivers. This enables temperature readings of these CPUs via sysctl. The sensors function identically to those for the "Raphael" processors (model 0x60-0x6f); only the PCI device ID differs. PR: kern/280942 Relnotes: yes Approved by: re (cperciva) (cherry picked from commit ef3f8aa0a0492487ac7db839de078b1913f61b4c) (cherry picked from commit cb8f15aeede63627e220c40fe4911df79f35fb69) --- sys/dev/amdsmn/amdsmn.c | 7 +++++++ sys/dev/amdtemp/amdtemp.c | 3 +++ 2 files changed, 10 insertions(+) diff --git a/sys/dev/amdsmn/amdsmn.c b/sys/dev/amdsmn/amdsmn.c index decb2c1249ed..fbef358f4957 100644 --- a/sys/dev/amdsmn/amdsmn.c +++ b/sys/dev/amdsmn/amdsmn.c @@ -61,6 +61,7 @@ #define PCI_DEVICE_ID_AMD_17H_M60H_ROOT 0x1630 #define PCI_DEVICE_ID_AMD_19H_M10H_ROOT 0x14a4 #define PCI_DEVICE_ID_AMD_19H_M60H_ROOT 0x14d8 +#define PCI_DEVICE_ID_AMD_19H_M70H_ROOT 0x14e8 struct pciid; struct amdsmn_softc { @@ -116,6 +117,12 @@ static const struct pciid { .amdsmn_addr_reg = F17H_SMN_ADDR_REG, .amdsmn_data_reg = F17H_SMN_DATA_REG, }, + { + .amdsmn_vendorid = CPU_VENDOR_AMD, + .amdsmn_deviceid = PCI_DEVICE_ID_AMD_19H_M70H_ROOT, + .amdsmn_addr_reg = F17H_SMN_ADDR_REG, + .amdsmn_data_reg = F17H_SMN_DATA_REG, + }, }; /* diff --git a/sys/dev/amdtemp/amdtemp.c b/sys/dev/amdtemp/amdtemp.c index b38f92131c77..0e7f805b40fd 100644 --- a/sys/dev/amdtemp/amdtemp.c +++ b/sys/dev/amdtemp/amdtemp.c @@ -116,6 +116,7 @@ struct amdtemp_softc { #define DEVICEID_AMD_HOSTB17H_M60H_ROOT 0x1630 #define DEVICEID_AMD_HOSTB19H_M10H_ROOT 0x14a4 #define DEVICEID_AMD_HOSTB19H_M60H_ROOT 0x14d8 +#define DEVICEID_AMD_HOSTB19H_M70H_ROOT 0x14e8 static const struct amdtemp_product { uint16_t amdtemp_vendorid; @@ -142,6 +143,7 @@ static const struct amdtemp_product { { VENDORID_AMD, DEVICEID_AMD_HOSTB17H_M60H_ROOT, false }, { VENDORID_AMD, DEVICEID_AMD_HOSTB19H_M10H_ROOT, false }, { VENDORID_AMD, DEVICEID_AMD_HOSTB19H_M60H_ROOT, false }, + { VENDORID_AMD, DEVICEID_AMD_HOSTB19H_M70H_ROOT, false }, }; /* @@ -875,6 +877,7 @@ amdtemp_probe_ccd_sensors19h(device_t dev, uint32_t model) _Static_assert((int)NUM_CCDS >= 12, ""); break; case 0x60 ... 0x6f: /* Zen4 Ryzen "Raphael" */ + case 0x70 ... 0x7f: /* Zen4 Ryzen "Phoenix" */ sc->sc_temp_base = AMDTEMP_ZEN4_CCD_TMP_BASE; maxreg = 8; _Static_assert((int)NUM_CCDS >= 8, "");