|
|
|
@ -127,6 +127,31 @@ void WriteReg0x10(Service::Interface* self) { |
|
|
|
LOG_WARNING(Service_DSP, "(STUBBED) called"); |
|
|
|
} |
|
|
|
|
|
|
|
/**
|
|
|
|
* DSP_DSP::WriteProcessPipe service function |
|
|
|
* Inputs: |
|
|
|
* 1 : Number |
|
|
|
* 2 : Size |
|
|
|
* 3 : (size <<14) | 0x402 |
|
|
|
* 4 : Buffer |
|
|
|
* Outputs: |
|
|
|
* 0 : Return header |
|
|
|
* 1 : Result of function, 0 on success, otherwise error code |
|
|
|
*/ |
|
|
|
void WriteProcessPipe(Service::Interface* self) { |
|
|
|
u32* cmd_buff = Kernel::GetCommandBuffer(); |
|
|
|
|
|
|
|
u32 number = cmd_buff[1]; |
|
|
|
u32 size = cmd_buff[2]; |
|
|
|
u32 new_size = cmd_buff[3]; |
|
|
|
u32 buffer = cmd_buff[4]; |
|
|
|
|
|
|
|
cmd_buff[1] = RESULT_SUCCESS.raw; // No error
|
|
|
|
|
|
|
|
LOG_WARNING(Service_DSP, "(STUBBED) called number=%u, size=0x%08X, new_size=0x%08X, buffer=0x%08X", |
|
|
|
number, size, new_size, buffer); |
|
|
|
} |
|
|
|
|
|
|
|
/**
|
|
|
|
* DSP_DSP::ReadPipeIfPossible service function |
|
|
|
* Inputs: |
|
|
|
@ -169,6 +194,41 @@ void ReadPipeIfPossible(Service::Interface* self) { |
|
|
|
LOG_WARNING(Service_DSP, "(STUBBED) called size=0x%08X, buffer=0x%08X", size, addr); |
|
|
|
} |
|
|
|
|
|
|
|
/**
|
|
|
|
* DSP_DSP::SetSemaphoreMask service function |
|
|
|
* Inputs: |
|
|
|
* 1 : Mask |
|
|
|
* Outputs: |
|
|
|
* 1 : Result of function, 0 on success, otherwise error code |
|
|
|
*/ |
|
|
|
void SetSemaphoreMask(Service::Interface* self) { |
|
|
|
u32* cmd_buff = Kernel::GetCommandBuffer(); |
|
|
|
|
|
|
|
u32 mask = cmd_buff[1]; |
|
|
|
|
|
|
|
cmd_buff[1] = RESULT_SUCCESS.raw; // No error
|
|
|
|
|
|
|
|
LOG_WARNING(Service_DSP, "(STUBBED) called mask=0x%08X", mask); |
|
|
|
} |
|
|
|
|
|
|
|
/**
|
|
|
|
* DSP_DSP::GetHeadphoneStatus service function |
|
|
|
* Inputs: |
|
|
|
* 1 : None |
|
|
|
* Outputs: |
|
|
|
* 1 : Result of function, 0 on success, otherwise error code |
|
|
|
* 2 : The headphone status response, 0 = Not using headphones?, |
|
|
|
* 1 = using headphones? |
|
|
|
*/ |
|
|
|
void GetHeadphoneStatus(Service::Interface* self) { |
|
|
|
u32* cmd_buff = Kernel::GetCommandBuffer(); |
|
|
|
|
|
|
|
cmd_buff[1] = RESULT_SUCCESS.raw; // No error
|
|
|
|
cmd_buff[2] = 0; // Not using headphones?
|
|
|
|
|
|
|
|
LOG_WARNING(Service_DSP, "(STUBBED) called"); |
|
|
|
} |
|
|
|
|
|
|
|
const Interface::FunctionInfo FunctionTable[] = { |
|
|
|
{0x00010040, nullptr, "RecvData"}, |
|
|
|
{0x00020040, nullptr, "RecvDataIsReady"}, |
|
|
|
@ -179,7 +239,7 @@ const Interface::FunctionInfo FunctionTable[] = { |
|
|
|
{0x00090040, nullptr, "ClearSemaphore"}, |
|
|
|
{0x000B0000, nullptr, "CheckSemaphoreRequest"}, |
|
|
|
{0x000C0040, ConvertProcessAddressFromDspDram, "ConvertProcessAddressFromDspDram"}, |
|
|
|
{0x000D0082, nullptr, "WriteProcessPipe"}, |
|
|
|
{0x000D0082, WriteProcessPipe, "WriteProcessPipe"}, |
|
|
|
{0x001000C0, ReadPipeIfPossible, "ReadPipeIfPossible"}, |
|
|
|
{0x001100C2, LoadComponent, "LoadComponent"}, |
|
|
|
{0x00120000, nullptr, "UnloadComponent"}, |
|
|
|
@ -187,13 +247,13 @@ const Interface::FunctionInfo FunctionTable[] = { |
|
|
|
{0x00140082, nullptr, "InvalidateDCache"}, |
|
|
|
{0x00150082, RegisterInterruptEvents, "RegisterInterruptEvents"}, |
|
|
|
{0x00160000, GetSemaphoreEventHandle, "GetSemaphoreEventHandle"}, |
|
|
|
{0x00170040, nullptr, "SetSemaphoreMask"}, |
|
|
|
{0x00170040, SetSemaphoreMask, "SetSemaphoreMask"}, |
|
|
|
{0x00180040, nullptr, "GetPhysicalAddress"}, |
|
|
|
{0x00190040, nullptr, "GetVirtualAddress"}, |
|
|
|
{0x001A0042, nullptr, "SetIirFilterI2S1_cmd1"}, |
|
|
|
{0x001B0042, nullptr, "SetIirFilterI2S1_cmd2"}, |
|
|
|
{0x001C0082, nullptr, "SetIirFilterEQ"}, |
|
|
|
{0x001F0000, nullptr, "GetHeadphoneStatus"}, |
|
|
|
{0x001F0000, GetHeadphoneStatus, "GetHeadphoneStatus"}, |
|
|
|
{0x00210000, nullptr, "GetIsDspOccupied"}, |
|
|
|
}; |
|
|
|
|
|
|
|
|