From nobody Mon Jan 23 12:37:39 2023 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 4P0qPc030Gz3bT5c; Mon, 23 Jan 2023 12:37:40 +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 4P0qPb6TFTz3CKt; Mon, 23 Jan 2023 12:37:39 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1674477459; 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=3aQyd5JJL8T4KklBuueVVEKTR0yKqAmA8a4EmK4OK4k=; b=nmNpDgF9Zdj79ahuA6QwbPu4Fb4YRGmxjhuevLIfKiNSOzK++kTAdVbgkzWUz1Hn87/4eq DSeWp2hwdvqN0w/Rzi6EUo9hT45VyzGuWe9PE2WRymbbDmVSqcfBlgur/vXUazklEMBZDG +feiBWNv0xKzFzs7TKQUGafA/41iBr6gudEbT5OPMgrTEggVAfGITft/79DxJB+KX8vHIJ XeUw4qcNJsW8kNjCMZ8t4DmOzHDx9f3gy0se7jhbZb2/XzjL7QdAYFz8/4Wb82ze9bfStg 3vzopjOn8a7d4oodfZv9Dy7aIeqgyNGO2B5vJr02qr2sL3BFkBqsvLKg/zwnIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1674477459; 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=3aQyd5JJL8T4KklBuueVVEKTR0yKqAmA8a4EmK4OK4k=; b=jbbhMsmcbV434mPBEJx7FuSAvDap9Kl6zkg/XjyiA1FRDtE0g5mCxLRBJog1+mCbSqmazq I6Ej0bZOWFrxAYa2WjHVLJaTWAyzBmqIRVVOyCinWEhNTNrXzjVePHKzNcQKzaP0TrYOsm vwnYpfLdRl+e12gVAkS/ArtUDsTBzXK9h0vBOGsZLYfScs3aLW+U8jQshlzzWqut5fPG5r ywKYERAnOwhNpEo824Tbfll9xKRYDloKImRgZwnrEFdDQyLQHWjPdsU/12O6glTsLYkcUu s8n8S/jhCBJwIH9470NzFl1tRlS1dig6H7v7X4CkGvg77Y3UA0x0zRkNbmgkmg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1674477459; a=rsa-sha256; cv=none; b=mdF5BFzE7gl8UdTckYa64Yp7WGSLdcS9d1wat+o2x51ZFjkkdeWLWnoRoxqZb0xjZN1O4M c9u5dfZRhR7LBl0xWvvoXgWKvtXwaX8Pd+OsvWyYE4+3Ud9vABQMXpw98+UaxgGlCQwEWC OuRXWyFdsobGLQlUbwP02tgm+OIq/5HlNtNZpkjyMUR7IdaDWxwwQlaWqQfr6QwD+DUmJ9 A5uDgASoEgvxQ55hEwJWpNyx+gHspfsgISoWhowzaaEeEGr9vzrjIfzzEmbz5Rs5OD2mBw QLk1RwjhQfLNDcrurV6nXwSv/lGLfSmhk/MpTY6lRc8qOY0cimRiXtW7tTuIlw== 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 4P0qPb5K5dzTHL; Mon, 23 Jan 2023 12:37:39 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 30NCbdBS085395; Mon, 23 Jan 2023 12:37:39 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 30NCbd83085394; Mon, 23 Jan 2023 12:37:39 GMT (envelope-from git) Date: Mon, 23 Jan 2023 12:37:39 GMT Message-Id: <202301231237.30NCbd83085394@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: 196f6aaa29d7 - stable/13 - Add the arch field to the arm64 MIDR macros 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: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: 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/13 X-Git-Reftype: branch X-Git-Commit: 196f6aaa29d7d9809b4225981e0bbc0d363f9b99 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by andrew: URL: https://cgit.FreeBSD.org/src/commit/?id=196f6aaa29d7d9809b4225981e0bbc0d363f9b99 commit 196f6aaa29d7d9809b4225981e0bbc0d363f9b99 Author: Andrew Turner AuthorDate: 2022-11-14 15:48:43 +0000 Commit: Andrew Turner CommitDate: 2023-01-23 12:36:28 +0000 Add the arch field to the arm64 MIDR macros For completeness add accessors for the MIDR field. As the field is always 0xf on arm64 it is unneeded in the current MICR handling, but will be used in the vmm module for bhyve. Obtained from: https://github.com/FreeBSD-UPB/freebsd-src (earlier version) Sponsored by: The FreeBSD Foundation (cherry picked from commit 80ba994bfacd8a843af4eb9cb7558b62e8de26ee) --- sys/arm64/include/cpu.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/arm64/include/cpu.h b/sys/arm64/include/cpu.h index e913716be7d2..f74944977b47 100644 --- a/sys/arm64/include/cpu.h +++ b/sys/arm64/include/cpu.h @@ -129,16 +129,19 @@ #define CPU_IMPL(midr) (((midr) >> 24) & 0xff) #define CPU_PART(midr) (((midr) >> 4) & 0xfff) #define CPU_VAR(midr) (((midr) >> 20) & 0xf) +#define CPU_ARCH(midr) (((midr) >> 16) & 0xf) #define CPU_REV(midr) (((midr) >> 0) & 0xf) #define CPU_IMPL_TO_MIDR(val) (((val) & 0xff) << 24) #define CPU_PART_TO_MIDR(val) (((val) & 0xfff) << 4) #define CPU_VAR_TO_MIDR(val) (((val) & 0xf) << 20) +#define CPU_ARCH_TO_MIDR(val) (((val) & 0xf) << 16) #define CPU_REV_TO_MIDR(val) (((val) & 0xf) << 0) #define CPU_IMPL_MASK (0xff << 24) #define CPU_PART_MASK (0xfff << 4) #define CPU_VAR_MASK (0xf << 20) +#define CPU_ARCH_MASK (0xf << 16) #define CPU_REV_MASK (0xf << 0) #define CPU_ID_RAW(impl, part, var, rev) \