OSDN Git Service

RISC-V: don't parse dt/acpi isa string to get rv32/rv64
authorHeiko Stuebner <heiko.stuebner@vrull.eu>
Thu, 13 Jul 2023 12:11:00 +0000 (13:11 +0100)
committerPalmer Dabbelt <palmer@rivosinc.com>
Tue, 25 Jul 2023 23:26:16 +0000 (16:26 -0700)
commit67270fb388feb3ab7b8f1c8e2825d43237ffa7a0
treee5da02a3e58f9295b64b39c1d4d9380db7f11eb9
parent23059893967826467e36c6d9f7428cc79dd48a11
RISC-V: don't parse dt/acpi isa string to get rv32/rv64

When filling hwcap the kernel already expects the isa string to start with
rv32 if CONFIG_32BIT and rv64 if CONFIG_64BIT.

So when recreating the runtime isa-string we can also just go the other way
to get the correct starting point for it.

Signed-off-by: Heiko Stuebner <heiko.stuebner@vrull.eu>
Reviewed-by: Andrew Jones <ajones@ventanamicro.com>
Reviewed-by: Evan Green <evan@rivosinc.com>
Co-developed-by: Conor Dooley <conor.dooley@microchip.com>
Signed-off-by: Conor Dooley <conor.dooley@microchip.com>
Link: https://lore.kernel.org/r/20230713-masculine-saddlebag-67a94966b091@wendy
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
arch/riscv/kernel/cpu.c