From nobody Mon Sep 02 09:12:37 2024 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 4Wy31d6B5gz5MqnM; Mon, 02 Sep 2024 09:12:37 +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 4Wy31d4Gv1z4CMm; Mon, 2 Sep 2024 09:12:37 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1725268357; 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=eWPtULs2XEKp84f9r0QJ3FE9hX/0Y4W4OcNb6/xNcU0=; b=lWUxFLc0JZmC1jCWXTXL3wEOA+dxQrAotdsBfIbgjVWYlLXrObpV8PsCyCcCYjOpo4/fpb 8uaOm+c1XzYy7oonMwoL6Z6F2K+CCLZcXdrJxdWS5EBzJUIlBB46wwfDhqmKT/Ae+FRHhq hWJ+XXt1eoOFxxaCC7um6xNqeOeuVoBhYJb3SHyztSypXbFFh5h5ATGQFIU4mrcaZPdOfd rB392OvLsud2H7PeUI9NxHCZV/1lo/ebUR3KauTC5ZRshJ0q4jwe/aERWiD+c6GRuhYv6p d4QxnTOGxsq1VuFx7HOyafWTeDhH0dHcBWRC0j0Dzk9YTOVGLXFJvNRXjYJ8sw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1725268357; a=rsa-sha256; cv=none; b=g8k/yQbPc9zbjh195HoTZcQDQMIkvg2ADC1/6NW5AcJMropj9Mx3C0NHr3Cb3ZBdwoEaiM Pt8nAifO6OmzK1D8uSzqPo14T0WZwb7Soj9QOUbWCiWCqJiD10sCiysnISplRvQaH1oRyX xsp6IDSTPW4wga6iuWyjxC8+hgTJme9L+a1/sDxlitD2NH7ZaAs6F4RF46MMDghOMXnd4/ 5uvVAFE/1yaZUu1fNzwhblqJnSgoWSkzVUsR+uYzBNMn9O6uGj/0/mp6Dy0Tr+uK/xKy0D eE9UUxyif/+IYJ1SjhKOFel2mwPOqOQJ9rz6GWlEFKtS+N+HilEOefpnwZ5sfg== 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=1725268357; 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=eWPtULs2XEKp84f9r0QJ3FE9hX/0Y4W4OcNb6/xNcU0=; b=bMtrE2giPruFLS9Gf968q/aBtpuvLmItILFE+vwQZfrxMbUUquo2RO0+3QfrSXIPcoB2yN 6nNHsIZHsx/+odVbAMcuyefDnWlmqyCj7RZJDFp0bmO/VUhs/cqKnlZbAWRuRqdmFB2OsR fL1WoHs1CGJwuaS+Yf6k6dV4Gb/OwJsKLpKuU6a6B7eugQLyfN00nxvliKOxlgiysiIEmY UWHbNvnhXbyEE6jNe1lfmTGLdsvkhk8GpVx3hcK1PinkjxWLdIf1oLrs3DySdFX6f4JkxP eu1fEE47cX+JzqRQSPLRTIpNmmyOR4T4TE3MqWUmY7Y9vdYIivW2rKz9ro7oUQ== 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 4Wy31d3vBHz16Dk; Mon, 2 Sep 2024 09:12:37 +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 4829CbOG049544; Mon, 2 Sep 2024 09:12:37 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4829CbH4049541; Mon, 2 Sep 2024 09:12:37 GMT (envelope-from git) Date: Mon, 2 Sep 2024 09:12:37 GMT Message-Id: <202409020912.4829CbH4049541@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Andrew Turner Subject: git: af603143e873 - stable/13 - arm64: Fix the gicv3 check in locore.S 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: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: af603143e8732dc279e3ffda012e1b39cea32b96 Auto-Submitted: auto-generated The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=af603143e8732dc279e3ffda012e1b39cea32b96 commit af603143e8732dc279e3ffda012e1b39cea32b96 Author: Andrew Turner AuthorDate: 2024-07-23 09:18:08 +0000 Commit: Andrew Turner CommitDate: 2024-09-02 09:11:57 +0000 arm64: Fix the gicv3 check in locore.S In locore.S we need to configure access to the GICv3. To check if it's available we read the id_aa64pfr0_el1 register, however we then only check if a GICv3.0 or 4.0 is present. If the system has a GICv4.1 this check would fail. Move to checking if the GICV3+ is not absent so this will still work if the field is updated again. Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45530 (cherry picked from commit 57ef7935eb114e98e7e554c5ffbded68fd038c04) --- sys/arm64/arm64/locore.S | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sys/arm64/arm64/locore.S b/sys/arm64/arm64/locore.S index 007ffdcae513..ada9c5b2e54f 100644 --- a/sys/arm64/arm64/locore.S +++ b/sys/arm64/arm64/locore.S @@ -297,9 +297,8 @@ LENTRY(enter_kernel_el) mrs x2, id_aa64pfr0_el1 /* Extract GIC bits from the register */ ubfx x2, x2, #ID_AA64PFR0_GIC_SHIFT, #ID_AA64PFR0_GIC_BITS - /* GIC[3:0] == 0001 - GIC CPU interface via special regs. supported */ - cmp x2, #(ID_AA64PFR0_GIC_CPUIF_EN >> ID_AA64PFR0_GIC_SHIFT) - b.ne 2f + /* GIC[3:0] != 0000 - GIC CPU interface via special regs. supported */ + cbz x2, 2f mrs x2, icc_sre_el2 orr x2, x2, #ICC_SRE_EL2_EN /* Enable access from insecure EL1 */