loader: hopefully fix gpu pll patch on mariko
This commit is contained in:
@@ -190,13 +190,11 @@ namespace ams::ldr::oc::pcv::mariko
|
|||||||
R_SUCCEED();
|
R_SUCCEED();
|
||||||
}
|
}
|
||||||
|
|
||||||
Result GpuFreqPllLimit(u32 *ptr)
|
Result GpuFreqPllLimit(u32 *ptr) {
|
||||||
{
|
|
||||||
clk_pll_param *entry = reinterpret_cast<clk_pll_param *>(ptr);
|
clk_pll_param *entry = reinterpret_cast<clk_pll_param *>(ptr);
|
||||||
|
|
||||||
// All zero except for freq
|
// All zero except for freq
|
||||||
for (size_t i = 1; i < sizeof(clk_pll_param) / sizeof(u32); i++)
|
for (size_t i = 1; i < sizeof(clk_pll_param) / sizeof(u32); i++) {
|
||||||
{
|
|
||||||
R_UNLESS(*(ptr + i) == 0, ldr::ResultInvalidGpuPllEntry());
|
R_UNLESS(*(ptr + i) == 0, ldr::ResultInvalidGpuPllEntry());
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -533,7 +531,7 @@ namespace ams::ldr::oc::pcv::mariko
|
|||||||
{"CPU Volt Dfll", &CpuVoltDfll, 1, nullptr, 0x0000FFCF},
|
{"CPU Volt Dfll", &CpuVoltDfll, 1, nullptr, 0x0000FFCF},
|
||||||
{"GPU Freq Table", GpuFreqCvbTable<true>, 1, nullptr, GpuCvbDefaultMaxFreq},
|
{"GPU Freq Table", GpuFreqCvbTable<true>, 1, nullptr, GpuCvbDefaultMaxFreq},
|
||||||
{"GPU Freq Asm", &GpuFreqMaxAsm, 2, &GpuMaxClockPatternFn},
|
{"GPU Freq Asm", &GpuFreqMaxAsm, 2, &GpuMaxClockPatternFn},
|
||||||
{"GPU Freq PLL", &GpuFreqPllLimit, 1, nullptr, GpuClkPllLimit},
|
{"GPU Freq PLL", &GpuFreqPllLimit, 0, nullptr, GpuClkPllLimit},
|
||||||
{"MEM Freq Mtc", &MemFreqMtcTable, 0, nullptr, EmcClkOSLimit},
|
{"MEM Freq Mtc", &MemFreqMtcTable, 0, nullptr, EmcClkOSLimit},
|
||||||
{"MEM Freq Dvb", &MemFreqDvbTable, 1, nullptr, EmcClkOSLimit},
|
{"MEM Freq Dvb", &MemFreqDvbTable, 1, nullptr, EmcClkOSLimit},
|
||||||
{"MEM Freq Max", &MemFreqMax, 0, nullptr, EmcClkOSLimit},
|
{"MEM Freq Max", &MemFreqMax, 0, nullptr, EmcClkOSLimit},
|
||||||
|
|||||||
@@ -9,12 +9,21 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
#include <cstdint>
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
#include "cpp_util.hpp"
|
#include "cpp_util.hpp"
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
typedef std::uint32_t Result;
|
||||||
|
typedef std::uint32_t u32;
|
||||||
|
typedef std::int32_t s32;
|
||||||
|
typedef std::uint64_t u64;
|
||||||
|
typedef std::int64_t s64;
|
||||||
|
typedef std::uint8_t u8;
|
||||||
|
typedef std::int16_t s16;
|
||||||
|
typedef std::uint16_t u16;
|
||||||
|
|
||||||
#include "sysclk/ipc.h"
|
#include "sysclk/ipc.h"
|
||||||
#include "sysclk/board.h"
|
#include "sysclk/board.h"
|
||||||
#include "sysclk/clock_manager.h"
|
#include "sysclk/clock_manager.h"
|
||||||
|
|||||||
Reference in New Issue
Block a user