mirror of
https://xff.cz/git/u-boot/
synced 2025-10-22 10:31:56 +02:00
driver/ddr/fsl: Check condition for erratum A-009803
Add condition of checking the enabled of address parity for erratum A-009803, if parity is not enabled, the workaround of erratum A-009803 should not be applied. Signed-off-by: Shengzhou Liu <Shengzhou.Liu@nxp.com> Reviewed-by: York Sun <york.sun@nxp.com>
This commit is contained in:
@@ -206,12 +206,14 @@ void fsl_ddr_set_memctl_regs(const fsl_ddr_cfg_regs_t *regs,
|
||||
|
||||
#ifdef CONFIG_SYS_FSL_ERRATUM_A009803
|
||||
/* part 1 of 2 */
|
||||
if (regs->ddr_sdram_cfg_2 & SDRAM_CFG2_AP_EN) {
|
||||
if (regs->ddr_sdram_cfg & SDRAM_CFG_RD_EN) { /* for RDIMM */
|
||||
ddr_out32(&ddr->ddr_sdram_rcw_2,
|
||||
regs->ddr_sdram_rcw_2 & ~0x0f000000);
|
||||
}
|
||||
|
||||
ddr_out32(&ddr->err_disable, regs->err_disable | DDR_ERR_DISABLE_APED);
|
||||
ddr_out32(&ddr->err_disable, regs->err_disable |
|
||||
DDR_ERR_DISABLE_APED);
|
||||
}
|
||||
#else
|
||||
ddr_out32(&ddr->err_disable, regs->err_disable);
|
||||
#endif
|
||||
@@ -395,6 +397,7 @@ step2:
|
||||
#endif /* CONFIG_SYS_FSL_ERRATUM_A008511 */
|
||||
|
||||
#ifdef CONFIG_SYS_FSL_ERRATUM_A009803
|
||||
if (regs->ddr_sdram_cfg_2 & SDRAM_CFG2_AP_EN) {
|
||||
/* if it's RDIMM */
|
||||
if (regs->ddr_sdram_cfg & SDRAM_CFG_RD_EN) {
|
||||
for (i = 0; i < CONFIG_CHIP_SELECTS_PER_CTRL; i++) {
|
||||
@@ -411,6 +414,7 @@ step2:
|
||||
|
||||
ddr_out32(&ddr->err_disable,
|
||||
regs->err_disable & ~DDR_ERR_DISABLE_APED);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user