summaryrefslogtreecommitdiff
path: root/src/code/main.c
diff options
context:
space:
mode:
authorDragorn421 <Dragorn421@users.noreply.github.com>2024-09-08 00:47:22 +0200
committerGitHub <noreply@github.com>2024-09-07 16:47:22 -0600
commit2e2b2e2c7a59bd3544de5e73f72a03b947ec8ab3 (patch)
treef8b347b1649933af455a23aee0bb31f67af1fbc1 /src/code/main.c
parente982c44721a76972de0e16a971e6447fc68f3f67 (diff)
[headers] Move padmgr, scheduler, irqmgr symbols to respective headers; add segmented_address.h (#1681)
* [headers] Move padmgr, scheduler symbols to respective headers * fix revealed header problems * Fix bss * review * bss * segmented_address.h --------- Co-authored-by: Derek Hensley <hensley.derek58@gmail.com>
Diffstat (limited to 'src/code/main.c')
-rw-r--r--src/code/main.c39
1 files changed, 22 insertions, 17 deletions
diff --git a/src/code/main.c b/src/code/main.c
index f45a1dfb2..e2822a9a8 100644
--- a/src/code/main.c
+++ b/src/code/main.c
@@ -1,19 +1,13 @@
-#include "audiomgr.h"
-#include "fault.h"
-#include "idle.h"
-#include "irqmgr.h"
-#include "padmgr.h"
-#include "scheduler.h"
-#include "CIC6105.h"
+#include "prevent_bss_reordering.h"
+#include "ultra64.h"
#include "stack.h"
-#include "stackcheck.h"
// Variables are put before most headers as a hacky way to bypass bss reordering
OSMesgQueue sSerialEventQueue;
OSMesg sSerialMsgBuf[1];
u32 gSegments[NUM_SEGMENTS];
-Scheduler gScheduler;
-IrqMgrClient sIrqClient;
+struct Scheduler gScheduler;
+struct IrqMgrClient sIrqClient;
OSMesgQueue sIrqMgrMsgQueue;
OSMesg sIrqMgrMsgBuf[60];
OSThread gGraphThread;
@@ -21,17 +15,28 @@ STACK(sGraphStack, 0x1800);
STACK(sSchedStack, 0x600);
STACK(sAudioStack, 0x800);
STACK(sPadMgrStack, 0x500);
-StackEntry sGraphStackInfo;
-StackEntry sSchedStackInfo;
-StackEntry sAudioStackInfo;
-StackEntry sPadMgrStackInfo;
-AudioMgr sAudioMgr;
+struct StackEntry sGraphStackInfo;
+struct StackEntry sSchedStackInfo;
+struct StackEntry sAudioStackInfo;
+struct StackEntry sPadMgrStackInfo;
+struct AudioMgr sAudioMgr;
static s32 sBssPad;
-PadMgr gPadMgr;
+struct PadMgr gPadMgr;
#include "main.h"
+
+#include "audiomgr.h"
#include "buffers.h"
-#include "global.h"
+#include "CIC6105.h"
+#include "fault.h"
+#include "idle.h"
+#include "irqmgr.h"
+#include "padmgr.h"
+#include "regs.h"
+#include "segment_symbols.h"
+#include "stack.h"
+#include "stackcheck.h"
+#include "scheduler.h"
#include "sys_initial_check.h"
#include "system_heap.h"
#include "z64nmi_buff.h"