diff options
author | Conor Dooley <conor.dooley@microchip.com> | 2024-03-04 23:28:35 +0000 |
---|---|---|
committer | Leo Yu-Chi Liang <ycliang@andestech.com> | 2024-03-12 14:36:13 +0800 |
commit | 0d95add3b1c7e17d979021505fcc138f74d95b88 (patch) | |
tree | 6c84650c0901bbb4f68bba1a536ec5df162ed09c /drivers/ddr/marvell/a38x/ddr3_training_bist.c | |
parent | e1d7ff220c5b0fb6c0a3a7938058cdc329f67031 (diff) |
riscv: cpu: improve multi-letter extension detection in supports_extension()
The first multi-letter extension after the single-letter extensions does
not have to be preceded by an underscore, which could cause the parser
to mistakenly find a single-letter extension after the start of the
multi-letter portion of the string.
Three letters precede multi-letter extensions (s, x & z), none of which
are valid single-letter extensions. The dt-binding also allows
multi-letter extensions starting with h, but no such extension have been
frozen or ratified, and the unprivileged spec no longer uses "h" as a
prefix for multi-letter hypervisor extensions, having moved to "sh"
instead. For that reason, modify the parser to stop at s, x & z to prevent
this overrun, ignoring h.
Signed-off-by: Conor Dooley <conor.dooley@microchip.com>
Reviewed-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Diffstat (limited to 'drivers/ddr/marvell/a38x/ddr3_training_bist.c')
0 files changed, 0 insertions, 0 deletions