Revert "fix micron timings (again)"

This reverts commit 1d8f19d3f9.
This commit is contained in:
souldbminersmwc
2025-08-28 07:33:31 -04:00
parent 1d8f19d3f9
commit 2dea34c212
3 changed files with 45 additions and 53 deletions

View File

@@ -20,6 +20,8 @@
#define MIN(A, B) std::min(A, B)
#define CEIL(A) std::ceil(A)
#define FLOOR(A) std::floor(A)
#define nCK_erista (1000'000. / C.eristaEmcMaxClock)
#define nCK_mariko (1000'000. / C.marikoEmcMaxClock)
#include "customize.hpp"
#include "oc_common.hpp"
@@ -51,7 +53,7 @@ volatile CustomizeTable C = {
* Value should be divided evenly by 12'500.
* Not enabled by default.
*/
.commonEmcMemVolt = 1212500, // RAM Rated Voltage
.commonEmcMemVolt = 1175000, // RAM Rated Voltage
/* Erista CPU:
* - Max Voltage in mV
@@ -84,7 +86,7 @@ volatile CustomizeTable C = {
* - System instabilities
* - NAND corruption
*/
.marikoEmcMaxClock = 2400000,
.marikoEmcMaxClock = 1996800,
/* - EMC Vddq (Mariko Only) Voltage in uV
* Range: 550'000 to 650'000 uV
* Value should be divided evenly by 5'000
@@ -92,59 +94,54 @@ volatile CustomizeTable C = {
* Not enabled by default.
* This will not work without sys-clk-OC.
*/
.marikoEmcVddqVolt = 640,
.marikoEmcVddqVolt = 0,
.marikoCpuUV = 3,
.marikoCpuUV = 0,
.marikoGpuUV = 2,
.marikoGpuUV = 0,
.commonGpuVoltOffset = 0,
.marikoEmcDvbShift = 3,
.marikoEmcDvbShift = 0,
// TODO - Don't use defines for these!
.nCK_mariko = 18.0,
.nCK_erista = 18.0,
.tCK_avg_e = 1000'000. / C.eristaEmcMaxClock,
.tCK_avg_m = 1000'000. / C.marikoEmcMaxClock,
.BL = 16,
.tRFCpb = 140,
.tRFCab = 280,
.tRAS = (uint32_t)MAX(42.0, 3 * C.nCK_mariko),
.tRAS = 42,
.tRPpb = 18,
.tRPab = 21,
.tRC = C.tRAS + C.tRPab,
.tRC = 60,
.tDQSCK_min = 1.5,
.tDQSCK_max = 3.5,
.tWPRE = 2 * C.nCK_mariko,
.tRPST = 1.5 * C.nCK_mariko,
.tDQSS_max = 1.25 - ((60 - 30) / C.tCK_avg_m),
.tWPRE = 1.8,
.tRPST = 0.4,
.tDQSS_max = 1.25,
.tDQS2DQ_max = 0.8,
.tDQSQ = 0.18,
.tWTR = (uint32_t)MAX(10.0, 8 * C.nCK_mariko),
.tRTP = C.nCK_mariko * C.tCK_avg_m, // Cannot find concrete value for this timing
.tWR = (uint32_t)MAX(10.0, 4 * C.nCK_mariko),
.tR2REF = 8, // Try 16, 8 or 9 × 2 × 8 or 16
.tWTR = (uint32_t)MAX(10.0, 8 * nCK_mariko),
.tRTP = 7.5, // Cannot find concrete value for this timing
.tWR = (uint32_t)MAX(10.0, 4 * nCK_mariko),
.tR2REF = 25.5,
.tRCD = 20, // Cannot find concrete value for this timing
.tRRD = 10, // Cannot find concrete value for this timing
.tREFpb = 488,
.tXP = MAX(7.5, 5 * C.nCK_mariko),
.tCMDCKE = MAX(1.75, 3 * C.nCK_mariko),
.tMRWCKEL = (uint32_t)MAX(14.0, 10 * C.nCK_mariko),
.tCKELCS = MAX(5.0, 5 * C.nCK_mariko),
.tXP = MAX(7.5, 5 * nCK_mariko),
.tCMDCKE = MAX(1.75, 3 * nCK_mariko),
.tMRWCKEL = (uint32_t)MAX(14.0, 10 * nCK_mariko),
.tCKELCS = MAX(5.0, 5 * nCK_mariko),
.tCSCKEH = 1.75,
.tXSR = MAX(C.tRFCpb + 7.5, 5 * C.nCK_mariko),
.tCKE = MAX(7.5, 4 * C.nCK_mariko),
.tXSR = MAX(C.tRFCpb + 7.5, 5 * nCK_mariko),
.tCKE = MAX(7.5, 4 * nCK_mariko),
.tSR = (uint32_t)MAX(15.0, 3 * C.nCK_mariko),
.tFAW = (uint32_t)(4 * C.tCK_avg_m),
.tSR = (uint32_t)MAX(15.0, 3 * nCK_mariko),
.tFAW = 30,
.tCKCKEH = MAX(1.75, 3 * C.nCK_mariko),
.tCKCKEH = MAX(1.75, 3 * nCK_mariko),
.WL = 14,
.RL = 32,

View File

@@ -60,12 +60,6 @@ typedef struct CustomizeTable {
// advanced config
u32 marikoEmcDvbShift;
//
const double nCK_mariko;
const double nCK_erista;
const double tCK_avg_e;
const double tCK_avg_m;
const uint32_t BL;
const uint32_t tRFCpb;
const uint32_t tRFCab;
@@ -105,6 +99,7 @@ typedef struct CustomizeTable {
const uint32_t tFAW;
const double tCKCKEH;
const double tCK_avg;
const uint32_t WL;
const uint32_t RL;

View File

@@ -2,40 +2,40 @@ OCS2-MICRON-WTB-PRESET
.BL = 16,
.tRFCpb = 140,
.tRFCab = 280,
.tRAS = (uint32_t)MAX(42.0, 3 * C.nCK_mariko),
.tRAS = 42,
.tRPpb = 18,
.tRPab = 21,
.tRC = C.tRAS + C.tRPab,
.tRC = 60,
.tDQSCK_min = 1.5,
.tDQSCK_max = 3.5,
.tWPRE = 2 * C.nCK_mariko,
.tRPST = 1.5 * C.nCK_mariko,
.tDQSS_max = 1.25 - ((60 - 30) / C.tCK_avg_m),
.tWPRE = 1.8,
.tRPST = 0.4,
.tDQSS_max = 1.25,
.tDQS2DQ_max = 0.8,
.tDQSQ = 0.18,
.tWTR = (uint32_t)MAX(10.0, 8 * C.nCK_mariko),
.tRTP = C.nCK_mariko * C.tCK_avg_m, // Cannot find concrete value for this timing
.tWR = (uint32_t)MAX(10.0, 4 * C.nCK_mariko),
.tR2REF = 8, // Try 16, 8 or 9 × 2 × 8 or 16
.tWTR = MAX(10, 8 * nCK_mariko),
.tRTP = 7.5, // Cannot find concrete value for this timing
.tWR = MAX(10, 4 * nCK_mariko),
.tR2REF = 25.5,
.tRCD = 20, // Cannot find concrete value for this timing
.tRRD = 10, // Cannot find concrete value for this timing
.tREFpb = 488,
.tXP = MAX(7.5, 5 * C.nCK_mariko),
.tCMDCKE = MAX(1.75, 3 * C.nCK_mariko),
.tMRWCKEL = (uint32_t)MAX(14.0, 10 * C.nCK_mariko),
.tCKELCS = MAX(5.0, 5 * C.nCK_mariko),
.tXP = MAX(7.5, 5 * nCK_mariko),
.tCMDCKE = MAX(1.75, 3 * nCK_mariko),
.tMRWCKEL = MAX(14, 10 * nCK_mariko),
.tCKELCS = MAX(5, 5 * nCK_mariko),
.tCSCKEH = 1.75,
.tXSR = MAX(C.tRFCpb + 7.5, 5 * C.nCK_mariko),
.tCKE = MAX(7.5, 4 * C.nCK_mariko),
.tXSR = MAX(C.tRFcpb + 7.5, 5 * nCK_mariko),
.tCKE = MAX(7.5, 4 * nCK_mariko),
.tSR = (uint32_t)MAX(15.0, 3 * C.nCK_mariko),
.tFAW = (uint32_t)(4 * C.tCK_avg_m),
.tSR = MAX(15, 3 * nCK_mariko),
.tFAW = 30,
.tCKCKEH = MAX(1.75, 3 * C.nCK_mariko),
.tCKCKEH = MAX(1.75, 3 * nCK_mariko),
.WL = 14,
.RL = 32,