Skip to content
This repository was archived by the owner on Mar 7, 2026. It is now read-only.

Commit d8e7175

Browse files
committed
riscv32: Add very basic support for Hazard3 SoC on Icebreaker SPRAM
1 parent ab164b5 commit d8e7175

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

src/target/riscv32.c

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,13 @@ static void riscv32_regs_write(target_s *target, const void *data);
7171
static int riscv32_breakwatch_set(target_s *target, breakwatch_s *breakwatch);
7272
static int riscv32_breakwatch_clear(target_s *target, breakwatch_s *breakwatch);
7373

74+
bool hazard3_probe(target_s *const target)
75+
{
76+
target->driver = "Hazard3";
77+
target_add_ram32(target, 0x0, 131072);
78+
return true;
79+
}
80+
7481
bool riscv32_probe(target_s *const target)
7582
{
7683
/* 'E' base ISA has 16 GPRs + PC, 'I' base ISA has 32 GPRs + PC */
@@ -102,6 +109,9 @@ bool riscv32_probe(target_s *const target)
102109
PROBE(ch32v003x_probe);
103110
PROBE(ch32vx_probe);
104111
break;
112+
case 0xe77:
113+
PROBE(hazard3_probe);
114+
break;
105115
default:
106116
break;
107117
}

0 commit comments

Comments
 (0)