[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 1/9] Add CPU_TYPE_ARM64
From: |
Sergey Bugaev |
Subject: |
[PATCH 1/9] Add CPU_TYPE_ARM64 |
Date: |
Mon, 15 Apr 2024 12:01:41 +0300 |
This is distinct from CPU_TYPE_ARM, since we're going to exclusively use
AArch64 / A64, which CPU_TYPE_ARM was never meant to support, and to
match EM_AARCH64, which is also separate from EM_ARM. CPU_TYPE_X86_64
was similarly made distinct from CPU_TYPE_I386.
This is named CPU_TYPE_ARM64 rather than CPU_TYPE_AARCH64, since AArch64
is an "execution state" (analogous to long mode on x86_64) rather than a
CPU type. "ARM64" here is not a name of the architecture, but simply
means an ARM CPU that is capable of (and for our case, will only really
be) running in the 64-bit mode (AArch64).
There are no subtypes defined, and none are expected to be defined in
the future. Support for individual features/extensions should be
discovered by other means, i.e. the aarch64_get_hwcaps() RPC.
---
include/mach/machine.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/mach/machine.h b/include/mach/machine.h
index 9a176e8c..072bf539 100644
--- a/include/mach/machine.h
+++ b/include/mach/machine.h
@@ -110,6 +110,7 @@ extern struct machine_slot machine_slot[NCPUS];
#define CPU_TYPE_PENTIUMPRO ((cpu_type_t) 19)
#define CPU_TYPE_POWERPC ((cpu_type_t) 20)
#define CPU_TYPE_X86_64 ((cpu_type_t) 21)
+#define CPU_TYPE_ARM64 ((cpu_type_t) 22) /* AArch64-capable ARM
*/
/*
* Machine subtypes (these are defined here, instead of in a machine
--
2.44.0
- [PATCH 0/9] AArch64 Mach public headers, Sergey Bugaev, 2024/04/15
- [PATCH 1/9] Add CPU_TYPE_ARM64,
Sergey Bugaev <=
- [PATCH 4/9] aarch64: Add vm_param.h, Sergey Bugaev, 2024/04/15
- [PATCH 3/9] aarch64: Add public syscall ABI, Sergey Bugaev, 2024/04/15
- [PATCH 5/9] aarch64: Add mach_aarch64 API, Sergey Bugaev, 2024/04/15
- [PATCH 6/9] aarch64: Add exception type definitions, Sergey Bugaev, 2024/04/15
- [PATCH 2/9] aarch64: Add the basics, Sergey Bugaev, 2024/04/15
- [PATCH 7/9] aarch64: Add thread state types, Sergey Bugaev, 2024/04/15
- [PATCH 9/9] Add a test for thread state, Sergey Bugaev, 2024/04/15