RISC-V: Correctly print supported extensions
authorTsukasa OI <research_trasio@irq.a4lg.com>
Mon, 14 Mar 2022 20:38:40 +0000 (13:38 -0700)
committerPalmer Dabbelt <palmer@rivosinc.com>
Thu, 17 Mar 2022 19:17:43 +0000 (12:17 -0700)
commit58004f266918912771ee71f46bfb92bf64ab9108
tree123f420e6b643691d890a6fd8dae9dcf88141087
parente783362eb54cd99b2cac8b3a9aeac942e6f6ac07
RISC-V: Correctly print supported extensions

This commit replaces BITS_PER_LONG with number of alphabet letters.

Current ISA pretty-printing code expects extension 'a' (bit 0) through
'z' (bit 25).  Although bit 26 and higher is not currently used (thus never
cause an issue in practice), it will be an annoying problem if we start to
use those in the future.

This commit disables printing high bits for now.

Reviewed-by: Anup Patel <anup@brainfault.org>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Tsukasa OI <research_trasio@irq.a4lg.com>
Signed-off-by: Atish Patra <atishp@rivosinc.com>
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
arch/riscv/kernel/cpufeature.c