1f126890aSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0 OR MIT) 2f126890aSEmmanuel Vadot%YAML 1.2 3f126890aSEmmanuel Vadot--- 4f126890aSEmmanuel Vadot$id: http://devicetree.org/schemas/riscv/extensions.yaml# 5f126890aSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 6f126890aSEmmanuel Vadot 7f126890aSEmmanuel Vadottitle: RISC-V ISA extensions 8f126890aSEmmanuel Vadot 9f126890aSEmmanuel Vadotmaintainers: 10f126890aSEmmanuel Vadot - Paul Walmsley <paul.walmsley@sifive.com> 11f126890aSEmmanuel Vadot - Palmer Dabbelt <palmer@sifive.com> 12f126890aSEmmanuel Vadot - Conor Dooley <conor@kernel.org> 13f126890aSEmmanuel Vadot 14f126890aSEmmanuel Vadotdescription: | 15f126890aSEmmanuel Vadot RISC-V has a large number of extensions, some of which are "standard" 16f126890aSEmmanuel Vadot extensions, meaning they are ratified by RISC-V International, and others 17f126890aSEmmanuel Vadot are "vendor" extensions. 18f126890aSEmmanuel Vadot This document defines properties that indicate whether a hart supports a 19f126890aSEmmanuel Vadot given extension. 20f126890aSEmmanuel Vadot 21f126890aSEmmanuel Vadot Once a standard extension has been ratified, no changes in behaviour can be 22f126890aSEmmanuel Vadot made without the creation of a new extension. 23f126890aSEmmanuel Vadot The properties for standard extensions therefore map to their originally 24f126890aSEmmanuel Vadot ratified states, with the exception of the I, Zicntr & Zihpm extensions. 25f126890aSEmmanuel Vadot See the "i" property for more information. 26f126890aSEmmanuel Vadot 27f126890aSEmmanuel Vadotselect: 28f126890aSEmmanuel Vadot properties: 29f126890aSEmmanuel Vadot compatible: 30f126890aSEmmanuel Vadot contains: 31f126890aSEmmanuel Vadot const: riscv 32f126890aSEmmanuel Vadot 33f126890aSEmmanuel Vadotproperties: 34f126890aSEmmanuel Vadot riscv,isa: 35f126890aSEmmanuel Vadot description: 36f126890aSEmmanuel Vadot Identifies the specific RISC-V instruction set architecture 37f126890aSEmmanuel Vadot supported by the hart. These are documented in the RISC-V 38f126890aSEmmanuel Vadot User-Level ISA document, available from 39f126890aSEmmanuel Vadot https://riscv.org/specifications/ 40f126890aSEmmanuel Vadot 41f126890aSEmmanuel Vadot Due to revisions of the ISA specification, some deviations 42f126890aSEmmanuel Vadot have arisen over time. 43f126890aSEmmanuel Vadot Notably, riscv,isa was defined prior to the creation of the 44f126890aSEmmanuel Vadot Zicntr, Zicsr, Zifencei and Zihpm extensions and thus "i" 45f126890aSEmmanuel Vadot implies "zicntr_zicsr_zifencei_zihpm". 46f126890aSEmmanuel Vadot 47f126890aSEmmanuel Vadot While the isa strings in ISA specification are case 48f126890aSEmmanuel Vadot insensitive, letters in the riscv,isa string must be all 49f126890aSEmmanuel Vadot lowercase. 50f126890aSEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/string 51f126890aSEmmanuel Vadot pattern: ^rv(?:64|32)imaf?d?q?c?b?k?j?p?v?h?(?:[hsxz](?:[a-z])+)?(?:_[hsxz](?:[a-z])+)*$ 52f126890aSEmmanuel Vadot deprecated: true 53f126890aSEmmanuel Vadot 54f126890aSEmmanuel Vadot riscv,isa-base: 55f126890aSEmmanuel Vadot description: 56f126890aSEmmanuel Vadot The base ISA implemented by this hart, as described by the 20191213 57f126890aSEmmanuel Vadot version of the unprivileged ISA specification. 58f126890aSEmmanuel Vadot enum: 59f126890aSEmmanuel Vadot - rv32i 60f126890aSEmmanuel Vadot - rv64i 61f126890aSEmmanuel Vadot 62f126890aSEmmanuel Vadot riscv,isa-extensions: 63f126890aSEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/string-array 64f126890aSEmmanuel Vadot minItems: 1 65f126890aSEmmanuel Vadot description: Extensions supported by the hart. 66f126890aSEmmanuel Vadot items: 67f126890aSEmmanuel Vadot anyOf: 68f126890aSEmmanuel Vadot # single letter extensions, in canonical order 69f126890aSEmmanuel Vadot - const: i 70f126890aSEmmanuel Vadot description: | 71f126890aSEmmanuel Vadot The base integer instruction set, as ratified in the 20191213 72f126890aSEmmanuel Vadot version of the unprivileged ISA specification. 73f126890aSEmmanuel Vadot 74f126890aSEmmanuel Vadot This does not include Chapter 10, "Counters", which was moved into 75f126890aSEmmanuel Vadot the Zicntr and Zihpm extensions after the ratification of the 76f126890aSEmmanuel Vadot 20191213 version of the unprivileged specification. 77f126890aSEmmanuel Vadot 78f126890aSEmmanuel Vadot - const: m 79f126890aSEmmanuel Vadot description: 80f126890aSEmmanuel Vadot The standard M extension for integer multiplication and division, as 81f126890aSEmmanuel Vadot ratified in the 20191213 version of the unprivileged ISA 82f126890aSEmmanuel Vadot specification. 83f126890aSEmmanuel Vadot 84f126890aSEmmanuel Vadot - const: a 85f126890aSEmmanuel Vadot description: 86f126890aSEmmanuel Vadot The standard A extension for atomic instructions, as ratified in the 87f126890aSEmmanuel Vadot 20191213 version of the unprivileged ISA specification. 88f126890aSEmmanuel Vadot 89f126890aSEmmanuel Vadot - const: f 90f126890aSEmmanuel Vadot description: 91f126890aSEmmanuel Vadot The standard F extension for single-precision floating point, as 92f126890aSEmmanuel Vadot ratified in the 20191213 version of the unprivileged ISA 93f126890aSEmmanuel Vadot specification. 94f126890aSEmmanuel Vadot 95f126890aSEmmanuel Vadot - const: d 96f126890aSEmmanuel Vadot description: 97f126890aSEmmanuel Vadot The standard D extension for double-precision floating-point, as 98f126890aSEmmanuel Vadot ratified in the 20191213 version of the unprivileged ISA 99f126890aSEmmanuel Vadot specification. 100f126890aSEmmanuel Vadot 101f126890aSEmmanuel Vadot - const: q 102f126890aSEmmanuel Vadot description: 103f126890aSEmmanuel Vadot The standard Q extension for quad-precision floating-point, as 104f126890aSEmmanuel Vadot ratified in the 20191213 version of the unprivileged ISA 105f126890aSEmmanuel Vadot specification. 106f126890aSEmmanuel Vadot 107f126890aSEmmanuel Vadot - const: c 108f126890aSEmmanuel Vadot description: 109f126890aSEmmanuel Vadot The standard C extension for compressed instructions, as ratified in 110f126890aSEmmanuel Vadot the 20191213 version of the unprivileged ISA specification. 111f126890aSEmmanuel Vadot 112f126890aSEmmanuel Vadot - const: v 113f126890aSEmmanuel Vadot description: 114f126890aSEmmanuel Vadot The standard V extension for vector operations, as ratified 115f126890aSEmmanuel Vadot in-and-around commit 7a6c8ae ("Fix text that describes vfmv.v.f 116f126890aSEmmanuel Vadot encoding") of the riscv-v-spec. 117f126890aSEmmanuel Vadot 118f126890aSEmmanuel Vadot - const: h 119f126890aSEmmanuel Vadot description: 120f126890aSEmmanuel Vadot The standard H extension for hypervisors as ratified in the 20191213 121f126890aSEmmanuel Vadot version of the privileged ISA specification. 122f126890aSEmmanuel Vadot 123f126890aSEmmanuel Vadot # multi-letter extensions, sorted alphanumerically 124f126890aSEmmanuel Vadot - const: smaia 125f126890aSEmmanuel Vadot description: | 126f126890aSEmmanuel Vadot The standard Smaia supervisor-level extension for the advanced 127f126890aSEmmanuel Vadot interrupt architecture for machine-mode-visible csr and behavioural 128f126890aSEmmanuel Vadot changes to interrupts as frozen at commit ccbddab ("Merge pull 129f126890aSEmmanuel Vadot request #42 from riscv/jhauser-2023-RC4") of riscv-aia. 130f126890aSEmmanuel Vadot 131*84943d6fSEmmanuel Vadot - const: smstateen 132*84943d6fSEmmanuel Vadot description: | 133*84943d6fSEmmanuel Vadot The standard Smstateen extension for controlling access to CSRs 134*84943d6fSEmmanuel Vadot added by other RISC-V extensions in H/S/VS/U/VU modes and as 135*84943d6fSEmmanuel Vadot ratified at commit a28bfae (Ratified (#7)) of riscv-state-enable. 136*84943d6fSEmmanuel Vadot 137f126890aSEmmanuel Vadot - const: ssaia 138f126890aSEmmanuel Vadot description: | 139f126890aSEmmanuel Vadot The standard Ssaia supervisor-level extension for the advanced 140f126890aSEmmanuel Vadot interrupt architecture for supervisor-mode-visible csr and 141f126890aSEmmanuel Vadot behavioural changes to interrupts as frozen at commit ccbddab 142f126890aSEmmanuel Vadot ("Merge pull request #42 from riscv/jhauser-2023-RC4") of riscv-aia. 143f126890aSEmmanuel Vadot 144f126890aSEmmanuel Vadot - const: sscofpmf 145f126890aSEmmanuel Vadot description: | 146f126890aSEmmanuel Vadot The standard Sscofpmf supervisor-level extension for count overflow 147f126890aSEmmanuel Vadot and mode-based filtering as ratified at commit 01d1df0 ("Add ability 148f126890aSEmmanuel Vadot to manually trigger workflow. (#2)") of riscv-count-overflow. 149f126890aSEmmanuel Vadot 150f126890aSEmmanuel Vadot - const: sstc 151f126890aSEmmanuel Vadot description: | 152f126890aSEmmanuel Vadot The standard Sstc supervisor-level extension for time compare as 153f126890aSEmmanuel Vadot ratified at commit 3f9ed34 ("Add ability to manually trigger 154f126890aSEmmanuel Vadot workflow. (#2)") of riscv-time-compare. 155f126890aSEmmanuel Vadot 156f126890aSEmmanuel Vadot - const: svinval 157f126890aSEmmanuel Vadot description: 158f126890aSEmmanuel Vadot The standard Svinval supervisor-level extension for fine-grained 159f126890aSEmmanuel Vadot address-translation cache invalidation as ratified in the 20191213 160f126890aSEmmanuel Vadot version of the privileged ISA specification. 161f126890aSEmmanuel Vadot 162f126890aSEmmanuel Vadot - const: svnapot 163f126890aSEmmanuel Vadot description: 164f126890aSEmmanuel Vadot The standard Svnapot supervisor-level extensions for napot 165f126890aSEmmanuel Vadot translation contiguity as ratified in the 20191213 version of the 166f126890aSEmmanuel Vadot privileged ISA specification. 167f126890aSEmmanuel Vadot 168f126890aSEmmanuel Vadot - const: svpbmt 169f126890aSEmmanuel Vadot description: 170f126890aSEmmanuel Vadot The standard Svpbmt supervisor-level extensions for page-based 171f126890aSEmmanuel Vadot memory types as ratified in the 20191213 version of the privileged 172f126890aSEmmanuel Vadot ISA specification. 173f126890aSEmmanuel Vadot 174f126890aSEmmanuel Vadot - const: zba 175f126890aSEmmanuel Vadot description: | 176f126890aSEmmanuel Vadot The standard Zba bit-manipulation extension for address generation 177f126890aSEmmanuel Vadot acceleration instructions as ratified at commit 6d33919 ("Merge pull 178f126890aSEmmanuel Vadot request #158 from hirooih/clmul-fix-loop-end-condition") of 179f126890aSEmmanuel Vadot riscv-bitmanip. 180f126890aSEmmanuel Vadot 181f126890aSEmmanuel Vadot - const: zbb 182f126890aSEmmanuel Vadot description: | 183f126890aSEmmanuel Vadot The standard Zbb bit-manipulation extension for basic bit-manipulation 184f126890aSEmmanuel Vadot as ratified at commit 6d33919 ("Merge pull request #158 from 185f126890aSEmmanuel Vadot hirooih/clmul-fix-loop-end-condition") of riscv-bitmanip. 186f126890aSEmmanuel Vadot 187f126890aSEmmanuel Vadot - const: zbc 188f126890aSEmmanuel Vadot description: | 189f126890aSEmmanuel Vadot The standard Zbc bit-manipulation extension for carry-less 190f126890aSEmmanuel Vadot multiplication as ratified at commit 6d33919 ("Merge pull request 191f126890aSEmmanuel Vadot #158 from hirooih/clmul-fix-loop-end-condition") of riscv-bitmanip. 192f126890aSEmmanuel Vadot 193f126890aSEmmanuel Vadot - const: zbs 194f126890aSEmmanuel Vadot description: | 195f126890aSEmmanuel Vadot The standard Zbs bit-manipulation extension for single-bit 196f126890aSEmmanuel Vadot instructions as ratified at commit 6d33919 ("Merge pull request #158 197f126890aSEmmanuel Vadot from hirooih/clmul-fix-loop-end-condition") of riscv-bitmanip. 198f126890aSEmmanuel Vadot 199f126890aSEmmanuel Vadot - const: zicbom 200f126890aSEmmanuel Vadot description: 201f126890aSEmmanuel Vadot The standard Zicbom extension for base cache management operations as 202f126890aSEmmanuel Vadot ratified in commit 3dd606f ("Create cmobase-v1.0.pdf") of riscv-CMOs. 203f126890aSEmmanuel Vadot 204f126890aSEmmanuel Vadot - const: zicbop 205f126890aSEmmanuel Vadot description: 206f126890aSEmmanuel Vadot The standard Zicbop extension for cache-block prefetch instructions 207f126890aSEmmanuel Vadot as ratified in commit 3dd606f ("Create cmobase-v1.0.pdf") of 208f126890aSEmmanuel Vadot riscv-CMOs. 209f126890aSEmmanuel Vadot 210f126890aSEmmanuel Vadot - const: zicboz 211f126890aSEmmanuel Vadot description: 212f126890aSEmmanuel Vadot The standard Zicboz extension for cache-block zeroing as ratified 213f126890aSEmmanuel Vadot in commit 3dd606f ("Create cmobase-v1.0.pdf") of riscv-CMOs. 214f126890aSEmmanuel Vadot 215f126890aSEmmanuel Vadot - const: zicntr 216f126890aSEmmanuel Vadot description: 217f126890aSEmmanuel Vadot The standard Zicntr extension for base counters and timers, as 218f126890aSEmmanuel Vadot ratified in the 20191213 version of the unprivileged ISA 219f126890aSEmmanuel Vadot specification. 220f126890aSEmmanuel Vadot 221*84943d6fSEmmanuel Vadot - const: zicond 222*84943d6fSEmmanuel Vadot description: 223*84943d6fSEmmanuel Vadot The standard Zicond extension for conditional arithmetic and 224*84943d6fSEmmanuel Vadot conditional-select/move operations as ratified in commit 95cf1f9 225*84943d6fSEmmanuel Vadot ("Add changes requested by Ved during signoff") of riscv-zicond. 226*84943d6fSEmmanuel Vadot 227f126890aSEmmanuel Vadot - const: zicsr 228f126890aSEmmanuel Vadot description: | 229f126890aSEmmanuel Vadot The standard Zicsr extension for control and status register 230f126890aSEmmanuel Vadot instructions, as ratified in the 20191213 version of the 231f126890aSEmmanuel Vadot unprivileged ISA specification. 232f126890aSEmmanuel Vadot 233f126890aSEmmanuel Vadot This does not include Chapter 10, "Counters", which documents 234f126890aSEmmanuel Vadot special case read-only CSRs, that were moved into the Zicntr and 235f126890aSEmmanuel Vadot Zihpm extensions after the ratification of the 20191213 version of 236f126890aSEmmanuel Vadot the unprivileged specification. 237f126890aSEmmanuel Vadot 238f126890aSEmmanuel Vadot - const: zifencei 239f126890aSEmmanuel Vadot description: 240f126890aSEmmanuel Vadot The standard Zifencei extension for instruction-fetch fence, as 241f126890aSEmmanuel Vadot ratified in the 20191213 version of the unprivileged ISA 242f126890aSEmmanuel Vadot specification. 243f126890aSEmmanuel Vadot 244f126890aSEmmanuel Vadot - const: zihintpause 245f126890aSEmmanuel Vadot description: 246f126890aSEmmanuel Vadot The standard Zihintpause extension for pause hints, as ratified in 247f126890aSEmmanuel Vadot commit d8ab5c7 ("Zihintpause is ratified") of the riscv-isa-manual. 248f126890aSEmmanuel Vadot 249f126890aSEmmanuel Vadot - const: zihpm 250f126890aSEmmanuel Vadot description: 251f126890aSEmmanuel Vadot The standard Zihpm extension for hardware performance counters, as 252f126890aSEmmanuel Vadot ratified in the 20191213 version of the unprivileged ISA 253f126890aSEmmanuel Vadot specification. 254f126890aSEmmanuel Vadot 255f126890aSEmmanuel Vadot - const: ztso 256f126890aSEmmanuel Vadot description: 257f126890aSEmmanuel Vadot The standard Ztso extension for total store ordering, as ratified 258f126890aSEmmanuel Vadot in commit 2e5236 ("Ztso is now ratified.") of the 259f126890aSEmmanuel Vadot riscv-isa-manual. 260f126890aSEmmanuel Vadot 261f126890aSEmmanuel VadotadditionalProperties: true 262f126890aSEmmanuel Vadot... 263