From a2535c73305fe81712afa209a7756e193563a3ed Mon Sep 17 00:00:00 2001 From: Michael Scire Date: Tue, 5 Jan 2021 00:22:38 -0800 Subject: [PATCH] sept: fix sdram parameter scratch save --- sept/sept-secondary/src/sdram.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/sept/sept-secondary/src/sdram.c b/sept/sept-secondary/src/sdram.c index 2d46efd54..a4e494e15 100644 --- a/sept/sept-secondary/src/sdram.c +++ b/sept/sept-secondary/src/sdram.c @@ -656,11 +656,11 @@ static void sdram_save_params_erista(const void *save_params) { */ /* [4.0.0+] Patch carveout parameters. */ - *(volatile uint32_t *)params->McGeneralizedCarveout1Cfg0 = 0; - *(volatile uint32_t *)params->McGeneralizedCarveout2Cfg0 = 0; - *(volatile uint32_t *)params->McGeneralizedCarveout3Cfg0 = 0; - *(volatile uint32_t *)params->McGeneralizedCarveout4Cfg0 = 0; - *(volatile uint32_t *)params->McGeneralizedCarveout5Cfg0 = 0; + *(volatile uint32_t *)¶ms->McGeneralizedCarveout1Cfg0 = 0; + *(volatile uint32_t *)¶ms->McGeneralizedCarveout2Cfg0 = 0; + *(volatile uint32_t *)¶ms->McGeneralizedCarveout3Cfg0 = 0; + *(volatile uint32_t *)¶ms->McGeneralizedCarveout4Cfg0 = 0; + *(volatile uint32_t *)¶ms->McGeneralizedCarveout5Cfg0 = 0; /* Patch SDRAM parameters. */ uint32_t t0 = params->EmcSwizzleRank0Byte0 << 5 >> 29 > params->EmcSwizzleRank0Byte0 << 1 >> 29; @@ -671,9 +671,9 @@ static void sdram_save_params_erista(const void *save_params) { uint32_t t5 = (t4 & 0xFFFFFFBF) | ((params->EmcSwizzleRank1Byte2 << 5 >> 29 > params->EmcSwizzleRank1Byte2 << 1 >> 29) << 6); uint32_t t6 = (t5 & 0xFFFFFFF7) | ((params->EmcSwizzleRank0Byte3 << 5 >> 29 > params->EmcSwizzleRank0Byte3 << 1 >> 29) << 3); uint32_t t7 = (t6 & 0xFFFFFF7F) | ((params->EmcSwizzleRank1Byte3 << 5 >> 29 > params->EmcSwizzleRank1Byte3 << 1 >> 29) << 7); - *(volatile uint32_t *)params->SwizzleRankByteEncode = t7; - *(volatile uint32_t *)params->EmcBctSpare2 = 0x40000DD8; - *(volatile uint32_t *)params->EmcBctSpare3 = t7; + *(volatile uint32_t *)¶ms->SwizzleRankByteEncode = t7; + *(volatile uint32_t *)¶ms->EmcBctSpare2 = 0x40000DD8; + *(volatile uint32_t *)¶ms->EmcBctSpare3 = t7; s(EmcClockSource, 7:0, scratch6, 15:8); s(EmcClockSourceDll, 7:0, scratch6, 23:16);