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.

Map_EmacConfigSet() fails to set {DGF} bit 5 in (EMACDMAOPMODE) REG58:0xC18

Guru 55913 points

Adding one more bit set [5] (Drop giant frames) to existing bit set commands but EMACDMAOPMODE REG58 is not obeying Map_EMACConfigSet().

Does making RX Watchdog set enable over ride the giant frame set bit [5] in REG58?

Possibly some undocumented vital information around these registers behaviors? 

 /* Set MAC configuration options in REG-58:0xC18 (EMACDMAOPMODE).
  * Reference: hw_emach.h, emac.h */

    MAP_EMACConfigSet(EMAC0_BASE, (EMAC_CONFIG_FULL_DUPLEX |
                                   EMAC_CONFIG_CHECKSUM_OFFLOAD |
                                   EMAC_CONFIG_7BYTE_PREAMBLE |
                                   EMAC_CONFIG_IF_GAP_96BITS |
                                   EMAC_CONFIG_USE_MACADDR0 |
                                   EMAC_CONFIG_SA_FROM_DESCRIPTOR |
                                   EMAC_CONFIG_BO_LIMIT_1024 |
                                   EMAC_DMAOPMODE_DGF), // Drop Giant Frames
    		            /* Configure the DMA engine to operate on the first frame
    		             * sending updates of descriptor status words on completion. */
                       (EMAC_MODE_RX_STORE_FORWARD |         //set RSF[21], (Reset) clears
                        EMAC_MODE_TX_STORE_FORWARD), 2048);  //set TSF[25], (Reset) clears
                         // TTC/RTC Ignored (TX/RX(SF)[25,21] set
                         // >2048-RX Giant frames watchdog timer WDIS.
  • Hello BP101

    Does a manual write of the register bit in the configuration allow it to remain set? Need to check if there is a function call which causes the bit to get cleared

    Regards
    Amit
  • Hi Amit,

    Think what we are seeing in this behavior is not related to SW. Rather HW architecture registers appear to deny DGF based on other register settings. The datasheet text does list any constraint over DGF[5]. Suspect text leaves out information or other an errata exists in the complex DMAIM/OPMODE.
  • Opps - the register 58 Dword was put in the wrong place in EMACConfigSet():

    The proper location:

    (EMAC_MODE_RX_STORE_FORWARD | 
     EMAC_MODE_TX_STORE_FORWARD | 
              EMAC_DMAOPMODE_DGF), 2048);