From nobody Tue Oct 24 04:47:15 2023 X-Original-To: dev-commits-src-branches@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 4SF00N17PMz4xVQC; Tue, 24 Oct 2023 04:47:16 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4SF00M702dz3KkY; Tue, 24 Oct 2023 04:47:15 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1698122836; 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=zsj6dMwkeDvZabngIVKVzY2mQ2N5I5d6MDhFV+D6K2k=; b=myNegedhaBaHCK2yxz7XwUR6MdVT0CHtgySghe1VpyAgU3jMUDDI84RA+LmTkoI0IWTbwB m3afi0iFnQ/k3mZlE1JU57UuLMgnZ6wmpXAnEg5uwY8fBJAd+O9FEP9ytUcjCXJHWF/ycZ 2rBH1z+x1c3zHn7URhE72stiu6VelHOJsUKAuos87kFNxEmv7yq8uSpOw/WfoFN3bXuYmR 39TWWktvexn6UCbGoT2pwdS+gk1/BvPBg8m80JRTXJ46wFZBNJBU1EWqotBNjW/wWgXio8 huOtIaZhCh4jdeGYsTO+PNQkJRAmnxdoVxTyxgNTmAEkkzbI32fxKDRyYHgj8g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1698122836; a=rsa-sha256; cv=none; b=g4MbPRTI0A9ucMmI5PgqbfFEO7hoBsBkdge2k3mltwMhLO8pDQIJ+rR/sreLPSamMuGA+O Cipt4fmSlj5dYaQaYYL9koVXiNNoT7MevF23miv+5Pqr429a7ROBmnjaZoFXgDyxNcdg9e HSR+IcyxVk01qpb+YV0w9cJNlvdsae4MDHVnB5dsunabGoj9tJYvm4s+Brx0BhrJWL2+Wg UG0F+tEVJmaRV8rs4FgzXIoufuubsCVG/mqmwn80/qPmN3VPaH3hcktxOcV+o7MTQVAjIe 014747/4PChrwZiijCOBZP7YnDt4LeAQJg//NJxhU/m52jmHh+ARW3f8WA0BQg== 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=1698122836; 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=zsj6dMwkeDvZabngIVKVzY2mQ2N5I5d6MDhFV+D6K2k=; b=XUc4aNJHn6yfrkpvDwOGdOgcHDfTjUDNoplhg7BL5ehuTVIWApz34kWjARFpJlCxRpfAT5 Jvp0anUQf8mJTnHGCLgS1NyoRgZsOPsLNSS86WaDM9fdNAP5V4pI+9VdZQBWsLimo8M8El UvepI88qCfJkmMC9XOnsrgAQwAxmLw6kVWZoophAjnGrDSslUjs0tO+kyfGRuDyGcI192g 9UGjWxm3ZQYAdREnNw5pAzVpqJd5PxX9cE2io4/fefRJBLBVvNHkHr8tokFaDXGJYBDRUG lFsHiMiQhtDYGt/Nqk7kIkZJipCqcxnDxIUP2gL3MbavJVpUKq7C11PQ53ofSg== 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 4SF00M62Sfz17vX; Tue, 24 Oct 2023 04:47:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 39O4lFCv005615; Tue, 24 Oct 2023 04:47:15 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 39O4lFjk005612; Tue, 24 Oct 2023 04:47:15 GMT (envelope-from git) Date: Tue, 24 Oct 2023 04:47:15 GMT Message-Id: <202310240447.39O4lFjk005612@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 180695b8e643 - stable/12 - amd64 pmap: Prefer consistent naming for loader tunable List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-branches@freebsd.org X-BeenThere: dev-commits-src-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: zlei X-Git-Repository: src X-Git-Refname: refs/heads/stable/12 X-Git-Reftype: branch X-Git-Commit: 180695b8e6434891c418cfdde9a32eee8c8fb6f0 Auto-Submitted: auto-generated The branch stable/12 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=180695b8e6434891c418cfdde9a32eee8c8fb6f0 commit 180695b8e6434891c418cfdde9a32eee8c8fb6f0 Author: Zhenlei Huang AuthorDate: 2023-10-20 07:31:44 +0000 Commit: Zhenlei Huang CommitDate: 2023-10-24 04:46:30 +0000 amd64 pmap: Prefer consistent naming for loader tunable The sysctl knob 'vm.pmap.allow_2m_x_ept' is loader tunable and have public document entry in security(7) but is fetched from kernel environment 'hw.allow_2m_x_ept'. That is inconsistent and obscure. As there is public security advisory FreeBSD-SA-19:25.mcepsc [1], people may refer to it and use 'hw.allow_2m_x_ept', let's keep old name for compatibility. [1] https://www.freebsd.org/security/advisories/FreeBSD-SA-19:25.mcepsc.asc Reviewed by: kib Fixes: c08973d09c95 Workaround for Intel SKL002/SKL012S errata MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D42311 (cherry picked from commit 9e7f349ff10691c2e3fb03898dbc942794a47566) (cherry picked from commit 8784b153a31fc0b3a12449a2f0377eb038e6fb7b) (cherry picked from commit 350e79edf9a8f65c9a9d17aa86ec90b436d638f8) --- sys/amd64/amd64/pmap.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/amd64/amd64/pmap.c b/sys/amd64/amd64/pmap.c index b2fe589ed029..cf4a96ceabe6 100644 --- a/sys/amd64/amd64/pmap.c +++ b/sys/amd64/amd64/pmap.c @@ -1847,7 +1847,10 @@ pmap_allow_2m_x_ept_recalculate(void) CPUID_TO_MODEL(cpu_id) == 0x57 || /* Knights */ CPUID_TO_MODEL(cpu_id) == 0x85)))) pmap_allow_2m_x_ept = 1; +#ifndef BURN_BRIDGES TUNABLE_INT_FETCH("hw.allow_2m_x_ept", &pmap_allow_2m_x_ept); +#endif + TUNABLE_INT_FETCH("vm.pmap.allow_2m_x_ept", &pmap_allow_2m_x_ept); } static bool