diff options
author | mrb0nk500 <b0nk@b0nk.xyz> | 2023-02-01 18:45:02 -0400 |
---|---|---|
committer | mrb0nk500 <b0nk@b0nk.xyz> | 2023-02-01 18:50:25 -0400 |
commit | 9fa0a7f1da1b70bee995f53c6c96c43189018772 (patch) | |
tree | 114548896790eaff23cdca84a025281de86bbb51 /include/dolphin/os/OSReset.h | |
parent | 2ba3289286bbfcf9fcc13fd135d976058d8b6c2e (diff) |
global: Import Dolphin SDK
This version comes from the Metroid Prime decompilation project.
https://github.com/PrimeDecomp/prime
Diffstat (limited to 'include/dolphin/os/OSReset.h')
-rw-r--r-- | include/dolphin/os/OSReset.h | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/include/dolphin/os/OSReset.h b/include/dolphin/os/OSReset.h new file mode 100644 index 0000000..6c1e33b --- /dev/null +++ b/include/dolphin/os/OSReset.h @@ -0,0 +1,48 @@ +#ifndef _DOLPHIN_OSRESET +#define _DOLPHIN_OSRESET + +#include <types.h> + +#ifdef __cplusplus +extern "C" { +#endif + +#define OS_RESETCODE_RESTART 0x80000000 +#define OS_RESETCODE_SYSTEM 0x40000000 + +#define OS_RESETCODE_EXEC 0xC0000000 +#define OS_RESETCODE_NETCONFIG 0xC0010000 + +#define OS_RESET_TIMEOUT OSMillisecondsToTicks(1000) + +#define OS_RESET_RESTART 0 +#define OS_RESET_HOTRESET 1 +#define OS_RESET_SHUTDOWN 2 + +#define OS_RESET_PRIO_SO 110 +#define OS_RESET_PRIO_IP 111 +#define OS_RESET_PRIO_CARD 127 +#define OS_RESET_PRIO_PAD 127 +#define OS_RESET_PRIO_GX 127 +#define OS_RESET_PRIO_ALARM 4294967295 + +typedef BOOL (*OSResetFunction)(BOOL final); +typedef struct OSResetFunctionInfo OSResetFunctionInfo; + +struct OSResetFunctionInfo { + // public + OSResetFunction func; + u32 priority; + + // private + OSResetFunctionInfo* next; + OSResetFunctionInfo* prev; +}; + +void __OSDoHotReset(s32 arg0); + +#ifdef __cplusplus +} +#endif + +#endif // _DOLPHIN_OSRESET |