Sys-clk-OC: fix emulator-mode detection

This commit is contained in:
KazushiM
2022-04-01 08:32:12 +08:00
parent 0bb4249a5f
commit ac43237b13
2 changed files with 29 additions and 25 deletions

View File

@@ -144,19 +144,11 @@ This project will not be actively maintained or regularly updated along with Atm
- Fusee will load any kips in `/atmosphere/kips/` automatically. - Fusee will load any kips in `/atmosphere/kips/` automatically.
### Patching sysmodules manually
## Build This method is only served as reference.
Grab necessary patches from the repo, then compile sys-clk, ReverseNX-RT and Atmosphere loader with devkitpro. Patched sysmodules would be persistent until pcv or ptm was updated in new HOS (usually in `x.0.0`).
If you are to install nro forwarders, remove `R_TRY(ValidateAcidSignature(std::addressof(g_original_meta_cache.meta)));` in `Atmosphere/stratosphere/loader/source/ldr_meta.cpp` to make them work again.
Uncompress the kip to make it work with config editor: `hactool -t kip1 Atmosphere/stratosphere/loader/loader.kip --uncompress=Atmosphere/stratosphere/loader/loader.kip`
### [DEPRECATED] Patching sysmodules manually
This method is NOT RECOMMENDED and NOT SUPPORTED ANY MORE, only served as reference.
<details> <details>
@@ -178,6 +170,18 @@ This method is NOT RECOMMENDED and NOT SUPPORTED ANY MORE, only served as refere
## Build
### Loader KIP
Grab necessary patches from the repo, then compile sys-clk, ReverseNX-RT and Atmosphere loader with devkitpro.
If you are to install nro forwarders, remove `R_TRY(ValidateAcidSignature(std::addressof(g_original_meta_cache.meta)));` in `Atmosphere/stratosphere/loader/source/ldr_meta.cpp` to make them work again.
Uncompress the kip to make it work with config editor: `hactool -t kip1 Atmosphere/stratosphere/loader/loader.kip --uncompress=Atmosphere/stratosphere/loader/loader.kip`
## Acknowledgement ## Acknowledgement
- CTCaer for [Hekate-ipl](https://github.com/CTCaer/hekate) bootloader, RE and hardware research - CTCaer for [Hekate-ipl](https://github.com/CTCaer/hekate) bootloader, RE and hardware research

View File

@@ -163,6 +163,7 @@ uint32_t ClockManager::GetHz(SysClkModule module)
return this->oc->maxMEMFreq; return this->oc->maxMEMFreq;
} }
}
/* Handle Handheld Emulator-Mode limit */ /* Handle Handheld Emulator-Mode limit */
if (this->context->realProfile == SysClkProfile_Handheld) if (this->context->realProfile == SysClkProfile_Handheld)
@@ -180,7 +181,6 @@ uint32_t ClockManager::GetHz(SysClkModule module)
break; break;
} }
} }
}
/* Handle CPU Auto Boost, no user-defined hz required */ /* Handle CPU Auto Boost, no user-defined hz required */
if (module == SysClkModule_CPU) if (module == SysClkModule_CPU)