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.

AM6442: AM64x RAT module

Part Number: AM6442


Hi all

Would you mind if we ask AM64 RAT(Region-based Address Translation) module?


<Question 1>
IF we want to access over 32bit address space(e.g. PCIE0_DAT1 : 0x600000000-0x6FFFFFFFF) from R5F core, shouId we use RAT module?
And if we access from 64bit cpu (e.g. A53), can the CPU see the memory space directly without RAT module?

<Question2>
In MCU+SDK, please let us know any information about RAT module example or device driver.


<Question3>
Does the ti-clang compiler allow to write memory address directly in C language?
e.g. *(&0x000001000) = {number};

Kind regards,

Hirotaka Matsumoto

  • Hello Hirotaka Matsumoto,

    I am working on your thread . You may get a reply in one or two days .

    Regards,

    S.Anil.

  • S.Anil san

    Thank you for your reply.
    We are looking forward to your update!

    Kind regards,

    Hirotaka Matsumoto

  • Hello Hirotaka Matsumoto,

    The RAT is a simple address remapping logic. 

    Assume R5 issues a transaction to address X.

    If X is NOT mapped to any of the RAT-configured remapping regions, the transaction is set to the SoC side using address X.

    If X is located in one of the RAT-configured regions, then it will be translated to address Y. Y can be any address. RAT hardware does not check the address Y at all. Therefore, there is no issue from the HW side if you want to map the address from 0x8000_0000 to oxFFFF_FFFF to any address on the SoC level.

    IF we want to access over 32bit address space(e.g. PCIE0_DAT1 : 0x600000000-0x6FFFFFFFF) from R5F core, shouId we use RAT module?

    Yes, you should use the steps below to enable RAT in your Application.

    Please follow the below steps to configure the RAT Module.

    1. Configure RAT settings based on the below image on your system.

     

    2. Call the below function to convert system address space (over 32bit address) into 32-bit address space.

    LocalBaseAddr = (uint32_t) AddrTranslateP_getLocalAddr (0x73D300000);

     

    3. Now, you have a local address space of 0x73D300000 Register.

    4. uint32 *ptr

    ptr = & LocalBaseAddr ;

    *LocalBaseAddr  = Write whatever value you want to write, and it will be assigned to the system address space, which is more than 32 bits address space.

    For your requirement, you should set the size based on your address space , and the system address space would be 0x600000000.

    And if we access from 64bit cpu (e.g. A53), can the CPU see the memory space directly without RAT module?

    Yes . A53 can directly access 64-bit Address and does not need any RAT modules.

    Does the ti-clang compiler allow to write memory address directly in C language?
    e.g. *(&0x000001000) = {number};

    Yes, it is possible. Please see the above example. I have clearly explained how to access more than 32 bits Address space memories.

    I hope this can be helpful .

    Regards,

    S.Anil.

    Regards,

    S.Anil.