Tried at 1300 MT/s, these are the changes applied:
1. RCW[0] = 0x0C0D000E
2. Bypassed DQ mapping by adding this lines in drivers/ddr/fsl/fsl_ddr_gen4.c
/*
* implement nxp suggested changes
* to bypass DQ mapping
* before enabling mem
*/
// clear all DQn_MAP
ddr_out32(&ddr->dq_map_0, 0);
ddr_out32(&ddr->dq_map_1, 0);
ddr_out32(&ddr->dq_map_2, 0);
ddr_out32(&ddr->dq_map_3, 0);
// DDR_SDRAM_CFG_2[DDR_SLOW] = 1
ddr_out32(&ddr->sdram_cfg_2, regs->ddr_sdram_cfg_2 | 0x00000800);
// DEBUG_2[27] = 1, (i.e. 0x1080F04 = 0x10)
// shouldn't it be 0xFE008F04?
u32 temp32 = ddr_in32(&ddr->debug[1]);
ddr_out32(&ddr->debug[1], temp32 | 0x10);
// add some delay in case
udelay(500);
// end nxp changes
/* Let the controller go */
ddr_out32(&ddr->sdram_cfg, temp_sdram_cfg | SDRAM_CFG_MEM_EN);
mb();
isb();
I had doubt with your suggestion no: 4) Set the DEBUG_2[27] = 1, (i.e. 0x1080F04 = 0x10). Is this address correct? I tried as shown in above code snippet.
Anyway after making these changes we are getting same problem. (see cngs_ubootLog.txt, #debug was enabled in few source files)
Also I observed that the reg: DDR_ERR_SBE[SBEC] continuously keeps on changing from 0 to ff (see attached screen grab)