Uploaded image for project: 'Embedded Software & Tools'
  1. Embedded Software & Tools
  2. EXT_EP-11339

FLS Driver instability with read-lengths not multiples of 256 bytes

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Medium Medium
    • MCAL
    • MCAL-8350
    • MCUSW_J7_01.03.00
    • j721e-evm

      The customer (Vector) has run into this issue and has added the following description:

       

      The issue appeared to me on the read with length and/or address not equal multiples of 256, in the example below at the read of 2 bytes. __ 

      The read gave back false data (if I remember correctly the first byte was correct, the 2^nd^ one was ORed with 0x04). __ 

      After that, a write access was running endlessly in the Fls module. __ 

      My workaround was to always perform 256 byte accesses aligned to 256 byte and read the actually required data out in a wrapper. I’ve attached the code to this mail. __ 

      The wrapper expects JobEndNotificationWrapper and JobErrorNotificationWrapper to be called by the Fls module as callbacks and FlsWrapper_Read to be used by upper layer. The FlsWrapper_Cancel is just there as the API is required by Vector FEE module.

       

      Attached is the Wrapper code (FlsWrapper.c) mentioned by the customer. Below is the test they are using to replicate the issue:

      volatile uint8 dummyArray[0x30];

      volatile uint8 buffer1[512];

      volatile uint8 buffer2[512];

      volatile uint8 buffer3[512];

      volatile uint32 counter;

      volatile tFblResult result;

      volatile MemIf_JobResultType jobResult;

      volatile uint8 breaker;

        

      void PollFls(void)

      {

        do

       

      {     Fls_MainFunction();     jobResult = Fls_GetJobResult();   }

      while (jobResult == MEMIF_JOB_PENDING);

      }

        while(1)

        {

          result = Fls_Erase(0x3FF0000, 0x10000);

          PollFls();

          result = Fls_Write(0x3FFFF00, buffer1, 256);

          PollFls();

          result = Fls_Read(0x3FFFF00, buffer2, 256);

          PollFls();

          result = Fls_Read(0x3FFFF00, buffer3, 2);

          PollFls();

          result = Fls_Write(0x3FFFE00, buffer1, 256);

          PollFls();

         

          while(breaker == 0)

          {}

          breaker = 0;

        }

            syncuser TI User
            syncuser TI User
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: