sysclk: RETRO super timings till 60hz, improve support

This commit is contained in:
souldbminersmwc
2026-03-20 20:57:41 -04:00
parent 71f31e8f6a
commit 1a42ad1a67
9 changed files with 52 additions and 17 deletions

View File

@@ -120,6 +120,7 @@ static const u32 gpuDvfsArray[] = { 590, 600, 610, 620, 630, 640, 650, 660, 670,
u32 dvfsTable[6][32] = {};
u64 dvfsAddress;
u32 ramVmin;
bool isRetro = false;
const char* Board::GetModuleName(SysClkModule module, bool pretty)
{
@@ -282,7 +283,7 @@ void Board::Initialize()
}
struct stat st = {0};
bool isRetro = stat("sdmc:/" FILE_CONFIG_DIR "/retro.flag", &st) == 0;
isRetro = (stat("sdmc:/" FILE_CONFIG_DIR "/retro.flag", &st) == 0);
u64 clkVirtAddr, dsiVirtAddr, outsize;
rc = svcQueryMemoryMapping(&clkVirtAddr, &outsize, 0x60006000, 0x1000);
@@ -309,6 +310,10 @@ void Board::Initialize()
}
bool Board::IsUsingRetroSuperDisplay() {
return isRetro;
}
void Board::fuseReadSpeedos() {
u64 pid = 0;

View File

@@ -69,6 +69,7 @@ class Board
static void SetCpuUvLevel(u32 levelLow, u32 levelHigh, u32 tbreakPoint);
static u32 CalculateTbreak(u32 table);
static bool IsHoag();
static bool IsUsingRetroSuperDisplay();
protected:
static void FetchHardwareInfos();
static PcvModule GetPcvModule(SysClkModule sysclkModule);

View File

@@ -152,6 +152,7 @@ ClockManager::ClockManager()
this->saltyNXIntegration->LoadSaltyNX();
}
this->context->isUsingRetroSuper = Board::IsUsingRetroSuperDisplay();
threadStart(&cpuGovernorTHREAD);
threadStart(&gpuGovernorTHREAD);
@@ -994,7 +995,7 @@ bool ClockManager::RefreshContext()
if(targetHz && this->context->realFreqs[HorizonOCModule_Display] > targetHz && this->context->profile != SysClkProfile_Docked)
this->context->realFreqs[HorizonOCModule_Display] = targetHz; // clean up display real freqs, should probably be moved to the real freqs loop?
if(!Board::IsHoag())
Board::SetDisplayRefreshDockedState(this->context->profile == SysClkProfile_Docked);
if(this->context->isSaltyNXInstalled)