Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
MorsGames
GitHub Repository: MorsGames/sm64plus
Path: blob/master/lib/src/__osSpSetPc.c
7857 views
1
#include "libultra_internal.h"
2
#include "hardware.h"
3
4
s32 __osSpSetPc(void *pc) {
5
register u32 status = HW_REG(SP_STATUS_REG, u32);
6
if (!(status & SPSTATUS_HALT)) {
7
return -1;
8
} else {
9
HW_REG(SP_PC_REG, void *) = pc;
10
return 0;
11
}
12
}
13
14