BIOSHLE: Implement GetOSDParamConfig2 for DST/24h/Format settings

This commit is contained in:
refractionpcsx2 2020-11-18 16:01:39 +00:00
parent e8ebb7d23d
commit 5a77ed14bf
2 changed files with 17 additions and 2 deletions

View File

@ -132,7 +132,7 @@ const char * const R5900::bios[256]=
"KSeg0", "EnableCache", "DisableCache", "GetCop0", "KSeg0", "EnableCache", "DisableCache", "GetCop0",
"FlushCache", "RFU101", "CpuConfig", "iGetCop0", "FlushCache", "RFU101", "CpuConfig", "iGetCop0",
"iFlushCache", "RFU105", "iCpuConfig", "sceSifStopDma", "iFlushCache", "RFU105", "iCpuConfig", "sceSifStopDma",
"SetCPUTimerHandler", "SetCPUTimer", "SetOsdConfigParam2", "SetOsdConfigParam2", "SetCPUTimerHandler", "SetCPUTimer", "SetOsdConfigParam2", "GetOsdConfigParam2",
//0x70 //0x70
"GsGetIMR_iGsGetIMR", "GsGetIMR_iGsPutIMR", "SetPgifHandler", "SetVSyncFlag", "GsGetIMR_iGsGetIMR", "GsGetIMR_iGsPutIMR", "SetPgifHandler", "SetVSyncFlag",
"RFU116", "print", "sceSifDmaStat_isceSifDmaStat", "sceSifSetDma_isceSifSetDma", "RFU116", "print", "sceSifDmaStat_isceSifDmaStat", "sceSifSetDma_isceSifSetDma",
@ -950,6 +950,7 @@ void SYSCALL()
u8 params[16]; u8 params[16];
cdvdReadLanguageParams(params); cdvdReadLanguageParams(params);
u32 osdconf = 0; u32 osdconf = 0;
u32 timezone = params[4] | ((u32)(params[3] & 0x7) << 8); u32 timezone = params[4] | ((u32)(params[3] & 0x7) << 8);
@ -962,8 +963,21 @@ void SYSCALL()
memcpy(pointer, &osdconf, 4); memcpy(pointer, &osdconf, 4);
return; return;
} }
break; break;
case Syscall::GetOSParamConfig2:
if (g_SkipBiosHack)
{
u8* pointer = (u8*)PSM(cpuRegs.GPR.n.a0.UL[0]);
u8 params[16];
cdvdReadLanguageParams(params);
u32 osdconf2 = (u32)((params[3] & 0x78) << 1); // Daylight Savings, 24hr clock, Date format
memcpy(pointer, &osdconf2, 4);
return;
}
break;
case Syscall::SetVTLBRefillHandler: case Syscall::SetVTLBRefillHandler:
DevCon.Warning("A tlb refill handler is set. New handler %x", (u32*)PSM(cpuRegs.GPR.n.a1.UL[0])); DevCon.Warning("A tlb refill handler is set. New handler %x", (u32*)PSM(cpuRegs.GPR.n.a1.UL[0]));
break; break;

View File

@ -22,6 +22,7 @@ enum Syscall : u8
SetGsCrt = 2, SetGsCrt = 2,
SetVTLBRefillHandler = 13, SetVTLBRefillHandler = 13,
GetOSParamConfig = 75, GetOSParamConfig = 75,
GetOSParamConfig2 = 111,
sysPrintOut = 117, sysPrintOut = 117,
sceSifSetDma = 119, sceSifSetDma = 119,
Deci2Call = 124 Deci2Call = 124