Files
tp/libs/JSystem/JAudio2/osdsp.cpp
T

63 lines
1.4 KiB
C++
Raw Normal View History

2021-04-01 02:07:58 +02:00
//
2021-03-28 22:49:05 +02:00
// Generated By: dol2asm
// Translation Unit: osdsp
2021-04-01 02:07:58 +02:00
//
2021-03-28 22:49:05 +02:00
2021-04-01 02:07:58 +02:00
#include "JSystem/JAudio2/osdsp.h"
2023-08-01 10:17:21 +03:00
#include "JSystem/JAudio2/osdsp_task.h"
#include "dolphin/os/OS.h"
#include "dolphin/dsp/dsp_task.h"
2021-03-28 22:49:05 +02:00
2021-04-01 02:07:58 +02:00
//
2021-03-28 22:49:05 +02:00
// Types:
2021-04-01 02:07:58 +02:00
//
2021-03-28 22:49:05 +02:00
2023-08-01 10:17:21 +03:00
// Unclear why this is a different type than DSPTaskInfo
struct STRUCT_DSP_TASK {
DSPTaskInfo info;
};
2021-03-28 22:49:05 +02:00
2021-04-01 02:07:58 +02:00
//
2021-03-28 22:49:05 +02:00
// Forward References:
2021-04-01 02:07:58 +02:00
//
2021-03-28 22:49:05 +02:00
2021-04-01 02:07:58 +02:00
//
2021-03-28 22:49:05 +02:00
// External References:
2021-04-01 02:07:58 +02:00
//
2021-03-28 22:49:05 +02:00
2021-04-01 02:07:58 +02:00
//
2021-03-28 22:49:05 +02:00
// Declarations:
2021-04-01 02:07:58 +02:00
//
2021-03-28 22:49:05 +02:00
/* ############################################################################################## */
2021-04-06 18:00:35 +02:00
/* 8029EA00-8029EA84 299340 0084+00 0/0 1/1 0/0 .text DSPAddTask */
2023-08-01 10:17:21 +03:00
DSPTaskInfo* DSPAddTask(DSPTaskInfo* task) {
if (DSP_prior_task == NULL) {
OSReport("Prior Task is not inited\n");
return NULL;
}
BOOL status = OSDisableInterrupts();
__DSP_insert_task(task);
task->state = 0;
task->flags = 1;
OSRestoreInterrupts(status);
return task;
2021-03-28 22:49:05 +02:00
}
/* ############################################################################################## */
2021-04-06 18:00:35 +02:00
/* 8029EAA0-8029EB1C 2993E0 007C+00 0/0 1/1 0/0 .text DSPAddPriorTask__FP15STRUCT_DSP_TASK */
2023-08-01 10:17:21 +03:00
void DSPAddPriorTask(STRUCT_DSP_TASK* task) {
if (DSP_prior_task != NULL) {
OSReport("Already inited prior DSP task\n");
return;
}
BOOL status = OSDisableInterrupts();
DSP_prior_task = (DSPTaskInfo*)task;
task->info.state = 0;
task->info.flags = 1;
__DSP_boot_task((DSPTaskInfo*)task);
OSRestoreInterrupts(status);
2021-03-28 22:49:05 +02:00
}