OSPI_readDirect and OSPI_isPhyEnable do not correctly check if the PHY is enabled

XMLWordPrintable

    • Type: Bug
    • Resolution: Duplicate
    • Priority: Medium
    • SITSW-6469
    • 10.01.00
    • 11.01.00
    • Hide
      am62xx-sk
      am62xx-sk-lp
      am62x-sip-sk
      am62a-sk
      am62p-sk
      am62d-evm
      am243x-evm
      am243x-lp
      am64xx-evm
      am64xx-sk
      am62l-evm
      Show
      am62xx-sk am62xx-sk-lp am62x-sip-sk am62a-sk am62p-sk am62d-evm am243x-evm am243x-lp am64xx-evm am64xx-sk am62l-evm
    • Duplicate of bug SITSW-7032

      OSPI_readDirect and OSPI_isPhyEnable check the flash attributes structure for the PHY being enabled, which is not always reflective of if the PHY is actually enabled. Both functions check for the PHY being enabled by doing this:

      OSPI_isPhyEnable
          const OSPI_Attrs* attrs = ((OSPI_Config *)handle)->attrs;
          retVal = attrs->phyEnable;
          return retVal;
          
      OSPI_readDirect
          if(attrs->phyEnable == TRUE) 

      This attributes structure must be updated manually and does not indicate if the actual PHY is enabled. There are multiple ways to solve this, but the simplest way may be just inspecting the IP register like the OSPI_enablePhy function does.

      //1 if enabled, 0 if not
      uint32_t phyEnable = CSL_REG32_FEXT(&pReg->CONFIG_REG, OSPI_FLASH_CFG_CONFIG_REG_PHY_MODE_ENABLE_FLD);

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

              Created:
              Updated:
              Resolved:

                Connection: Intermediate to External PROD System
                EXTSYNC-5257 - OSPI_readDirect and OSPI_isPhyEnabl...
                SYNCHRONIZED
                • Last Sync Date: