saimaa: pc slot is 14th word (r0-r12,pc)

This commit is contained in:
SashegDev
2026-09-07 09:32:34 +00:00
parent 5f14a0eac5
commit 3258b0a6ff
+2 -1
View File
@@ -187,7 +187,8 @@ static void saimaa_machine_init(MachineState *machine)
uint32_t tgt = strtoul(sms->sblmain, NULL, 0); uint32_t tgt = strtoul(sms->sblmain, NULL, 0);
uint32_t zero = 0; uint32_t zero = 0;
cpu_physical_memory_write(0x085FFF00, &zero, 4); cpu_physical_memory_write(0x085FFF00, &zero, 4);
cpu_physical_memory_write(0x085FFF00 + 12 * 4, &tgt, 4); /* trampoline pops r0-r12,pc: pc slot is 14th word */
cpu_physical_memory_write(0x085FFF00 + 13 * 4, &tgt, 4);
printf("saimaa: stack-pc override -> 0x%x\n", tgt); printf("saimaa: stack-pc override -> 0x%x\n", tgt);
} }
printf("saimaa: SBL1 %s loaded (%zd bytes), entry 0x%lx\n", printf("saimaa: SBL1 %s loaded (%zd bytes), entry 0x%lx\n",