Skip the raw ID dump once id_phase is consumed; record the full console pass
The whole gc_bba_test suite now passes on a real GameCube: Identity (device ID 04 02 02 00, HIPR, NWAYS), Registers, Reset/control, EXI integrity (speed sweep ok=[1,1,1,1,1,1], per-speed dump clean at all six indices, raw reg dump 0x17 in slot 0), Ethernet, and SPRAM/DMA -- at the real 27 MHz EXI rate. The one reported failure was t_raw_id, and it was not a fault: an earlier suite had already issued the NCRA reset that clears id_phase, after which address 0 correctly reads back NCRA. t_devid already guarded for this; t_raw_id did not, so a full run cried wolf. It now returns SKIP like t_devid, and both messages say reflash/reset the FPGA rather than power-cycle the console, which is what actually restores id_phase. CLAUDE.md records the device-ID fix and, importantly, that simulation CANNOT reproduce the bug it fixed -- bba_top passed the ID at EXI_HALF=1 beforehand, because sim's sync-to-EXI latency ratio does not match silicon closely enough to miss a 296 ns window. Anyone "simplifying" the ID back into the register file will keep a green suite and break hardware. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -16,7 +16,7 @@ static int t_devid(char *m, size_t n)
|
||||
u8 b[4];
|
||||
int rc;
|
||||
if (g_ncra_reset_done) {
|
||||
snprintf(m, n, "skipped: one-shot, needs a console power cycle");
|
||||
snprintf(m, n, "skipped: id_phase is a one-shot; reflash/reset the FPGA");
|
||||
return 2;
|
||||
}
|
||||
if ((rc = bba_devid(b)) < 0) { snprintf(m, n, "EXI error %d", rc); return 1; }
|
||||
@@ -238,6 +238,14 @@ static int t_raw_id(char *m, size_t n)
|
||||
u8 b[8];
|
||||
int i, at = -1, rc;
|
||||
u16 h = 0x0000;
|
||||
/* Same one-shot as t_devid. Without this guard a full run reports a
|
||||
* FAILURE here purely because an earlier suite issued the NCRA reset
|
||||
* that clears id_phase -- address 0 then reads back NCRA, which is
|
||||
* correct behaviour, not a fault. */
|
||||
if (g_ncra_reset_done) {
|
||||
snprintf(m, n, "skipped: id_phase is a one-shot; reflash/reset the FPGA");
|
||||
return 2;
|
||||
}
|
||||
if ((rc = begin_raw()) < 0) { snprintf(m, n, "EXI error %d", rc); return 1; }
|
||||
EXI_Imm(BBA_EXI_CHAN, &h, 2, EXI_WRITE, NULL);
|
||||
EXI_Sync(BBA_EXI_CHAN);
|
||||
|
||||
Reference in New Issue
Block a user