fix cvb patch to consider lowering max cpu volt

This commit is contained in:
hanabbi
2023-06-29 01:51:55 +09:00
parent 049d654c1d
commit 25346f9839

View File

@@ -178,7 +178,12 @@ Result CpuFreqCvbTable(u32* ptr) {
cvb_entry_t* customize_table = const_cast<cvb_entry_t *>(isMariko ? (C.marikoCpuUV ? C.marikoCpuDvfsTableSLT : C.marikoCpuDvfsTable) : C.eristaCpuDvfsTable);
u32 cpu_max_volt = isMariko ? C.marikoCpuMaxVolt : C.eristaCpuMaxVolt;
u32 cpu_freq_threshold = isMariko ? (C.marikoCpuUV ? 2193'000 : 2091'000) : 1887'000;
u32 cpu_freq_threshold = 1020'000;
if (isMariko) {
cpu_freq_threshold = C.marikoCpuUV ? 2193'000 : 2091'000;
} else {
cpu_freq_threshold = cpu_max_volt >= 1235 ? 1887'000 : 1428'000;
}
size_t default_entry_count = GetDvfsTableEntryCount(default_table);
size_t default_table_size = default_entry_count * sizeof(cvb_entry_t);