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.

TDA4VH-Q1: Network DMA problem consultation

Part Number: TDA4VH-Q1

HI ,TI experts

      Our use Software  Version  is  SDK 8.6。

      why the network driver tx&rx needs to perform interrupt disable and enable operations for the DMA, while other modules that use DMA do not require similar operations? Can we avoid disabling and enabling interrupts in the DMA critical functions of the network driver in Linux and PDK? 

Linux:

am65_cpsw_nuss_tx_irq

     -->disable_irq_nosync(irq)

am65_cpsw_nuss_tx_poll

      ---> enable_irq(tx_chn->irq);

PDK:

Lwip2Enet_notifyRxPackets

     -->EnetDma_disableRxEvent(rx->hFlow)

Lwip2Enet_rxPacketTask

    -->EnetDma_enableRxEvent(rx->hFlow)

Best regards

Alex

 

  • Hello Alex, 

    Our assigned engineer is out of office, please expect a delay in the response. Thank you for your patience. 

    Regards,
    Sarabesh S

  • Hi,

      why the network driver tx&rx needs to perform interrupt disable and enable operations for the DMA, while other modules that use DMA do not require similar operations? 

    This is the standard flow every driver follows, whoever handles large data via DMA.

    The process is to spend short time in Interrupt and schedule the task to process the data and enable the interrupt after processing all the data from DMA (i.e. process all descriptors) and free the descriptors and submit back to DMA.

    In Linux NAPI will be scheduled and irq will be disabled in Interrupt Handler, and processing all the data in NAPI interrupt will be enabled. (This also avoids firing more interrupts to CPU)

    Please refer to other Network drivers in Linux for reference.

    Best Regards,
    Sudheer 

  • HI, Sudheer 

    Thank you for your answer. Our questions arose because this current DMA usage method sporadically presents the following issues on MCU2_0:

    Exception data abort on task context!!!
    Exception pc : 0x99fc07e4
    Exception sp : 0x99917f60
    Current task : Lwip2Enet_RxPacketTask
    r0 : 0x00000001  r1 : 0x00000000
    r2 : 0x00000001  r3 : 0x00000000
    r4 : 0x00000000  r5 : 0x33db7000
    r6 : 0x00000001  r7 : 0x00000000
    r8 : 0x08080808  r9 : 0x99911d70
    r10 : 0x99910d34 r11 : 0x9a080899
    r12 : 0x00000008 r14 : 0x99fc07d0
    dfsr : 0x00001808 dfar : 0x33db7000
    ifsr : 0x00000000 ifar : 0x00000000

    We found the issue occurred when accessing register (0x33db7000), and the specific process is as follows:

    Lwip2Enet_rxPacketTask

        -->EnetDma_enableRxEvent(rx->hFlow)

            -->CSL_intaggrSetIntrEnable

    So what could be the cause of this issue? Do TI’s experts have any ideas?

    Best regards

    Alex

  • Hi,

    May I know which example are you running?
    Also, Please share us the changes if you have made any?

    We found the issue occurred when accessing register (0x33db7000), and the specific process is as follows:

    Also, is it the same register address whenever it was working.

    Best Regards,
    Sudheer