Skip to content

Commit

Permalink
target/riscv: vector CSRs are optional
Browse files Browse the repository at this point in the history
This is a fix to a mistake made in
ea7e174.

The newly introduced `gdb_regno_exist()` function was missing a part
regarding vector CSRs:
ea7e174#diff-b4aa16f9e42cb8f0934baa7c8e0ec9c70a369bef98b99b26ae2e896c8aa95d6aL6163-L6171

Change-Id: I0361ea4dce8df5be748e2c6e7e6838029d3a7120
Signed-off-by: Evgeniy Naydanov <evgeniy.naydanov@syntacore.com>
  • Loading branch information
en-sc committed Jun 25, 2024
1 parent fdd07f1 commit 3caff1a
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/target/riscv/riscv.c
Original file line number Diff line number Diff line change
Expand Up @@ -6626,6 +6626,14 @@ static bool gdb_regno_exist(const struct target *target, uint32_t regno)
case CSR_FRM:
case CSR_FCSR:
return riscv_supports_extension(target, 'F');
case CSR_VSTART:
case CSR_VXSAT:
case CSR_VXRM:
case CSR_VL:
case CSR_VCSR:
case CSR_VTYPE:
case CSR_VLENB:
return vlenb_exists(target);
case CSR_SCOUNTEREN:
case CSR_SSTATUS:
case CSR_STVEC:
Expand Down

0 comments on commit 3caff1a

Please sign in to comment.