arch: riscv: Add the support for Zbkb ISA extension

Introduce the missing flag to compile code with Zbkb extension,
which has already been supported by the GCC 12 in current SDK.

Signed-off-by: Andy Lin <andylinpersonal@gmail.com>
This commit is contained in:
Andy Lin
2026-01-07 01:42:17 +08:00
committed by Alberto Escolar
parent 261dfbc765
commit d807e39a2c
2 changed files with 12 additions and 0 deletions

View File

@@ -237,6 +237,14 @@ config RISCV_ISA_EXT_ZBC
The Zbc instructions can be used for carry-less multiplication that
is the multiplication in the polynomial ring over GF(2).
config RISCV_ISA_EXT_ZBKB
bool
help
(Zbkb) - Zbkb BitManip Extension (Bit-manipulation for Cryptography)
The Zbkb instructions can be used for accelerating cryptography workloads
and contain rotation, reversion, packing and some advanced bit-manipulation.
config RISCV_ISA_EXT_ZBS
bool
help

View File

@@ -118,6 +118,10 @@ if(CONFIG_RISCV_ISA_EXT_ZBC)
string(CONCAT riscv_march ${riscv_march} "_zbc")
endif()
if(CONFIG_RISCV_ISA_EXT_ZBKB)
string(CONCAT riscv_march ${riscv_march} "_zbkb")
endif()
if(CONFIG_RISCV_ISA_EXT_ZBS)
string(CONCAT riscv_march ${riscv_march} "_zbs")
endif()