Hello, to everyone,
I'am using TMS3206670 DSP and want to make a DDR3 Ethernet boot. Before that our application was spread through L2SRAM and MSMCSRAM and booted through Ethernet. So I have no problem with generating the boot table, processing the BOOTP and other stuff. But now I need to swich the application location to DDR3 since it getting to big for holding in mentioned memory regions.
I have done some forum browsing and find out that I need to initialize the DDR3 at the first booting step for that I add to the .cmd file
MEMORY
{
DDR_CFG : origin = 0x00873500 , length = 0x180
L2MAGIC : origin = 0x8ffffc, length = 0x4
}
SECTIONS
{
.emif4Cfg > DDR_CFG
.stack > DDR3
.msmc > DDR3
.data > DDR3
.far > DDR3
.text > DDR3
.const > DDR3
.cinit > DDR3
.lmagic > L2MAGIC
}
And created a section in the main.c file (added a tiboot_c66x.h file with correct BOOT_EMIF4_TBL_T structure for C6670)
#pragma DATA_SECTION (emif4Cfg, ".emif4Cfg")
const BOOT_EMIF4_TBL_T emif4Cfg = {
BOOT_EMIF4_ENABLE_pllCtl | \
BOOT_EMIF4_ENABLE_sdRamTiming1 | \
BOOT_EMIF4_ENABLE_sdRamTiming2 | \
BOOT_EMIF4_ENABLE_sdRamTiming3 | \
BOOT_EMIF4_ENABLE_ddrPhyCtl1 | \
BOOT_EMIF4_ENABLE_sdRamRefreshCtl | \
BOOT_EMIF4_ENABLE_sdRamOutImpdedCalCfg | \
BOOT_EMIF4_ENABLE_sdRamConfig,
3, /* pllPrediv */
40, /* pllMult */
2, /* pllPostDiv */
0x62477AB2, /* sdRamConfig */
0, /* sdRamConfig2, dont care*/
0x0000144F, /* sdRamRefreshCtl */
0x1333780C, /* sdRamTiming1 */
0x30717FE3, /* sdRamTiming2 */
0x559F86AF, /* sdRamTiming3 */
0, /* lpDdrNvmTiming, dont care */
0, /* powerManageCtl, dont care */
0, /* iODFTTestLogic, dont care */
0, /* performCountCfg, dont care */
0, /* performCountMstRegSel, dont care */
0, /* readIdleCtl, dont care */
0, /* sysVbusmIntEnSet, dont care */
0x70074c1f, /* sdRamOutImpdedCalCfg, dont care */
0, /* tempAlterCfg, dont care */
0x0010010F, /* ddrPhyCtl1 */
0, /* ddrPhyCtl2, dont care */
0, /* priClassSvceMap, dont care */
0, /* mstId2ClsSvce1Map, dont care */
0, /* mstId2ClsSvce2Map, dont care */
0, /* eccCtl, dont care */
0, /* eccRange1, dont care */
0, /* eccRange2, dont care */
0, /* rdWrtExcThresh, dont care */
};
The DDR3 section is specified in the Platform.xdc file as
externalMemoryMap:
[
["DDR3",
{
name: "DDR3",
base: 0x80000000,
len: 0x20000000,
space: "code/data",
access: "RWX",
}
],
],
l2Mode: "64k",
l1PMode: "32k",
l1DMode: "32k",
This is where I get confused at the first time . When I try to build the project I get an error #10264 L2SRAM memory range overlaps linker.cmd. So I have checked in the linker.cmd file and find out where it overlaps:
L2SRAM (RWX) : org = 0x800000, len = 0xf0000
So the DDR_CFG address is in the L2SRAM region. But when I placed the DR_CFG address like in the C6657 0x8ffd20 the project build just fine. What causing this problem? Since DDR3 and L2SRAM was defined by the platform wizard and I specify the correct DDR_CFG address from the data manual it should work correctly. Or the platform wizard have occupied the space in the L2SRAM supposed to be for DDR_CFG?
UPD: I have find out that L2SRAM size is established by the platform wizard by default like that. So what is the best solution for that? I'am thinking to create a custom platform file and just reduce the L2SRAM length. Or there are some other ways?
Best Regards,
Pavlo!

