summaryrefslogtreecommitdiff
path: root/src/code
diff options
context:
space:
mode:
authorAnghelo Carvajal <angheloalf95@gmail.com>2026-03-26 07:59:39 -0300
committerGitHub <noreply@github.com>2026-03-26 07:59:39 -0300
commita9da608e187f0f6874ee15491347751751fcedeb (patch)
tree3c6a69aad3623d66afd2ab6e46b2a693a2529b2d /src/code
parent02eafced87237be63b32ddc187ea85faf92afe00 (diff)
[n64-jp-1.1] CIC6105.c matched (#1843)
* match CIC6105.c * Renames and fixes * Fix bss * format * Review * Version check inequalities
Diffstat (limited to 'src/code')
-rw-r--r--src/code/audio_thread_manager.c4
-rw-r--r--src/code/graph.c2
-rw-r--r--src/code/osFlash.c2
-rw-r--r--src/code/sys_math3d.c2
-rw-r--r--src/code/z_jpeg.c14
5 files changed, 13 insertions, 11 deletions
diff --git a/src/code/audio_thread_manager.c b/src/code/audio_thread_manager.c
index d6661b700..25aa6c11f 100644
--- a/src/code/audio_thread_manager.c
+++ b/src/code/audio_thread_manager.c
@@ -16,7 +16,7 @@ void AudioMgr_HandleRetrace(AudioMgr* audioMgr) {
OSTimer timer;
s32 msg;
- if (SREG(20) > 0) {
+ if (R_AUDIOMGR_DEBUG_LEVEL > 0) {
audioMgr->rspTask = NULL;
}
@@ -37,7 +37,7 @@ void AudioMgr_HandleRetrace(AudioMgr* audioMgr) {
Sched_SendNotifyMsg(audioMgr->sched);
}
- if (SREG(20) >= 2) {
+ if (R_AUDIOMGR_DEBUG_LEVEL >= 2) {
rspTask = NULL;
} else {
rspTask = AudioThread_Update();
diff --git a/src/code/graph.c b/src/code/graph.c
index f823f995a..d25ec751f 100644
--- a/src/code/graph.c
+++ b/src/code/graph.c
@@ -236,7 +236,7 @@ retry:
void Graph_UpdateGame(GameState* gameState) {
GameState_GetInput(gameState);
GameState_IncrementFrameCount(gameState);
- if (SREG(20) < 3) {
+ if (R_AUDIOMGR_DEBUG_LEVEL < 3) {
Audio_Update();
}
}
diff --git a/src/code/osFlash.c b/src/code/osFlash.c
index 17162c53c..bdc59e8f2 100644
--- a/src/code/osFlash.c
+++ b/src/code/osFlash.c
@@ -3,6 +3,8 @@
#include "alignment.h"
#include "macros.h"
+#pragma increment_block_number "n64-us:188"
+
u32 __osFlashID[4] ALIGNED(8);
OSIoMesg __osFlashMsg ALIGNED(8);
OSMesgQueue __osFlashMessageQ ALIGNED(8);
diff --git a/src/code/sys_math3d.c b/src/code/sys_math3d.c
index 039f58829..a0fb5fbd6 100644
--- a/src/code/sys_math3d.c
+++ b/src/code/sys_math3d.c
@@ -6,7 +6,7 @@
#include "macros.h"
-#pragma increment_block_number "n64-us:124"
+#pragma increment_block_number "n64-us:122"
// The bss index at this point should be 184
diff --git a/src/code/z_jpeg.c b/src/code/z_jpeg.c
index 377080e7d..91a9900af 100644
--- a/src/code/z_jpeg.c
+++ b/src/code/z_jpeg.c
@@ -25,7 +25,7 @@ extern u64 njpgdspMainDataStart[];
* Configures and schedules a JPEG decoder task and waits for it to finish.
*/
void Jpeg_ScheduleDecoderTask(JpegContext* jpegCtx) {
- static OSTask_t sJpegTask = {
+ static OSTask sJpegTask = {
M_NJPEGTASK, // type
0, // flags
NULL, // ucode_boot
@@ -54,18 +54,18 @@ void Jpeg_ScheduleDecoderTask(JpegContext* jpegCtx) {
workBuf->taskData.qTableUPtr = &workBuf->qTableU;
workBuf->taskData.qTableVPtr = &workBuf->qTableV;
- sJpegTask.flags = 0;
- sJpegTask.ucode_boot = SysUcode_GetUCodeBoot();
- sJpegTask.ucode_boot_size = SysUcode_GetUCodeBootSize();
- sJpegTask.yield_data_ptr = (u64*)&workBuf->yieldData;
- sJpegTask.data_ptr = (u64*)&workBuf->taskData;
+ sJpegTask.t.flags = 0;
+ sJpegTask.t.ucode_boot = SysUcode_GetUCodeBoot();
+ sJpegTask.t.ucode_boot_size = SysUcode_GetUCodeBootSize();
+ sJpegTask.t.yield_data_ptr = (u64*)&workBuf->yieldData;
+ sJpegTask.t.data_ptr = (u64*)&workBuf->taskData;
jpegCtx->scTask.next = NULL;
jpegCtx->scTask.flags = OS_SC_NEEDS_RSP;
jpegCtx->scTask.msgQ = &jpegCtx->mq;
jpegCtx->scTask.msg = NULL;
jpegCtx->scTask.framebuffer = NULL;
- jpegCtx->scTask.list.t = sJpegTask;
+ jpegCtx->scTask.list = sJpegTask;
osSendMesg(&gScheduler.cmdQueue, (OSMesg*)&jpegCtx->scTask, OS_MESG_BLOCK);
Sched_SendNotifyMsg(&gScheduler); // osScKickEntryMsg