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.

AM620-Q1: drivers/qspi.h not found in MCU +Sdk

Part Number: AM620-Q1
Other Parts Discussed in Thread: SYSCONFIG

Tool/software:

Hi,

       We are trying to use SBL boot from MCU SDK to boot M4F application early. We have a qspi based Winbond Norflash. I found that there is no direct support in syscfg to change it from OSPI to QSPI. I tried to change it by changing in soc cfg to pick serial nor flash v1. But, I got a compile error that qspi.h is not found. 

Is SBL flash with qspi support available in the sdk? If not, please direct me to correct source.

I am using MCU +SDK VERSION 10.00

  • Moreover, you would not need to worry about the qspi.h file.

    The files under source/drivers/ospi/v0/.... and source/board/flash/ospi/... should be enough to cater to a flash part which is either SPI, QSPI or OSPI NOR/NAND.

  • Thanks. I saw the thread for getting the NOR flash config by running ospi flash diag. Our board has jtag interface and we are using lauterbach trace 32. Could the out file  generated be run from trace 32 software?

  • Hi,

    Currently for AM62x, programming through JTAG is not supported.

    Regards,

    Vaibhav

  • Hello Vaibhav,

            How do I know which mode to use either phy or Tap? I saw that in the sysconfig flash_spansionquirk function is added. Is that still required? I am using winbond w25q128jv. Do you have any sysfs flash configuration example for this part?

  • Hi Shibi,

    flash_spansionquirk

    Not required as that function addresses those flash parts which have a hybrid vs Uniform mode. If your flash does not have these modes, then you can remove this quirk function else I can help you setup the quirk function in case these modes exist for your flash part.

    To understand hybrid vs Uniform mode please refer my FAQ here: https://e2e.ti.com/support/processors-group/processors/f/processors-forum/1492859/faq-am62x-am62px-am62d-q1-am64x-am243x-4kb-sector-erase-fails/5734123#5734123

    Apart from this,

    How do I know which mode to use either phy or Tap?

    I would encourage you to read through: https://www.ti.com/lit/ds/symlink/am623.pdf#page=202

    Let me know after reading if you have the same doubt or you need more clarification. I will help you on this.

    Do you have any sysfs flash configuration example for this part

    I currently do not have the SysConfig Flash Configuration for this flash. But I have the configurations for W25Q256JV. Please check with the flash vendor on how much similar W25Q256JV is with the one you are using w25q128jv. If they are similar on configuration terms, I can share the configurations for the W25Q256JV flash.

    NOTE: I have the 1S-1S-4S protocol settings for the W25Q256JV flash.

    Looking forward to your response.

    Regards,

    Vaibhav

  • That would help. Please share the configuration you have.

  • Sure, here you go:

    /**
     * Write custom configuration values to the imported modules.
     */
     flash1.$name                           = "CONFIG_FLASH0";
     flash1.device                          = "CUSTOM_FLASH";
     flash1.skipHwInit                      = true;
     flash1.fname                           = "W25Q256";
     flash1.protocol                        = "1s_1s_4s";
     flash1.flashSize                       = 33554432;
     flash1.flashManfId                     = "0xEF";
     flash1.flashBlockSize                  = 65536;
     flash1.cmdBlockErase3B                 = "0xD8";
     flash1.cmdBlockErase4B                 = "0xD8";
     flash1.cmdSectorErase3B                = "0x20";
     flash1.cmdSectorErase4B                = "0x20";
     flash1.cmdRd                           = "0x6C";
     flash1.cmdWr                           = "0x32";
     flash1.dummyClksCmd                    = 0;
     flash1.dummyClksRd                     = 8;
     flash1.flashQeType                     = "4";
     flash1.proto_isAddrReg                 = false;
     flash1.dummy_isAddrReg                 = false;
     flash1.strDtr_isAddrReg                = false;
     flash1.resetType                       = "0x30";
     flash1.cmdExtType                      = "NONE";
     flash1.xspiWipRdCmd                    = "0x00";
     flash1.xspiWipReg                      = "0x00000000";
     flash1.idNumBytes                      = 5;
     flash1.dummyId8                        = 0;
     flash1.fourByteEnableSeq               = "0xA5";
     flash1.flashDeviceBusyTimeout          = 80000000;
     flash1.flashPageProgTimeout            = 704;
     flash1.flashDeviceId                   = "0x7019";
     flash1.peripheralDriver.$name          = "CONFIG_OSPI0";
     flash1.peripheralDriver.inputClkFreq   = 200000000;
     flash1.peripheralDriver.dmaEnable      = true;
     flash1.peripheralDriver.baudRateDiv    = 4;
     flash1.peripheralDriver.OSPI.CLK.rx    = true;
     flash1.peripheralDriver.OSPI.DQS.$used = false;
     flash1.peripheralDriver.OSPI.D7.rx     = false;
     flash1.peripheralDriver.OSPI.D7.$used  = false;
     flash1.peripheralDriver.OSPI.D6.rx     = false;
     flash1.peripheralDriver.OSPI.D6.$used  = false;
     flash1.peripheralDriver.OSPI.D5.rx     = false;
     flash1.peripheralDriver.OSPI.D5.$used  = false;
     flash1.peripheralDriver.OSPI.D4.rx     = false;
     flash1.peripheralDriver.OSPI.D4.$used  = false;

    The rest of the other values will be default and the changes would be to the above parameters.

    Thanks,

    Vaibhav

  • The SBL ospi_linux_multistage1 is reading wrong jedec id from NOR flash. 
    ERROR: Flash_norOspiReadId:859: man id 43 devid 1CFD where it should be 0xEF and 0x7018. 
    I have attached below the configuration I used.
    /*
     * FLASH
     */
    /* FLASH Object - initialized during Flash_open() */
    Flash_NorOspiObject gFlashObject_W25Q128JVFAM =
    {
        .rdDummyValPhyMode = FLASH_NOR_UPDATE_RD_DUMMY_VALUE,
    };

    /* FLASH Attrs */
    Flash_Attrs gFlashAttrs_W25Q128JVFAM =
    {
        .flashType = CONFIG_FLASH_TYPE_SERIAL,
        .flashName = "W25Q128JVFAM",
        .deviceId = 0x7018,
        .manufacturerId = 0xEF,
        .flashSize = 16777216,
        .blockCount = 256,
        .blockSize = 65536,
        .pageCount = 256,
        .pageSize = 256,
        .sectorCount = 4096,
        .sectorSize = 4096,
    };

    /* FLASH DevConfig */
    Flash_DevConfig gFlashDevCfg_W25Q128JVFAM =
    {
        .cmdExtType = OSPI_CMD_EXT_TYPE_REPEAT,
        .enable4BAddr = TRUE,
        .addrByteSupport = 1,
        .fourByteAddrEnSeq = 0xA0,
        .cmdWren = 0x06,
        .cmdRdsr = 0x05,
        .cmdWrsr = 0x00,
        .srWip = (1 << 0),
        .srWel = (1 << 1),
        .xspiWipRdCmd = 0x05,
        .xspiWipReg = 0x00800000,
        .xspiWipBit = (1 << 0),
        .resetType = 0x10,
        .eraseCfg = {
            .blockSize = 65536,
            .sectorSize = 4096,
            .cmdBlockErase3B = 0xD8,
            .cmdBlockErase4B = 0xD8,
            .cmdSectorErase3B = 0x20,
            .cmdSectorErase4B = 0x20,
            .cmdChipErase = 0xC7,
        },
        .idCfg = {
            .cmd = 0x9F, /* Constant */
            .numBytes = 3,
            .dummy4 = 0,
            .dummy8 = 0,
        },
        .protocolCfg = {
            .protocol = FLASH_CFG_PROTO_1S_1S_4S,
            .isDtr = FALSE,
            .cmdRd = 0x6B,
            .cmdWr = 0x32,
            .modeClksCmd = 0,
            .modeClksRd = 0,
            .dummyClksCmd = 0,
            .dummyClksRd = 8,
            .enableType = 5,
            .enableSeq = 0xFF,
            .dummyCfg = {
                .isAddrReg = FALSE,
                .cmdRegRd = 0x00,
                .cmdRegWr = 0x00,
                .cfgReg = 0x00,
                .shift = 0,
                .mask = 0x00,
                .cfgRegBitP = 0,
            },
        },
        .flashWriteTimeout = 512,
        .flashBusyTimeout = 256000000,
    };
  • Before Drivers open
    ERROR: Flash_norOspiSetAddressBytes:317: Setting address byte to 1 enable 4 byte 1
    ERROR: Flash_norOspiCmdRead:129: cmd 1136811122 cmdaddr 159 databuf ▒pCt datalen 3
    ERROR: Flash_norOspiReadId:854: man id EF devid 7018

    After making the changes I could read the dev id and manufacturing id. But the X509 header of MCU app image is not read properly. I have a hs-fs device and flashed the ipc_rpmsg example hs_fs.tiimage to 0x100000 offset and sbl2 to 0x80000 offset as given in SBL booting guide.


    ERROR: Flash_norOspiRead:881: inside Flash nor ospi read
    ERROR: Flash_norOspiRead:901: Data buffer 0xF3 0x7F 0xC1 0x43 length 4
    ERROR: OSPI_readDirect:1214: DMA copy 0, phy enable 0
    ERROR: Flash_norOspiRead:903: Data buffer 0xE9 0x2C 0x37 0x11 length 4
    ERROR: Flash_imgSeek:91: Inside Flash img seek

    It should be 30 82 06 53 as I checked the data written to the memory


  • Drivers open done
    ERROR: Flash_imgOpen:56: Inside Flash img open
    ERROR: Bootloader_open:93: Bootloader open Flash open status 0
    ERROR: Flash_imgOpen:56: Inside Flash img open
    ERROR: Bootloader_open:93: Bootloader open Flash open status 0
    ERROR: Bootloader_parseMultiCoreAppImage:709: inside Parse multicore app image. Boot Media: 29!
    ERROR: Bootloader_verifyMulticoreImage:562: inside verify core imageBoot Media: -1341718526!!
    ERROR: Flash_imgRead:67: Inside Flash img Read
    ERROR: Flash_read:185: Inside Flash read 1048576
    ERROR: Flash_norOspiRead:881: inside Flash nor ospi read
    ERROR: Flash_norOspiRead:901: offset 1048576 Data buffer 0x00 0x00 0x00 0x00 length 4
    ERROR: OSPI_readDirect:1214: DMA copy 0, phy enable 0 src 0x60100000 dest 0x43C2CFD4
    ERROR: Flash_norOspiRead:903: Data buffer 0xE9 0x2C 0x37 0x11 length 4
    ERROR: Flash_imgSeek:91: Inside Flash img seek
    ERROR: Bootloader_verifyMulticoreImage:590: x509header ▒,7`▒▒C▒▒C
    ERROR: Flash_imgPhyToggle:106: Inside Flash img phy toggle

    Now I have narrowed down. The x509 header is read using OSPI read direct using memory mapped to spi nor. But I suspect that it is not happening. Am I missing any setting.

  • Hi Shibi,

    Thanks for the detailed logs, I like the way you have described the issue in bits and pieces.

    After making the changes I could read the dev id and manufacturing id.

    Please tell me what changes you have done so that you were seeing the manufacture and device id being read correctly.

    Is it flash configuration change or driver level change.

    Now I have narrowed down. The x509 header is read using OSPI read direct using memory mapped to spi nor. But I suspect that it is not happening. Am I missing any setting.

    Let us start by checking the MPU ARMv7 configurations. This section is present under SYSCONFIG of the application. Can you check if the region 0x60000000 is defined in the application, if yes, can you share a screenshot of the setting.

    Looking forward to your response.

    Regards,

    Vaibhav

  • I am using mcu_plus_sdk_am62x_10_00_00_14/ and /sbl_ospi_linux_multistage/sbl_ospi_linux_stage1/ example. Attached below are the changes done to the example.syscfg. The dev id and manufacturer id could be read after increasing the divider to 8 from 4.

    0x600000000 has be configured in the syscfg.
    mpu_armv710.$name = "CONFIG_MPU_REGION9";
    mpu_armv710.allowExecute = false;
    mpu_armv710.size = 9;
    mpu_armv710.attributes = "Device";
    mpu_armv710.baseAddr = 0x2800000;

    mpu_armv711.$name = "FSS0_DAT_REG1";
    mpu_armv711.baseAddr = 0x60000000;
    mpu_armv711.size = 27;
    mpu_armv711.attributes = "Device";
    mpu_armv711.allowExecute = false;

    --- a/examples/drivers/boot/sbl_ospi_linux_multistage/sbl_ospi_linux_stage1/am62x-sk/r5fss0-0_nortos/example.syscfg
    +++ b/examples/drivers/boot/sbl_ospi_linux_multistage/sbl_ospi_linux_stage1/am62x-sk/r5fss0-0_nortos/example.syscfg
    @@ -2,7 +2,7 @@
    * These arguments were used when this file was generated. They will be automatically applied on subsequent loads
    * via the GUI or CLI. Run CLI with '--help' for additional information on how to override these arguments.
    * @cliArgs --device "AM62x" --package "ALW" --part "Default" --context "r5fss0-0" --product "MCU_PLUS_SDK_AM62x@10.00.00"
    - * @versions {"tool":"1.19.0+3426"}
    + * @versions {"tool":"1.20.0+3587"}
    */

    /**
    @@ -16,10 +16,10 @@ const bootloader2 = bootloader.addInstance();
    const ddr = scripting.addModule("/drivers/ddr/ddr", {}, false);
    const ddr1 = ddr.addInstance();
    const gtc = scripting.addModule("/drivers/gtc/gtc");
    -const qos = scripting.addModule("/drivers/qos/qos", {}, false);
    -const qos1 = qos.addInstance();
    const mcu_bist = scripting.addModule("/drivers/mcu_bist/mcu_bist", {}, false);
    const mcu_bist1 = mcu_bist.addInstance();
    +const qos = scripting.addModule("/drivers/qos/qos", {}, false);
    +const qos1 = qos.addInstance();
    const clock = scripting.addModule("/kernel/dpl/clock");
    const debug_log = scripting.addModule("/kernel/dpl/debug_log");
    const mpu_armv7 = scripting.addModule("/kernel/dpl/mpu_armv7", {}, false);
    @@ -51,15 +51,49 @@ flash1.$name = "CONFIG_FLASH0";
    bootloader1.flashDriver = flash1;
    bootloader2.flashDriver = flash1;
    flash1.serialFlashDriver.$name = "board_flash_serialFlash_serialflash0";
    +flash1.serialFlashDriver.flashSize = 16777216;
    +flash1.serialFlashDriver.flashManfId = "0xEF";
    +flash1.serialFlashDriver.dummy_isAddrReg = false;
    +flash1.serialFlashDriver.dummy_cfgReg = "0x00";
    +flash1.serialFlashDriver.dummy_cmdRegRd = "0x00";
    +flash1.serialFlashDriver.dummy_cmdRegWr = "0x00";
    +flash1.serialFlashDriver.dummy_mask = "0x00";
    +flash1.serialFlashDriver.dummy_bitP = 0;
    +flash1.serialFlashDriver.proto_isAddrReg = false;
    +flash1.serialFlashDriver.proto_cfgReg = "0x00";
    +flash1.serialFlashDriver.proto_cmdRegRd = "0x00";
    +flash1.serialFlashDriver.proto_cmdRegWr = "0x00";
    +flash1.serialFlashDriver.proto_mask = "0x00";
    +flash1.serialFlashDriver.proto_bitP = 0;
    +flash1.serialFlashDriver.fname = "W25Q128JVFAM";
    +flash1.serialFlashDriver.flashDeviceId = "0x7018";
    +flash1.serialFlashDriver.xspiWipRdCmd = "0x05";
    +flash1.serialFlashDriver.quirks = "";
    +flash1.serialFlashDriver.cmdBlockErase3B = "0xD8";
    +flash1.serialFlashDriver.cmdBlockErase4B = "0xD8";
    +flash1.serialFlashDriver.cmdSectorErase3B = "0x20";
    +flash1.serialFlashDriver.cmdSectorErase4B = "0x20";
    +flash1.serialFlashDriver.flashBlockSize = 65536;
    +flash1.serialFlashDriver.protocol = "1s_1s_4s";
    +flash1.serialFlashDriver.cmdRd = "0x6B";
    +flash1.serialFlashDriver.cmdWr = "0x32";
    +flash1.serialFlashDriver.dummyClksRd = 8;
    flash1.serialFlashDriver.peripheralDriver.$name = "CONFIG_OSPI0";
    flash1.serialFlashDriver.peripheralDriver.dmaEnable = true;
    -flash1.serialFlashDriver.peripheralDriver.phyEnable = true;
    -flash1.serialFlashDriver.peripheralDriver.fastBootTuning = "true";
    +flash1.serialFlashDriver.peripheralDriver.baudRateDiv = 8;
    +flash1.serialFlashDriver.peripheralDriver.OSPI.DQS.$used = false;
    +flash1.serialFlashDriver.peripheralDriver.OSPI.D7.$used = false;
    +flash1.serialFlashDriver.peripheralDriver.OSPI.D6.$used = false;
    +flash1.serialFlashDriver.peripheralDriver.OSPI.D5.$used = false;
    +flash1.serialFlashDriver.peripheralDriver.OSPI.D4.$used = false;

    -ddr1.$name = "CONFIG_DDR0";
    +ddr1.$name = "CONFIG_DDR0";
    +ddr1.ddrConfigIncludeFileName = "drivers/ddr/v0/soc/am62x/board_lpddrReginit.h";

    mcu_bist1.$name = "CONFIG_MCU_BIST0";

    +qos1.$name = "CONFIG_QOS0";
    +
    const udma = scripting.addModule("/drivers/udma/udma", {}, false);
    const udma1 = udma.addInstance({}, false);
    udma1.$name = "CONFIG_UDMA0";
    @@ -72,8 +106,6 @@ udma_blkcopy_channel1.$name = "CONFIG_UDMA_BLKC
    bootloader1.udmaBlkCopyChannel = udma_blkcopy_channel1;
    flash1.serialFlashDriver.peripheralDriver.udmaBlkCopyChannel = udma_blkcopy_channel1;

    -qos1.$name = "CONFIG_QOS0";
    -
    clock.instance = "TIMER1";

    debug_log.enableUartLog = true;
    @@ -152,11 +184,6 @@ mpu_armv711.allowExecute = false;
    flash1.serialFlashDriver.peripheralDriver.OSPI.$suggestSolution = "OSPI0";
    flash1.serialFlashDriver.peripheralDriver.OSPI.CLK.$suggestSolution = "OSPI0_CLK";
    flash1.serialFlashDriver.peripheralDriver.OSPI.CSn0.$suggestSolution = "OSPI0_CSn0";
    -flash1.serialFlashDriver.peripheralDriver.OSPI.DQS.$suggestSolution = "OSPI0_DQS";
    -flash1.serialFlashDriver.peripheralDriver.OSPI.D7.$suggestSolution = "OSPI0_D7";
    -flash1.serialFlashDriver.peripheralDriver.OSPI.D6.$suggestSolution = "OSPI0_D6";
    -flash1.serialFlashDriver.peripheralDriver.OSPI.D5.$suggestSolution = "OSPI0_D5";
    -flash1.serialFlashDriver.peripheralDriver.OSPI.D4.$suggestSolution = "OSPI0_D4";
    flash1.serialFlashDriver.peripheralDriver.OSPI.D3.$suggestSolution = "OSPI0_D3";
    flash1.serialFlashDriver.peripheralDriver.OSPI.D2.$suggestSolution = "OSPI0_D2";
    flash1.serialFlashDriver.peripheralDriver.OSPI.D1.$suggestSolution = "OSPI0_D1";

  • Hi Shibi,

    0x600000000 has be configured in the syscfg.
    mpu_armv710.$name = "CONFIG_MPU_REGION9";
    mpu_armv710.allowExecute = false;
    mpu_armv710.size = 9;
    mpu_armv710.attributes = "Device";
    mpu_armv710.baseAddr = 0x2800000;

    mpu_armv711.$name = "FSS0_DAT_REG1";
    mpu_armv711.baseAddr = 0x60000000;
    mpu_armv711.size = 27;
    mpu_armv711.attributes = "Device";
    mpu_armv711.allowExecute = false;

    Not able to understand completely though, but is the region for 0x60000000 marked as Cached?

    --- a/examples/drivers/boot/sbl_ospi_linux_multistage/sbl_ospi_linux_stage1/am62x-sk/r5fss0-0_nortos/example.syscfg
    +++ b/examples/drivers/boot/sbl_ospi_linux_multistage/sbl_ospi_linux_stage1/am62x-sk/r5fss0-0_nortos/example.syscfg
    @@ -2,7 +2,7 @@
    * These arguments were used when this file was generated. They will be automatically applied on subsequent loads
    * via the GUI or CLI. Run CLI with '--help' for additional information on how to override these arguments.
    * @cliArgs --device "AM62x" --package "ALW" --part "Default" --context "r5fss0-0" --product "MCU_PLUS_SDK_AM62x@10.00.00"
    - * @versions {"tool":"1.19.0+3426"}
    + * @versions {"tool":"1.20.0+3587"}
    */

    /**
    @@ -16,10 +16,10 @@ const bootloader2 = bootloader.addInstance();
    const ddr = scripting.addModule("/drivers/ddr/ddr", {}, false);
    const ddr1 = ddr.addInstance();
    const gtc = scripting.addModule("/drivers/gtc/gtc");
    -const qos = scripting.addModule("/drivers/qos/qos", {}, false);
    -const qos1 = qos.addInstance();
    const mcu_bist = scripting.addModule("/drivers/mcu_bist/mcu_bist", {}, false);
    const mcu_bist1 = mcu_bist.addInstance();
    +const qos = scripting.addModule("/drivers/qos/qos", {}, false);
    +const qos1 = qos.addInstance();
    const clock = scripting.addModule("/kernel/dpl/clock");
    const debug_log = scripting.addModule("/kernel/dpl/debug_log");
    const mpu_armv7 = scripting.addModule("/kernel/dpl/mpu_armv7", {}, false);
    @@ -51,15 +51,49 @@ flash1.$name = "CONFIG_FLASH0";
    bootloader1.flashDriver = flash1;
    bootloader2.flashDriver = flash1;
    flash1.serialFlashDriver.$name = "board_flash_serialFlash_serialflash0";
    +flash1.serialFlashDriver.flashSize = 16777216;
    +flash1.serialFlashDriver.flashManfId = "0xEF";
    +flash1.serialFlashDriver.dummy_isAddrReg = false;
    +flash1.serialFlashDriver.dummy_cfgReg = "0x00";
    +flash1.serialFlashDriver.dummy_cmdRegRd = "0x00";
    +flash1.serialFlashDriver.dummy_cmdRegWr = "0x00";
    +flash1.serialFlashDriver.dummy_mask = "0x00";
    +flash1.serialFlashDriver.dummy_bitP = 0;
    +flash1.serialFlashDriver.proto_isAddrReg = false;
    +flash1.serialFlashDriver.proto_cfgReg = "0x00";
    +flash1.serialFlashDriver.proto_cmdRegRd = "0x00";
    +flash1.serialFlashDriver.proto_cmdRegWr = "0x00";
    +flash1.serialFlashDriver.proto_mask = "0x00";
    +flash1.serialFlashDriver.proto_bitP = 0;
    +flash1.serialFlashDriver.fname = "W25Q128JVFAM";
    +flash1.serialFlashDriver.flashDeviceId = "0x7018";
    +flash1.serialFlashDriver.xspiWipRdCmd = "0x05";
    +flash1.serialFlashDriver.quirks = "";
    +flash1.serialFlashDriver.cmdBlockErase3B = "0xD8";
    +flash1.serialFlashDriver.cmdBlockErase4B = "0xD8";
    +flash1.serialFlashDriver.cmdSectorErase3B = "0x20";
    +flash1.serialFlashDriver.cmdSectorErase4B = "0x20";
    +flash1.serialFlashDriver.flashBlockSize = 65536;
    +flash1.serialFlashDriver.protocol = "1s_1s_4s";
    +flash1.serialFlashDriver.cmdRd = "0x6B";
    +flash1.serialFlashDriver.cmdWr = "0x32";
    +flash1.serialFlashDriver.dummyClksRd = 8;
    flash1.serialFlashDriver.peripheralDriver.$name = "CONFIG_OSPI0";
    flash1.serialFlashDriver.peripheralDriver.dmaEnable = true;
    -flash1.serialFlashDriver.peripheralDriver.phyEnable = true;
    -flash1.serialFlashDriver.peripheralDriver.fastBootTuning = "true";
    +flash1.serialFlashDriver.peripheralDriver.baudRateDiv = 8;
    +flash1.serialFlashDriver.peripheralDriver.OSPI.DQS.$used = false;
    +flash1.serialFlashDriver.peripheralDriver.OSPI.D7.$used = false;
    +flash1.serialFlashDriver.peripheralDriver.OSPI.D6.$used = false;
    +flash1.serialFlashDriver.peripheralDriver.OSPI.D5.$used = false;
    +flash1.serialFlashDriver.peripheralDriver.OSPI.D4.$used = false;

    -ddr1.$name = "CONFIG_DDR0";
    +ddr1.$name = "CONFIG_DDR0";
    +ddr1.ddrConfigIncludeFileName = "drivers/ddr/v0/soc/am62x/board_lpddrReginit.h";

    mcu_bist1.$name = "CONFIG_MCU_BIST0";

    +qos1.$name = "CONFIG_QOS0";
    +
    const udma = scripting.addModule("/drivers/udma/udma", {}, false);
    const udma1 = udma.addInstance({}, false);
    udma1.$name = "CONFIG_UDMA0";
    @@ -72,8 +106,6 @@ udma_blkcopy_channel1.$name = "CONFIG_UDMA_BLKC
    bootloader1.udmaBlkCopyChannel = udma_blkcopy_channel1;
    flash1.serialFlashDriver.peripheralDriver.udmaBlkCopyChannel = udma_blkcopy_channel1;

    -qos1.$name = "CONFIG_QOS0";
    -
    clock.instance = "TIMER1";

    debug_log.enableUartLog = true;
    @@ -152,11 +184,6 @@ mpu_armv711.allowExecute = false;
    flash1.serialFlashDriver.peripheralDriver.OSPI.$suggestSolution = "OSPI0";
    flash1.serialFlashDriver.peripheralDriver.OSPI.CLK.$suggestSolution = "OSPI0_CLK";
    flash1.serialFlashDriver.peripheralDriver.OSPI.CSn0.$suggestSolution = "OSPI0_CSn0";
    -flash1.serialFlashDriver.peripheralDriver.OSPI.DQS.$suggestSolution = "OSPI0_DQS";
    -flash1.serialFlashDriver.peripheralDriver.OSPI.D7.$suggestSolution = "OSPI0_D7";
    -flash1.serialFlashDriver.peripheralDriver.OSPI.D6.$suggestSolution = "OSPI0_D6";
    -flash1.serialFlashDriver.peripheralDriver.OSPI.D5.$suggestSolution = "OSPI0_D5";
    -flash1.serialFlashDriver.peripheralDriver.OSPI.D4.$suggestSolution = "OSPI0_D4";
    flash1.serialFlashDriver.peripheralDriver.OSPI.D3.$suggestSolution = "OSPI0_D3";
    flash1.serialFlashDriver.peripheralDriver.OSPI.D2.$suggestSolution = "OSPI0_D2";
    flash1.serialFlashDriver.peripheralDriver.OSPI.D1.$suggestSolution = "OSPI0_D1";

    This is a diff or a difference of the SYSCONFIG file which you sent, can you send me the exact example.syscfg file for me to take a note of the flash configurations?

    This will help me track the parameters easily.

    Apart from this I understand that changing the clock divider from 4 -> 8 helped you out.

    Regards,

    Vaibhav

  • Attaching the full syscfg contents

    /**
    * These arguments were used when this file was generated. They will be automatically applied on subsequent loads
    * via the GUI or CLI. Run CLI with '--help' for additional information on how to override these arguments.
    * @cliArgs --device "AM62x" --package "ALW" --part "Default" --context "r5fss0-0" --product "MCU_PLUS_SDK_AM62x@10.00.00"
    * @versions {"tool":"1.20.0+3587"}
    */

    /**
    * Import the modules used in this configuration.
    */
    const flash = scripting.addModule("/board/flash/flash", {}, false);
    const flash1 = flash.addInstance();
    const bootloader = scripting.addModule("/drivers/bootloader/bootloader", {}, false);
    const bootloader1 = bootloader.addInstance();
    const bootloader2 = bootloader.addInstance();
    const ddr = scripting.addModule("/drivers/ddr/ddr", {}, false);
    const ddr1 = ddr.addInstance();
    const gtc = scripting.addModule("/drivers/gtc/gtc");
    const mcu_bist = scripting.addModule("/drivers/mcu_bist/mcu_bist", {}, false);
    const mcu_bist1 = mcu_bist.addInstance();
    const qos = scripting.addModule("/drivers/qos/qos", {}, false);
    const qos1 = qos.addInstance();
    const clock = scripting.addModule("/kernel/dpl/clock");
    const debug_log = scripting.addModule("/kernel/dpl/debug_log");
    const mpu_armv7 = scripting.addModule("/kernel/dpl/mpu_armv7", {}, false);
    const mpu_armv71 = mpu_armv7.addInstance();
    const mpu_armv72 = mpu_armv7.addInstance();
    const mpu_armv73 = mpu_armv7.addInstance();
    const mpu_armv74 = mpu_armv7.addInstance();
    const mpu_armv75 = mpu_armv7.addInstance();
    const mpu_armv76 = mpu_armv7.addInstance();
    const mpu_armv77 = mpu_armv7.addInstance();
    const mpu_armv78 = mpu_armv7.addInstance();
    const mpu_armv79 = mpu_armv7.addInstance();
    const mpu_armv710 = mpu_armv7.addInstance();
    const mpu_armv711 = mpu_armv7.addInstance();

    /**
    * Write custom configuration values to the imported modules.
    */
    bootloader1.EMMCAppImageOffset = "0x800000";
    bootloader1.$name = "CONFIG_BOOTLOADER_FLASH_MCU";
    bootloader1.appImageOffset = "0x100000";
    bootloader1.bootloaderDma = true;

    bootloader2.EMMCAppImageOffset = "0xC00000";
    bootloader2.$name = "CONFIG_BOOTLOADER_FLASH_SBL";
    bootloader2.appImageOffset = "0x80000";

    flash1.$name = "CONFIG_FLASH0";
    bootloader1.flashDriver = flash1;
    bootloader2.flashDriver = flash1;
    flash1.serialFlashDriver.$name = "board_flash_serialFlash_serialflash0";
    flash1.serialFlashDriver.flashSize = 16777216;
    flash1.serialFlashDriver.flashManfId = "0xEF";
    flash1.serialFlashDriver.dummy_isAddrReg = false;
    flash1.serialFlashDriver.dummy_cfgReg = "0x00";
    flash1.serialFlashDriver.dummy_cmdRegRd = "0x00";
    flash1.serialFlashDriver.dummy_cmdRegWr = "0x00";
    flash1.serialFlashDriver.dummy_mask = "0x00";
    flash1.serialFlashDriver.dummy_bitP = 0;
    flash1.serialFlashDriver.proto_isAddrReg = false;
    flash1.serialFlashDriver.proto_cfgReg = "0x00";
    flash1.serialFlashDriver.proto_cmdRegRd = "0x00";
    flash1.serialFlashDriver.proto_cmdRegWr = "0x00";
    flash1.serialFlashDriver.proto_mask = "0x00";
    flash1.serialFlashDriver.proto_bitP = 0;
    flash1.serialFlashDriver.fname = "W25Q128JVFAM";
    flash1.serialFlashDriver.flashDeviceId = "0x7018";
    flash1.serialFlashDriver.xspiWipRdCmd = "0x05";
    flash1.serialFlashDriver.quirks = "";
    flash1.serialFlashDriver.cmdBlockErase3B = "0xD8";
    flash1.serialFlashDriver.cmdBlockErase4B = "0xD8";
    flash1.serialFlashDriver.cmdSectorErase3B = "0x20";
    flash1.serialFlashDriver.cmdSectorErase4B = "0x20";
    flash1.serialFlashDriver.flashBlockSize = 65536;
    flash1.serialFlashDriver.protocol = "1s_1s_4s";
    flash1.serialFlashDriver.cmdRd = "0x6B";
    flash1.serialFlashDriver.cmdWr = "0x32";
    flash1.serialFlashDriver.dummyClksRd = 8;
    flash1.serialFlashDriver.peripheralDriver.$name = "CONFIG_OSPI0";
    flash1.serialFlashDriver.peripheralDriver.dmaEnable = true;
    flash1.serialFlashDriver.peripheralDriver.baudRateDiv = 8;
    flash1.serialFlashDriver.peripheralDriver.OSPI.DQS.$used = false;
    flash1.serialFlashDriver.peripheralDriver.OSPI.D7.$used = false;
    flash1.serialFlashDriver.peripheralDriver.OSPI.D6.$used = false;
    flash1.serialFlashDriver.peripheralDriver.OSPI.D5.$used = false;
    flash1.serialFlashDriver.peripheralDriver.OSPI.D4.$used = false;

    ddr1.$name = "CONFIG_DDR0";
    ddr1.ddrConfigIncludeFileName = "drivers/ddr/v0/soc/am62x/board_lpddrReginit.h";

    mcu_bist1.$name = "CONFIG_MCU_BIST0";

    qos1.$name = "CONFIG_QOS0";

    const udma = scripting.addModule("/drivers/udma/udma", {}, false);
    const udma1 = udma.addInstance({}, false);
    udma1.$name = "CONFIG_UDMA0";
    bootloader1.udmaDriver = udma1;
    flash1.serialFlashDriver.peripheralDriver.udmaDriver = udma1;

    const udma_blkcopy_channel = scripting.addModule("/drivers/udma/udma_blkcopy_channel", {}, false);
    const udma_blkcopy_channel1 = udma_blkcopy_channel.addInstance({}, false);
    udma_blkcopy_channel1.$name = "CONFIG_UDMA_BLKCOPY_CH0";
    bootloader1.udmaBlkCopyChannel = udma_blkcopy_channel1;
    flash1.serialFlashDriver.peripheralDriver.udmaBlkCopyChannel = udma_blkcopy_channel1;

    clock.instance = "TIMER1";

    debug_log.enableUartLog = true;
    debug_log.enableCssLog = false;
    debug_log.sysfwUartTrace = true;
    debug_log.uartLog.$name = "CONFIG_UART0";
    debug_log.uartLog.intrEnable = "DISABLE";
    debug_log.uartLog.useWakeupDomainPeripherals = false;
    debug_log.sysfwUartLog.$name = "CONFIG_UART_TRACE0";
    debug_log.sysfwUartLog.useWakeupDomainPeripherals = false;
    debug_log.sysfwUartLog.UART.$assign = "USART1";
    debug_log.sysfwUartLog.UART.RXD.$assign = "MCASP0_AFSR";
    debug_log.sysfwUartLog.UART.TXD.$assign = "MCASP0_ACLKR";
    debug_log.sysfwUartLog.UART.RTSn.$assign = "MCASP0_AXR2";
    debug_log.sysfwUartLog.UART.CTSn.$assign = "MCASP0_AXR3";

    mpu_armv71.$name = "CONFIG_MPU_REGION0";
    mpu_armv71.accessPermissions = "Supervisor RD+WR, User RD";
    mpu_armv71.allowExecute = false;
    mpu_armv71.attributes = "NonCached";

    mpu_armv72.$name = "CONFIG_MPU_REGION1";
    mpu_armv72.accessPermissions = "Supervisor RD+WR, User RD";
    mpu_armv72.size = 7;

    mpu_armv73.$name = "CONFIG_MPU_REGION2";
    mpu_armv73.accessPermissions = "Supervisor RD+WR, User RD";
    mpu_armv73.baseAddr = 0x41C00000;
    mpu_armv73.size = 19;

    mpu_armv74.$name = "CONFIG_MPU_REGION3";
    mpu_armv74.accessPermissions = "Supervisor RD+WR, User RD";
    mpu_armv74.baseAddr = 0x70000000;
    mpu_armv74.size = 16;

    mpu_armv75.$name = "CONFIG_MPU_REGION4";
    mpu_armv75.baseAddr = 0x80000000;
    mpu_armv75.size = 31;

    mpu_armv76.$name = "CONFIG_MPU_REGION5";
    mpu_armv76.baseAddr = 0x41010000;
    mpu_armv76.size = 15;
    mpu_armv76.attributes = "NonCached";

    mpu_armv77.$name = "CONFIG_MPU_REGION6";
    mpu_armv77.size = 15;
    mpu_armv77.attributes = "NonCached";

    mpu_armv78.$name = "CONFIG_MPU_REGION8";
    mpu_armv78.baseAddr = 0x43C00000;
    mpu_armv78.size = 18;

    mpu_armv79.$name = "CONFIG_MPU_REGION7";
    mpu_armv79.baseAddr = 0xFC40000;
    mpu_armv79.size = 8;
    mpu_armv79.attributes = "Device";
    mpu_armv79.allowExecute = false;

    mpu_armv710.$name = "CONFIG_MPU_REGION9";
    mpu_armv710.allowExecute = false;
    mpu_armv710.size = 9;
    mpu_armv710.attributes = "Device";
    mpu_armv710.baseAddr = 0x2800000;

    mpu_armv711.$name = "FSS0_DAT_REG1";
    mpu_armv711.baseAddr = 0x60000000;
    mpu_armv711.size = 27;
    mpu_armv711.attributes = "Device";
    mpu_armv711.allowExecute = false;

    /**
    * Pinmux solution for unlocked pins/peripherals. This ensures that minor changes to the automatic solver in a future
    * version of the tool will not impact the pinmux you originally saw. These lines can be completely deleted in order to
    * re-solve from scratch.
    */
    flash1.serialFlashDriver.peripheralDriver.OSPI.$suggestSolution = "OSPI0";
    flash1.serialFlashDriver.peripheralDriver.OSPI.CLK.$suggestSolution = "OSPI0_CLK";
    flash1.serialFlashDriver.peripheralDriver.OSPI.CSn0.$suggestSolution = "OSPI0_CSn0";
    flash1.serialFlashDriver.peripheralDriver.OSPI.D3.$suggestSolution = "OSPI0_D3";
    flash1.serialFlashDriver.peripheralDriver.OSPI.D2.$suggestSolution = "OSPI0_D2";
    flash1.serialFlashDriver.peripheralDriver.OSPI.D1.$suggestSolution = "OSPI0_D1";
    flash1.serialFlashDriver.peripheralDriver.OSPI.D0.$suggestSolution = "OSPI0_D0";
    debug_log.uartLog.UART.$suggestSolution = "USART0";
    debug_log.uartLog.UART.RXD.$suggestSolution = "UART0_RXD";
    debug_log.uartLog.UART.TXD.$suggestSolution = "UART0_TXD";

  • Please use non-DTR variant.

  • Hi,

    I have referred the datasheet and saw that 166 MHz was no where mentioned to be supported for the flash, hence, I would request you to try with the OSPI combinations as follows:

    Combination 1: freq=133333333 , clock divider= 4

    Combination 2: freq=133333333 , clock divider= 8

    Let me know the results.

    Regards,

    Vaibhav

  • Hi, 

            With frequency 166 MHz and divider set to 8, I was able to read the JEDEC id. Is this something to be changed still?

  • With frequency 166 MHz and divider set to 8, I was able to read the JEDEC id. Is this something to be changed still?

    Yes please try with the combinations as mentioned above in my response and let me know how it goes. Looking forward to your response.

  • Tried this setting as well


    Before Drivers open
    ERROR: Flash_norOspiSetAddressBytes:317: Setting address byte to 1 enable 4 byte 1
    ERROR: Flash_norOspiCmdRead:129: cmd 5 cmdaddr 4294967295 databuf datalen 1
    ERROR: Flash_norOspiCmdRead:129: cmd 159 cmdaddr 4294967295 databuf ▒p datalen 3
    ERROR: Flash_norOspiReadId:854: man id EF devid 7018

    SYSFW Firmware Version 10.0.8--v10.00.08 (Fiery Fox)
    SYSFW Firmware revision 0xa
    SYSFW ABI revision 4.0

    Drivers open done
    ERROR: Flash_imgOpen:56: Inside Flash img open
    ERROR: Bootloader_open:93: Bootloader open Flash open status 0
    ERROR: Flash_imgOpen:56: Inside Flash img open
    ERROR: Bootloader_open:93: Bootloader open Flash open status 0
    ERROR: Bootloader_parseMultiCoreAppImage:709: inside Parse multicore app image. Boot Media: 2953248770!!
    ERROR: Bootloader_verifyMulticoreImage:562: inside verify core imageBoot Media: -1341718526!!
    ERROR: Flash_imgRead:67: Inside Flash img Read
    ERROR: Flash_read:185: Inside Flash read 1048576
    ERROR: Flash_norOspiRead:881: inside Flash nor ospi read
    ERROR: Flash_norOspiRead:901: offset 1048576 Data buffer 0x00 0x00 0x00 0x00 length 4
    ERROR: OSPI_readDirect:1214: DMA copy 0, phy enable 0 src 0x60100000 dest 0x43C2CFD4
    ERROR: Flash_norOspiRead:903: Data buffer 0x11 0x60 0x11 0x9A length 4
    ERROR: Flash_imgSeek:91: Inside Flash img seek
    ERROR: Bootloader_verifyMulticoreImage:590: x509header `▒`▒▒C▒C
    ERROR: Flash_imgPhyToggle:106: Inside Flash img phy toggle
    ERROR: Bootloader_parseMultiCoreAppImage:727: verify multicore image -1!!
    Parse image status -1!!
    Reading mcu app image -1!!
    Reading sbl app image -1!!
    [BOOTLOADER_PROFILE] Boot Media : FLASH
    [BOOTLOADER_PROFILE] Boot Media Clock : 133.333 MHz
    [BOOTLOADER_PROFILE] Boot Image Size : 0 KB
    [BOOTLOADER_PROFILE] Cores present :
    [BOOTLOADER PROFILE] System_init : 41968us
    [BOOTLOADER PROFILE] Board_init : 0us
    [BOOTLOADER PROFILE] Drivers_open : 298us
    [BOOTLOADER PROFILE] Board_driversOpen : 29532us
    [BOOTLOADER PROFILE] Sciclient Get Version : 10195us
    [BOOTLOADER PROFILE] App_waitForMcuPbist : 22440us
    [BOOTLOADER PROFILE] App_waitForMcuLbist : 7689us
    [BOOTLOADER PROFILE] App_loadImages : 80981us
    [BOOTLOADER_PROFILE] SBL Total Time Taken : 193107us

    ERROR: Flash_imgClose:99: Inside Flash img close
    Some tests have failed!!
    ERROR: Flash_norOspiCmdRead:129: cmd 5 cmdaddr 4294967295 databuf datalen 1

  • Combination 1: freq=133333333 , clock divider= 4

    Combination 2: freq=133333333 , clock divider= 8

    Did both the combinations led to the same result?

    Regards,

    Vaibhav

  • With divider set to 8 I didn't see any issue in reading JEDEC ID.

    But with 4 it is failing for few tries and finally it could be read.

    Before Drivers open
    ERROR: Flash_norOspiSetAddressBytes:317: Setting address byte to 1 enable 4 byte 1
    ERROR: Flash_norOspiCmdRead:129: cmd 5 cmdaddr 4294967295 databuf datalen 1
    ERROR: Flash_norOspiCmdRead:129: cmd 159 cmdaddr 4294967295 databuf ▒▒0 datalen 3
    ERROR: Flash_norOspiReadId:854: man id DE devid E030
    ERROR: Flash_norOspiReadId:863: Failed to read device id
    ERROR: Flash_norOspiCmdRead:129: cmd 159 cmdaddr 4294967295 databuf ▒▒8 datalen 3
    ERROR: Flash_norOspiReadId:854: man id FF devid F038
    ERROR: Flash_norOspiReadId:863: Failed to read device id
    ERROR: Flash_norOspiCmdRead:129: cmd 159 cmdaddr 4294967295 databuf ▒p datalen 3
    ERROR: Flash_norOspiReadId:854: man id EF devid 7018

    SYSFW Firmware Version 10.0.8--v10.00.08 (Fiery Fox)
    SYSFW Firmware revision 0xa

  • flashFixUpOspiBoot Is this still needed in main function?
  • Hi Vaibhav,

         Happy to share that the certificate can be read now. Identified the issue. The qspi read command for this chip is 0x6B which works with 3B addressing. But syscfg tool always set 4B addressing to be true. I had to set this manually in the API given below for it to read properly.

    static int32_t Flash_norOspiSetAddressBytes(Flash_Config *config, void *ospiHandle)
    {
        int32_t status = SystemP_SUCCESS;
        Flash_DevConfig *devCfg = config->devConfig;
        Flash_NorOspiObject *obj = (Flash_NorOspiObject *)(config->object);
        devCfg->enable4BAddr=FALSE;
    Now, the authentication fails. Is this due to wrong key used to sign?
    ERROR: Flash_norOspiRead:902: offset 1048576 Data buffer 0x00 0x00 0x00 0x00 length 4
    ERROR: OSPI_readDirect:1214: DMA copy 0, phy enable 0 src 0x60100000 dest 0x43C2D0D4
    ERROR: Flash_norOspiRead:904: Data buffer 0x30 0x82 0x06 0x53 length 4
    ERROR: Flash_imgSeek:91: Inside Flash img seek
    ERROR: Bootloader_verifyMulticoreImage:590: x509header 0�S`▒▒▒C
    ERROR: Flash_imgPhyToggle:106: Inside Flash img phy toggle
    ERROR: Bootloader_verifyMulticoreImage:661: Failed to authenticate Image
    ERROR: Bootloader_parseMultiCoreAppImage:727: verify multicore image -1!!
    Parse image status -1!!
  • Hi Shibi,

    With divider set to 8 I didn't see any issue in reading JEDEC ID.

    But with 4 it is failing for few tries and finally it could be read.

    Understood the results here. Thanks.

    flashFixUpOspiBoot Is this still needed in main function?

    Since your flash is operating in QSPI mode, hence we need the alternative of this function which can be though of as flashFixUpQspiBoot. Notice, how the OSPI got changes to QSPI, so will the implementation. To find the implementation you can refer the file: https://github.com/TexasInstruments/mcupsdk-core/blob/next/examples/drivers/boot/sbl_ospi/am243x-lp/r5fss0-0_nortos/main.c#L44

    Once you introduce this you should be good to go.

    But syscfg tool always set 4B addressing to be true

    To eliminate this, we can unselect the option here in SysConfig. Please see the screenshot below:

    Notice how it is unchecked hence the 4 Byte addressing will not be set. Moreover with the flashFixUpQspiBoot being called correctly with the linked implementation, will reset the flash. Once the flash is reset, it means it will automatically be in 3 Byte addressing mode.

    Hope my explanation helps on all the above points.

    Now, the authentication fails. Is this due to wrong key used to sign?

    I am assuming you have an HS FS device and you are using all hs-fs binaries. Please clarify on this front, so that we can isolate the issue: if it is hs-fs binary issue or an issue with the incorrect key(as per your statement).

    Looking forward to your response.

    Regards,

    Vaibhav

  • I am using hs_fs appimages.

  • As I mentioned earlier, I am using mcu_plus_sdk_am62x_10_00_00_14 and sysconfig-1.20.0 version. I don't see an option to disable the 4B addressing in that.

  • As I mentioned earlier, I am using mcu_plus_sdk_am62x_10_00_00_14 and sysconfig-1.20.0 version. I don't see an option to disable the 4B addressing in that.

    This is not expected, I tried using the same combination of the SDK along with the SysConfig, I am able to see the 4 B addressing option there.

    Al you would need to do is expand the "Advanced Flash Configuration" tab and then you will be able to see that option. Let me know if you are able to find it, if not, please send me a screenshot of the FLASH section in your application's SysConfig.

    Thanks,

    Vaibhav

  • Apologize. I found that.

  • How to solve the authentication issue now. I am compiling the applications with Device type GP and it generates the appimage.hs_fs image using rom_degeneratekey. Is this the correct approach?

  • How to solve the authentication issue now. I am compiling the applications with Device type GP and it generates the appimage.hs_fs image using rom_degeneratekey. Is this the correct approach?

    Can you please go ahead and make the following change?

    Set the ddrCopy value to 1 as shown in the snippet above.

    After this is done rebuild the libraries and the application as well.

    Thanks,

    Vaibhav

  • Hi Vaibhav,

             I don't think this resolves the issue. Because I could see that only when DMA copy is false the data is read properly. When the DMA copy is true, it is all 0's. Without this setting previously, I was able to get the correct image size last time. 

         Drivers open done
    ERROR: Flash_imgOpen:56: Inside Flash img open
    ERROR: Bootloader_open:93: Bootloader open Flash open status 0
    ERROR: Flash_imgOpen:56: Inside Flash img open
    ERROR: Bootloader_open:93: Bootloader open Flash open status 0
    ERROR: Bootloader_parseMultiCoreAppImage:712: inside Parse multicore app image. Boot Media: 2953248770!!
    ERROR: Bootloader_verifyMulticoreImage:562: inside verify core imageBoot Media: -1341718526!!
    ERROR: Flash_imgRead:67: Inside Flash img Read
    ERROR: Flash_read:185: Inside Flash read 1048576
    ERROR: Flash_norOspiRead:881: inside Flash nor ospi read
    ERROR: Flash_norOspiRead:901: offset 1048576 Data buffer 0x00 0x00 0x00 0x00 length 4
    ERROR: OSPI_readDirect:1214: DMA copy 0, phy enable 0 src 0x60100000 dest 0x43C2D350
    ERROR: Flash_norOspiRead:903: Data buffer 0x30 0x82 0x06 0x53 length 4
    ERROR: Flash_imgSeek:91: Inside Flash img seek
    ERROR: Bootloader_verifyMulticoreImage:590: x509header 02-07 0▒S▒▒▒C▒C
    ERROR: Flash_imgPhyToggle:106: Inside Flash img phy toggle
    ERROR: Flash_imgRead:67: Inside Flash img Read
    ERROR: Flash_read:185: Inside Flash read 1048576
    ERROR: Flash_norOspiRead:881: inside Flash nor ospi read
    ERROR: Flash_norOspiRead:901: offset 1048576 Data buffer 0x02 0x00 0x40 0x00 length 2048
    ERROR: OSPI_readDirect:1214: DMA copy 1, phy enable 0 src 0x60100000 dest 0x84000000
    ERROR: Flash_norOspiRead:903: Data buffer 0x00 0x00 0x00 0x00 length 2048
    ERROR: Bootloader_verifyMulticoreImage:629: imagelen 0x0 Certlen 0x657
    ERROR: Flash_imgSeek:91: Inside Flash img seek
    ERROR: Flash_imgRead:67: Inside Flash img Read
    ERROR: Flash_read:185: Inside Flash read 1048576
    ERROR: Flash_norOspiRead:881: inside Flash nor ospi read
    ERROR: Flash_norOspiRead:901: offset 1048576 Data buffer 0x00 0x00 0x00 0x00 length 1664
    ERROR: OSPI_readDirect:1214: DMA copy 1, phy enable 0 src 0x60100000 dest 0x84000000
    ERROR: Flash_norOspiRead:903: Data buffer 0x00 0x00 0x00 0x00 length 1664
    ERROR: Bootloader_verifyMulticoreImage:636: cert load addr 0x84000000
    ERROR: Flash_imgSeek:91: Inside Flash img seek
    ERROR: Bootloader_verifyMulticoreImage:652: flash current offset 0x100000 Image length 0x0 cert length 0x657 load addr 0x84000000 values2
    ERROR: Sciclient_service:251: ret status 0 msgtype 49440
    ERROR: Sciclient_service:258: ret status 0
    ERROR: Bootloader_socAuthImage:1076: ret status 0
    ERROR: Flash_imgPhyToggle:106: Inside Flash img phy toggle
    ERROR: Bootloader_parseMultiCoreAppImage:730: verify multicore image 0!!
    ERROR: Bootloader_parseMultiCoreAppImage:753: Current offset 0x84000000!!

  • Hi,

    Did you try setting the ddrCopy variable to 1 and testing out further after rebuilding successfully?

    Please also read this: https://e2e.ti.com/support/processors-group/processors/f/processors-forum/1530694/am62p-am62p-sbl-with-gd25f64-flash-the-mirror-loading-speed-is-slow/5905869#5905869

    Regards,

    Vaibhav

  • Hi,  

          I tried this method, and the previously attached log was taken with this change made. I tried printing the data it copied to the buffer but they were all zeros.

    Should I try manually copying from NOR flash to DDR instead? The thread you shared speaks about that.

  • Should I try manually copying from NOR flash to DDR instead? The thread you shared speaks about that.

    Yes please try the same and let me know as well.

  • What version of mcu sdk should I pick for this to work?

  • I would recommend picking the latest one: www.ti.com/.../11.00.00.16

  • Hi Vaibhav,

         I have narrowed down the issue to memory copy to scratch memory (0x84000000). Data is copied properly when it tries to read 2048 bytes from NOR flash. But it works momentarily when entire image is copied to scratch memory (54016 bytes, appimage size). Further, this memory is used for getting data from other functions. Hence, this will not work as expected.

    ERROR: Bootloader_verifyMulticoreImage:629: Reading 0x800 bytest to scratch memory
    Data at scratch memory 0x0, 0x1, 0x2
    ERROR: Flash_imgRead:67: Inside Flash img Read flash index 0 offset 0x100000
    ERROR: Flash_read:185: Inside Flash read 1048576
    ERROR: Flash_norOspiRead:881: inside Flash nor ospi read
    ERROR: Flash_norOspiRead:901: offset 1048576 Data buffer 0x00 0x00 0x00 0x00 length 2048
    ERROR: OSPI_readDirect:1214: DMA copy 0, phy enable 0 src 0x60100000 dest 0x84000000
    ERROR: Utils_memcpyWord:42: source 0x60100000 destination 0x84000000 length 2048
    ERROR: Utils_memcpyWord:43: Data at source 0x30 0x82 0x6 0x53
    ERROR: Utils_memcpyWord:46: alignment
    ERROR: Utils_memcpyWord:105: Data at destination 0x30 0x82 0x6 0x53
    ERROR: Flash_norOspiRead:903: Data buffer 0x30 0x82 0x06 0x53 length 2048
    ERROR: Bootloader_verifyMulticoreImage:631: Data at scratch memory 0x30, 0x82, 0x6
    ERROR: Bootloader_verifyMulticoreImage:633: scratch pointer 84000000 imagelen 0xCC64 Certlen 0x657
    ERROR: Flash_imgSeek:91: Inside Flash img seek
    ERROR: Bootloader_verifyMulticoreImage:637: Reading image to scracth memory
    ERROR: Flash_imgRead:67: Inside Flash img Read flash index 0 offset 0x100000
    ERROR: Flash_read:185: Inside Flash read 1048576
    ERROR: Flash_norOspiRead:881: inside Flash nor ospi read
    ERROR: Flash_norOspiRead:901: offset 1048576 Data buffer 0x30 0x82 0x06 0x53 length 54016
    ERROR: OSPI_readDirect:1214: DMA copy 0, phy enable 0 src 0x60100000 dest 0x84000000
    ERROR: Utils_memcpyWord:42: source 0x60100000 destination 0x84000000 length 54016
    ERROR: Utils_memcpyWord:43: Data at source 0x30 0x82 0x6 0x53
    ERROR: Utils_memcpyWord:46: alignment
    ERROR: Utils_memcpyWord:105: Data at destination 0x30 0x0 0x36 0x0
    ERROR: Flash_norOspiRead:903: Data buffer 0x30 0x00 0x36 0x00 length 54016
    ERROR: Bootloader_verifyMulticoreImage:640: Data at scratch memory 0x30, 0x0, 0x36

    This log is captured with dma copy disabled. Enabling it also doesn't seem to fix the issue.

  • Hi,

    Thanks for the update.

    I have narrowed down the issue to memory copy to scratch memory (0x84000000). Data is copied properly when it tries to read 2048 bytes from NOR flash. But it works momentarily when entire image is copied to scratch memory (54016 bytes, appimage size). Further, this memory is used for getting data from other functions. Hence, this will not work as expected.

    Interesting find.

    So now there are two cases:

    2048 bytes read working:

    ERROR: Utils_memcpyWord:42: source 0x60100000 destination 0x84000000 length 2048
    ERROR: Utils_memcpyWord:43: Data at source 0x30 0x82 0x6 0x53
    ERROR: Utils_memcpyWord:46: alignment
    ERROR: Utils_memcpyWord:105: Data at destination 0x30 0x82 0x6 0x53
    ERROR: Flash_norOspiRead:903: Data buffer 0x30 0x82 0x06 0x53 length 2048
    ERROR: Bootloader_verifyMulticoreImage:631: Data at scratch memory 0x30, 0x82, 0x6

    The appimage read not working:

    ERROR: Flash_norOspiRead:901: offset 1048576 Data buffer 0x30 0x82 0x06 0x53 length 54016
    ERROR: OSPI_readDirect:1214: DMA copy 0, phy enable 0 src 0x60100000 dest 0x84000000
    ERROR: Utils_memcpyWord:42: source 0x60100000 destination 0x84000000 length 54016
    ERROR: Utils_memcpyWord:43: Data at source 0x30 0x82 0x6 0x53
    ERROR: Utils_memcpyWord:46: alignment
    ERROR: Utils_memcpyWord:105: Data at destination 0x30 0x0 0x36 0x0
    ERROR: Flash_norOspiRead:903: Data buffer 0x30 0x00 0x36 0x00 length 54016
    ERROR: Bootloader_verifyMulticoreImage:640: Data at scratch memory 0x30, 0x0, 0x36

    Please let me know the current OSPI settings as well, is it the clock divider 8 or 4. I am assuming frequency is still set to 133 MHz(actual 133333333).

    Apart from this, I see that the protocol is 1s-1s-4s, so on that note, there is a limitation of the controller that the clock divider needs to be 4 and not 8.

    Let me know your thoughts.

    Thanks,

    Vaibhav

  • Clock divider is set to 8. Do you suggest setting it to 4?

  • Hi Shibi,

    Thanks for your patience.

    Clock divider is set to 8. Do you suggest setting it to 4?

    Yes, I would suggest to set it to 4.

    The reason being:

    Apart from this, I see that the protocol is 1s-1s-4s, so on that note, there is a limitation of the controller that the clock divider needs to be 4 and not 8.

    Thanks,

    Vaibhav

  • Hi Vaibhav,

             I tried with 133MHz and clock divider 4 and 8. Still, the results are same. Also tried with 166 MHz and 4. Same results. I think QSPI works as expected but copying the data to RAM doesn't seem to work as expected. Is this something to deal with Cache?

        ERROR: Utils_memcpyWord:105: Data at destination 0x30 0x82 0x6 0x53
    ERROR: Flash_norOspiRead:903: Data buffer 0x30 0x82 0x06 0x53 length 4
    ERROR: Flash_imgSeek:91: Inside Flash img seek
    ERROR: Bootloader_verifyMulticoreImage:593: x509header 02-07 0ނS0W▒C▒¤▒C
    ERROR: Flash_imgPhyToggle:106: Inside Flash img phy toggle
    ERROR: Bootloader_verifyMulticoreImage:629: Reading 0x800 bytest to scratch memory
    Data at scratch memory 0x0, 0x1, 0x2
    ERROR: Flash_imgRead:67: Inside Flash img Read flash index 0 offset 0x100000
    ERROR: Flash_read:185: Inside Flash read 1048576
    ERROR: Flash_norOspiRead:881: inside Flash nor ospi read
    ERROR: Flash_norOspiRead:901: offset 1048576 Data buffer 0x00 0x00 0x00 0x00 length 2048
    ERROR: OSPI_readDirect:1214: DMA copy 0, phy enable 0 src 0x60100000 dest 0x84000000
    ERROR: Utils_memcpyWord:42: source 0x60100000 destination 0x84000000 length 2048
    ERROR: Utils_memcpyWord:43: Data at source 0x30 0x82 0x6 0x53
    ERROR: Utils_memcpyWord:46: alignment
    ERROR: Utils_memcpyWord:105: Data at destination 0x30 0x82 0x6 0x53
    ERROR: Flash_norOspiRead:903: Data buffer 0x30 0x82 0x06 0x53 length 2048
    ERROR: Bootloader_verifyMulticoreImage:631: Data at scratch memory 0x30, 0x82, 0x6
    ERROR: Bootloader_verifyMulticoreImage:633: scratch pointer 84000000 imagelen 0xCC64 Certlen 0x657
    ERROR: Flash_imgSeek:91: Inside Flash img seek
    ERROR: Bootloader_verifyMulticoreImage:637: Reading image to scracth memory
    ERROR: Flash_imgRead:67: Inside Flash img Read flash index 0 offset 0x100000
    ERROR: Flash_read:185: Inside Flash read 1048576
    ERROR: Flash_norOspiRead:881: inside Flash nor ospi read
    ERROR: Flash_norOspiRead:901: offset 1048576 Data buffer 0x00 0x00 0x00 0x00 length 54016
    ERROR: OSPI_readDirect:1214: DMA copy 0, phy enable 0 src 0x60100000 dest 0x84000000
    ERROR: Utils_memcpyWord:42: source 0x60100000 destination 0x84000000 length 54016
    ERROR: Utils_memcpyWord:43: Data at source 0x30 0x82 0x6 0x53
    ERROR: Utils_memcpyWord:46: alignment
    ERROR: Utils_memcpyWord:105: Data at destination 0x0 0x5 0x0 0x3D
    ERROR: Flash_norOspiRead:903: Data buffer 0x00 0x05 0x00 0x3D length 54016
    ERROR: Bootloader_verifyMulticoreImage:641: Data at scratch memory 0x0, 0x5, 0x0
    ERROR: Bootloader_verifyMulticoreImage:644: cert load addr 0x84000000
    ERROR: Flash_imgSeek:91: Inside Flash img seek
    ERROR: Bootloader_verifyMulticoreImage:660: flash current offset 0x100000 Image length 0xCC64 cert length 0x657 load ad2
    ERROR: Sciclient_service:251: ret status 0 msgtype 49440
    ERROR: Sciclient_service:258: ret status 0
    ERROR: Bootloader_socAuthImage:1076: ret status 0
    ERROR: Flash_imgPhyToggle:106: Inside Flash img phy toggle
    ERROR: Bootloader_verifyMulticoreImage:689: Current offset 00100000
    ERROR: Bootloader_parseMultiCoreAppImage:739: verify multicore image 0!!
    ERROR: Bootloader_parseMultiCoreAppImage:763: Flash index 0x0 Flash type 0x43C1A650
    Current offset 0x84000000, 0x0!!
    ERROR: Mem_imgRead:71: Inside Image img Read dma enable? 0
    ERROR: Utils_memcpyWord:42: source 0x84000000 destination 0x43C2563C length 16
    ERROR: Utils_memcpyWord:43: Data at source 0x0 0x0 0x0 0x3D
    ERROR: Utils_memcpyWord:46: alignment
    ERROR: Utils_memcpyWord:105: Data at destination 0x0 0x0 0x0 0x3D
    ERROR: Bootloader_parseMultiCoreAppImage:765: Image read function magic string 0x3D000000 0!!
    Parse image status -1!!

  • Hi Shibi,

    Is this something to deal with Cache?

    It could be because of the cache.

    The cache invalidation might not be happening which results in stale date.

    Can you use the API CacheP_inv to invalidate the destination buffer?

    Regards,

    Vaibhav

  • Hi Vaibhav,

             I am calling the CacheP_inv before reading the total length in bootloader.c. But the issue still persists

    CacheP_inv((void *)config->scratchMemPtr, totalLen, CacheP_TYPE_ALL);
  • Hi,

    I have assigned another expert to help comment on the DMA. Please expect responses in sometime.

    Regards,

    Vaibhav

  • Hello Shibi ,

    I talked with Vaibhav on the above observation, and you are already confirmed with the DMA, you are not able to read the length of 54016 bytes .

    Without DMA you are able to read the 54016 bytes.

    Here, we can try a simple test case. Instead of 54016 bytes, we can try to read 52K bytes (53248 bytes ).

    Try the above test case and see if you are able to read this pattern or not.

    Regards,

    Anil.

  • Hi Swargam,

           Thanks for joining the thread. I noticed that the data I am writing to the RAM is not properly written. Because if I write and read, at many offset the data is matching with what was written. 

    I did a small write-read test with length 54016. I am writing 0xDEADBEEF to the memory.  First few offsets in the memory retains the data correctly.

    Is this something to do with RAM configuration? Cache is enabled in this memory region.


    Drivers open done
    ERROR: Flash_imgOpen:56: Inside Flash img open
    ERROR: Bootloader_open:93: Bootloader open Flash open status 0
    ERROR: Flash_imgOpen:56: Inside Flash img open
    ERROR: Bootloader_open:93: Bootloader open Flash open status 0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 24 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 25 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 26 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 27 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 28 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 29 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 30 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 31 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 32 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 33 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 34 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 35 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 36 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 37 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 38 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 39 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 40 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 41 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 42 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 43 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 44 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 45 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 46 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 47 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 64 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 65 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 66 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 67 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 68 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 69 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 70 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 71 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 120 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 121 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 122 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 123 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 124 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 125 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 126 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 127 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 152 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 153 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 154 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 155 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 156 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 157 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 158 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 159 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 440 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 441 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 442 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 443 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 444 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 445 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 446 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 447 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 448 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 449 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 450 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 451 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 452 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 453 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 454 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 455 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 456 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 457 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 458 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 459 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 460 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 461 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 462 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 463 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 464 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 465 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 466 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 467 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 468 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 469 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 470 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 471 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 472 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 473 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 474 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 475 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 476 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 477 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 478 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 479 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 480 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 481 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 482 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 483 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 484 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 485 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 486 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 487 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 488 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 489 data 0xEF00AD
    ERROR: RAM_test:271: Data mismatch at 84000000 index 490 data 0xEF00EF
    ERROR: RAM_test:271: Data mismatch at 84000000 index 491 data 0xEF00EF
    ERROR: RAM_test:271: Data mismatch at 84000000 index 492 data 0xEF00EF
    ERROR: RAM_test:271: Data mismatch at 84000000 index 493 data 0xEF00EF
    ERROR: RAM_test:271: Data mismatch at 84000000 index 494 data 0xEF00EF
    ERROR: RAM_test:271: Data mismatch at 84000000 index 495 data 0xEF00EF
    ERROR: RAM_test:271: Data mismatch at 84000000 index 496 data 0x0
    ERROR: RAM_test:271: Data mismatch at 84000000 index 497 data 0xEF00AC
    ERROR: RAM_test:271: Data mismatch at 84000000 index 498 data 0xEF00EF
    ERROR: RAM_test:271: Data mismatch at 84000000 index 499 data 0xEF00EF
    ERROR: RAM_test:271: Data mismatch at 84000000 index 500 data 0xEF00EF
    ERROR: RAM_test:271: Data mismatch at 84000000 index 501 data 0xEF00EF

  • Hello Shibi ,

    You can confirm either the above memory is cached or not by checking the below memory region.

    Mostly the DDR memory is cached.

    If this memory is cached, then after the DMA we need to perform the cache_invalidation, then only the CPU will be able to see the proper content of the memory.

    Regards,

    Anil.

  • Cache is enabled in this memory region.

    Lets disable cache for this region and see the progress.

    Thanks,

    Vaibhav