This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[参考译文] AM5749:ECC 不再工作

Guru**** 2463330 points
Other Parts Discussed in Thread: AM5749

请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/processors-group/processors/f/processors-forum/1552198/am5749-ecc-not-working-anymore

器件型号:AM5749


工具/软件:

您好、

我们有一个基于 AM5749 SoC 的定制电路板和一个基于 AM57XX-EVM 板的定制 U-Boot。

使用 SDK 6.x 和 U-Boot v2019 时、存储器 ECC 可以正常工作。

最近、我们迁移到了 SDK 8.X、并将所有 U-Boot 更改移植到 v2021。

我们的电路板卡在 arch/arm/mach-OMAP2/emif-common.c 中的 dra7_enable_ecc () 函数中

如果我们在 EMIF 配置中禁用 ECC、则电路板再次引导、但 ECC 显然无法正常工作。

这是我们的 EMIF 配置:

/*
 * MT41K512M16VRN-107 (with ECC enabled) memory timings
 * This is a twin die of MT41K512M8 (also used for the ECC), so see that
 * datasheet for most timings.
 */
const struct emif_regs am57xx_emif_532mhz_512m16_ecc_regs = {
	.sdram_config_init		= 0x61851bb2,
	.sdram_config			= 0x61851bb2,
	.sdram_config2			= 0x08000000,
	.ref_ctrl			= 0x000040f1,
	.ref_ctrl_final			= 0x00001035,
	.sdram_tim1			= 0xeeef265b,
	.sdram_tim2			= 0x308f7fda,
	.sdram_tim3			= 0x409f88a8,
	.read_idle_ctrl			= 0x00090000,
	.zq_config			= 0x5007190b,
	.temp_alert_config		= 0x00000000,
	.emif_ddr_phy_ctlr_1_init	= 0x0024400b,
	.emif_ddr_phy_ctlr_1		= 0x0e24400b,
	.emif_ddr_ext_phy_ctrl_1	= 0x10040100,
	.emif_ddr_ext_phy_ctrl_2	= 0x00910091,
	.emif_ddr_ext_phy_ctrl_3	= 0x00950095,
	.emif_ddr_ext_phy_ctrl_4	= 0x009b009b,
	.emif_ddr_ext_phy_ctrl_5	= 0x009e009e,
	.emif_rd_wr_lvl_rmp_win		= 0x00000000,
	.emif_rd_wr_lvl_rmp_ctl		= 0x80000000,
	.emif_rd_wr_lvl_ctl		= 0x00000000,
	.emif_rd_wr_exec_thresh		= 0x00000305,
	.emif_ecc_ctrl_reg		= 0xD0000001,
    // This needs to be not quite 2G due to LISA3 carve out
   .emif_ecc_address_range_1       = 0x7EFF0000,
   .emif_ecc_address_range_2       = 0x00000000,
};

和 DMM 配置:

const struct dmm_lisa_map_regs am574x_2gx1_ecc_lisa_regs = {
	.dmm_lisa_map_3 = 0xFF020100,
	.dmm_lisa_map_2 = 0x80700100,
	.is_ma_present  = 0x1
};

我们将使用以下命令禁用 ECC:

-       .emif_rd_wr_exec_thresh         = 0x00000305,
-       .emif_ecc_ctrl_reg              = 0xd0000001,
-       // This needs to be not quite 2G due to LISA3 carve out
-       .emif_ecc_address_range_1       = 0x7EFF0000,
-       .emif_ecc_address_range_2       = 0x00000000,
+       .emif_rd_wr_exec_thresh         = 0x00000305
 };

是否知道 SDK 8.x 中有关 ECC 的问题可能出在哪里?

我们根本没有更改 DRAM 配置。

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    在 arch/arm/mach-OMAP2/emif-common.c 中找到原因:

    static void dra7_reset_ddr_data(u32 base, u32 size)
    {
    #if defined(CONFIG_TI_EDMA3) && !defined(CONFIG_DMA)
    	enable_edma3_clocks();
    
    	edma3_fill(EDMA3_BASE, 1, (void *)base, 0, size);
    
    	disable_edma3_clocks();
    #else
    	memset((void *)base, 0, size);
    #endif
    }

     缺少 CONFIG_TI_EDMA3 时、dra7_reset_DDR_DATA () 不起作用。

    在 TI am57xx-EVM 和其他版本上、CONFIG_TI_EDMA3 使用 CONFIG_TI_QSPI=y 隐式启用

    但是、在我们的电路板上缺少 CONFIG_TI_QSPI;因此缺少 CONFIG_TI_EDMA3。

    最后但同样重要的是,如果 dra7_reset_ddr_data() 不能使用 memset () 对 CPU 归零内存起作用,并且无论如何都需要 EDMA3 方法,则该方法应该在 emif-common.c 中修复!

    不应该有有条件使用 EDMA3 的选项、而应该是一项授权?

    感谢您的意见。

    BR、
    Primoz

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好 Primoz、

    如果我理解正确、在启用 CONFIG_TI_QSPI=y 时、您的问题会得到解决? 或 用于 EDMA3 的单模块?

    您的 SDK 6.3 映像的制作方式也是这样吗?

    不应该有有条件使用 EDMA3 的选项、而应该是一项授权?

    我认为这取决于单个项目及其要求、对于我们的图像、它仅用于演示目的、每个客户都应根据其项目需求自定义其内核。

    请参阅 https://software-dl.ti.com/processor-sdk-linux/esd/AM57X/09_03_06_05/exports/docs/linux/processor-sdk-technology-support。Overview_Technical_Support

    -Josue

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    你好 Josue Zamitiz-Ayala ,

    我只是想知道、 如果没有 dra7_reset_DDR_DATA () 无法正常工作、选择 DRA7XX 时对 CONFIG_TI_EDMA3=y 进行严格依赖是否有意义?

    diff --git a/arch/arm/mach-omap2/omap5/Kconfig b/arch/arm/mach-omap2/omap5/Kconfig
    index 5394529658bc..14dd8000fadc 100644
    --- a/arch/arm/mach-omap2/omap5/Kconfig
    +++ b/arch/arm/mach-omap2/omap5/Kconfig
    @@ -7,6 +7,7 @@ config DRA7XX
            bool
            select IODELAY_RECALIBRATION
            select SYS_OMAP_ABE_SYSCK
    +       select TI_EDMA3
            help
              DRA7xx is an OMAP based SOC with Dual Core A-15s.

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    Primoz、

    无需考虑这一点当这是设计另一部分的先决条件时、大多数 DRA7x 器件 旨在用于汽车市场、该市场 对 QSPI 提出 了严格要求、AM57xx SW 继承了这一点。  

    我很高兴您能使其正常工作! 我假设您找到了您的解决方案并关闭此主题。

    此致、

     Josue