From nobody Mon Oct 21 15:05:16 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 4XXJWx380Tz5ZNfc; Mon, 21 Oct 2024 15:05:17 +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 4XXJWx00D4z4ffY; Mon, 21 Oct 2024 15:05:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1729523117; 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=7v4adu34jN91WUjLXhTcUE2CCBhNrsvwldfCmW5DI7A=; b=dxOvx0BAXwFSdwXMYuhSGFZS8tgjyjLRsvRj0JZQYq9fxU/fmiNJPRgk4TJTvR2ckG8sA3 6uKNAwEesTy2pXU4NeljW3o1tKUjTE6F1AemUPEg1nhSRYgViQv3DVRba336N14euVfwM+ L9wvQvMJp1Bx0onsWwnYWJjQcP/yz/BXsaYb8oDqNyXXCT7jdArOKkdtZy1C0EqeJbzjgn 0r87dtNIcL7282EOImNLVrAz+KvNnzNKtRL73YcPQOSoRwkx0alD/XPPV3NvxjOH3dkmif dbHvPS7WoZe9CEyBdvO7qoPyugaIXPNQ6CzNeb/DkFdOS5oWOcPV7SZgC1/SCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1729523117; 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=7v4adu34jN91WUjLXhTcUE2CCBhNrsvwldfCmW5DI7A=; b=OrgrOIlh3etMZCRnq5Hlvw7GfW9f8sRQlT6C1ZLLZ+eY9uRvGoPv/UGk8Y4kvFyGG4j0nt j33SlRzncPU/F8L4o9RKfptTxyXlK9MgYA7YYRgj+TIHLtKT5Vlw7qct53T3glSXhnwbgE 4KnK8W2T/U2Zqw9TJuBgJvhJg3gtcskg7gydhS/qCKOpKQnXrfIOxuDlgaAc4bkaUeD/9/ h0sHNmar/Muqkf4RStINcCnsXV/oQLL26qTFNwVz4VShc2uyv4b8PYSjebUNj9yJZm1Mc1 GTix7NmmRkin3pUhOsa2LCMhgAvfE8VomjsHSgM7JDHG5YHZXGbMR+JMk7j2Jw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1729523117; a=rsa-sha256; cv=none; b=uiMwNWhGD4FHVjSTNTxgDjr4d35zwLrKmu15GncmL1/2nSZpQ7ppnQqK5QhJLmtJJgdbFp JT/izfFzM9fDxI8i37dew6CAMGPSmtMHOy7VzLOJ4s7YdzcmbRa7QSs4ixUwDjir+xraT8 NfPIPq5oaOIw080vZIqvlrQ1Elg0urGZeXvjDd9YMcXKrn8Nqt1gem8j2FLgjwqdQ88nvT vNxHuMPbQz2rYctbzeDzzICvz9affnt9W6y3sxQh3R+ZDO7On1EWTcHzVdMfHqwPcLRhwj GunDhWjxQaHaRKVQNggneloSnL+6Rz8xh7MhdAz8fcfFQtsbLmqj1Q3xyXhZ8Q== 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 4XXJWw5wz6zbQm; Mon, 21 Oct 2024 15:05:16 +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 49LF5GKd047246; Mon, 21 Oct 2024 15:05:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 49LF5Ggf047243; Mon, 21 Oct 2024 15:05:16 GMT (envelope-from git) Date: Mon, 21 Oct 2024 15:05:16 GMT Message-Id: <202410211505.49LF5Ggf047243@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: c0de8718a5c1 - stable/14 - arm64: Support HWCAP2_AFP and HWCAP2_RPRES 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: andrew X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: c0de8718a5c1523c01bf30745a4be80784587fc1 Auto-Submitted: auto-generated The branch stable/14 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=c0de8718a5c1523c01bf30745a4be80784587fc1 commit c0de8718a5c1523c01bf30745a4be80784587fc1 Author: Andrew Turner AuthorDate: 2024-10-04 13:08:36 +0000 Commit: Andrew Turner CommitDate: 2024-10-21 15:03:27 +0000 arm64: Support HWCAP2_AFP and HWCAP2_RPRES These add alternative behaviour to some floating-point instructions so don't need any kernel support and can just be exposed to userspace. Sponsored by: Arm Ltd (cherry picked from commit 48979e8def00b69a07880e7827af7e32d5e377ff) --- sys/arm64/arm64/identcpu.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/sys/arm64/arm64/identcpu.c b/sys/arm64/arm64/identcpu.c index 22978af219dc..d0b4f74c8a15 100644 --- a/sys/arm64/arm64/identcpu.c +++ b/sys/arm64/arm64/identcpu.c @@ -943,6 +943,11 @@ static const struct mrs_field_value id_aa64isar2_rpres[] = { MRS_FIELD_VALUE_END, }; +static const struct mrs_field_hwcap id_aa64isar2_rpres_caps[] = { + MRS_HWCAP(2, HWCAP2_RPRES, ID_AA64ISAR2_RPRES_IMPL), + MRS_HWCAP_END +}; + static const struct mrs_field_value id_aa64isar2_wfxt[] = { MRS_FIELD_VALUE_NONE_IMPL(ID_AA64ISAR2, WFxT, NONE, IMPL), MRS_FIELD_VALUE_END, @@ -957,7 +962,8 @@ static const struct mrs_field id_aa64isar2_fields[] = { id_aa64isar2_apa3, id_aa64isar2_apa3_caps), MRS_FIELD_HWCAP(ID_AA64ISAR2, GPA3, false, MRS_EXACT, id_aa64isar2_gpa3, id_aa64isar2_gpa3_caps), - MRS_FIELD(ID_AA64ISAR2, RPRES, false, MRS_EXACT, id_aa64isar2_rpres), + MRS_FIELD_HWCAP(ID_AA64ISAR2, RPRES, false, MRS_LOWER, + id_aa64isar2_rpres, id_aa64isar2_rpres_caps), MRS_FIELD(ID_AA64ISAR2, WFxT, false, MRS_EXACT, id_aa64isar2_wfxt), MRS_FIELD_END, }; @@ -1100,6 +1106,11 @@ static const struct mrs_field_value id_aa64mmfr1_afp[] = { MRS_FIELD_VALUE_END, }; +static const struct mrs_field_hwcap id_aa64mmfr1_afp_caps[] = { + MRS_HWCAP(2, HWCAP2_AFP, ID_AA64MMFR1_AFP_IMPL), + MRS_HWCAP_END +}; + static const struct mrs_field_value id_aa64mmfr1_hcx[] = { MRS_FIELD_VALUE_NONE_IMPL(ID_AA64MMFR1, HCX, NONE, IMPL), MRS_FIELD_VALUE_END, @@ -1166,7 +1177,8 @@ static const struct mrs_field id_aa64mmfr1_fields[] = { MRS_FIELD(ID_AA64MMFR1, CMOVW, false, MRS_EXACT, id_aa64mmfr1_cmovw), MRS_FIELD(ID_AA64MMFR1, TIDCP1, false, MRS_EXACT, id_aa64mmfr1_tidcp1), MRS_FIELD(ID_AA64MMFR1, nTLBPA, false, MRS_EXACT, id_aa64mmfr1_ntlbpa), - MRS_FIELD(ID_AA64MMFR1, AFP, false, MRS_EXACT, id_aa64mmfr1_afp), + MRS_FIELD_HWCAP(ID_AA64MMFR1, AFP, false, MRS_LOWER, id_aa64mmfr1_afp, + id_aa64mmfr1_afp_caps), MRS_FIELD(ID_AA64MMFR1, HCX, false, MRS_EXACT, id_aa64mmfr1_hcx), MRS_FIELD(ID_AA64MMFR1, ETS, false, MRS_EXACT, id_aa64mmfr1_ets), MRS_FIELD(ID_AA64MMFR1, TWED, false, MRS_EXACT, id_aa64mmfr1_twed),