Add test case for `riscv expose_custom`.
[riscv-tests.git] / debug / targets / RISC-V / spike-rtos.cfg
1 # Connect to a mult-icore RISC-V target, exposing each hart as a thread.
2 adapter_khz 10000
3
4 interface remote_bitbang
5 remote_bitbang_host $::env(REMOTE_BITBANG_HOST)
6 remote_bitbang_port $::env(REMOTE_BITBANG_PORT)
7
8 set _CHIPNAME riscv
9 jtag newtap $_CHIPNAME cpu -irlen 5 -expected-id 0x10e31913
10
11 set _TARGETNAME $_CHIPNAME.cpu
12 target create $_TARGETNAME riscv -chain-position $_TARGETNAME -rtos riscv
13
14 gdb_report_data_abort enable
15 gdb_report_register_access_error enable
16
17 # Expose an unimplemented CSR so we can test non-existent register access
18 # behavior.
19 riscv expose_csrs 2288
20 riscv expose_custom 1,12345-12348
21
22 init
23
24 set challenge [ocd_riscv authdata_read]
25 riscv authdata_write [expr $challenge + 1]
26
27 halt