voice: Return ORBIS_FAIL in sceVoiceReadFromOPort to fix BO3 hang - #4792
voice: Return ORBIS_FAIL in sceVoiceReadFromOPort to fix BO3 hang#4792Modified17 wants to merge 1 commit into
Conversation
| s32 PS4_SYSV_ABI sceVoiceReadFromOPort() { | ||
| LOG_ERROR(Lib_Voice, "(STUBBED) called"); | ||
| return ORBIS_OK; | ||
| return ORBIS_FAIL; |
There was a problem hiding this comment.
There's probably a better error code to use here, libraries don't usually return the value ORBIS_FAIL.
There was a problem hiding this comment.
maybe test this 0x804e0801 = The voice library has not been initialized.
There was a problem hiding this comment.
I'd argue a not-initialized error is probably just as inaccurate. For a stub error code, probably best to do 0x804E0803 (ORBIS_VOICE_ERROR_GENERAL) or 0x804E0808 (ORBIS_VOICE_ERROR_RESOURCE_INSUFFICIENT).
Best solution would be testing the function to see how it behaves when there's no data to read, and stubbing whatever that behavior is. I can do that myself if needed.
There was a problem hiding this comment.
int sceVoiceReadFromOPort(
uint32_t ops,
void *data,
uint32_t *size
); maybe you can just *size=0;
Fixes a startup hang in BO3 where the game gets stuck polling for microphone input. Returning ORBIS_FAIL bypasses the loop.
With this fix, BO3 successfully reaches in-game (tested via null gpu).