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.

How to access MSTPRI register on DM8168?

Hello.

How can I change value of MSTPRIx registers on DM8168? What is address of those registers? Shall I touch it from u-boot only or can it be done from linux side?

It is mentioned in "TMS320DM816x DaVinci Digital Media Processors Technical Reference Manual" in chapter "6.2.13 Transfer Node Priority", but no details are given.

I was able to find details for dm6446, but not for dm8168.

  • Also, could anyone, please, clarify relationship between QUEPRI and MSTPRI registers?

    Accoring docs:

    MSTPRI: "master priority register is used to set the priority of the transfer node used in issuing memory transfer requests to system memory ... within the Switched Central Resource (SCR5) for master peripheral"

    QUEPRI: "programming QUEPRI essentially governs the priority of the associated transfer controller(s) read/write commands with respect to the other bus masters in the device"

    Shall I ever touch QUEPRI if I want to adjust prio of EMAC? If so, how to discover TCn that affects EMAC?
  • I guess QUEPRI has nothing to do with EMAC since EMAC has its own DMA engine.

    Still I can't find address of MSTPRI register mentioned in chapter "6.2.13 Transfer Node Priority" of "TMS320DM816x Technical Reference Manual".

    As for DM6446 it is given in "Table 3-1. System Module Register Memory Map".
    But as for DM816X it is not present neither in "Table 6-4. Device Configuration Registers Summary" of SPRS614F, nor in "Table 1-212. Device Configuration Registers" of SPRUGX8C.

    Any clue please?
  • Alexey,

    The DM816x EMAC priority is controlled from the INIT_PRESSURE_1 register (address 0x4814060C)

    [1:0] CPGMAC0 - EMAC0 initiator pressure
    [3:2] CPGMAC1 - EMAC1 initiator pressure

    L3 Interconnect – Routes/arbitrates bus requests between Masters and Slaves

    EMAC data traffic initiator have programmable pressure control for interconnect. Data from EMAC initiator to targets goes through shared switches. When multiple initiators are going to single target through shared switch, there will be arbitration. “Pressure” determines which initiator’s request wins arbitration in interconnect switch. For same pressure round robin arbitration is performed.

    Interconnect supports 3 levels of pressure
    0x0 low pressure
    0x1 medium pressure
    0x3 high pressure
    Note: 0x2 pressure value is illegal

    This is static pressure.

    There is no MSTPRIx register in DM816x device, it is replaced with INIT_PRESSURE_x.

    Regards,
    Pavel
  • Great, thanks a lot!

    Is it possible to modify this register from linux kernel in run-time? Or should it be set before linux loaded (from u-boot)?
  • Alexey,

    You can not modify this register from user space (run-time), as this register needs supervisor/privileged mode, and in user space (run-time) you are in user mode, see the below e2e threads for more info:

    e2e.ti.com/.../1466571
    e2e.ti.com/.../225767
    e2e.ti.com/.../1053217
    e2e.ti.com/.../255684

    You can modify this register value from u-boot and from linux kernel, where you are in supervisor/privileged mode.

    Regards,
    Pavel