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.

TDA2HG: Clear Buffer On Utils_memAlloc will access illegale address in early boot

Part Number: TDA2HG

Hi,

Like thread  said: Utils_memAlloc will rise iommu fault on init stage.

It works fine on noraml boot(load ipu and dsp image in linux stage). But when I swith to early boot, it will cause mmu fault below:

When I allocate at address: 0x8f680800, it return fine. But when it call BspOsal_cacheWb it will cause iommu fault which access address is 0x9cad3d00, which have more than 207MB with 0x8f680800.

After my deep inspection, I found it will rise fault when memset 0 in Utils_memAlloc. If I comments those code, it works fine. So my question is:

1. Why memset will jump to unspecified memory area? And what's the relationship with earlyboot?

2. If this fault caused by memset, why flags is 0(IOMMU_FAULT_READ)?

Thanks!

BR/Tim

  • Sorry,

    I guess this problem may cause by IPC. Because I use printf or use for loop to replace memset. This crash jumper to other place, but always after IPC communicate.

    From this log, it crash at 0x6208c0c8. And my Ammu2_bios.cfg:

        /* EVE1 MBOX0, MBOX1 */ 
        var entry = AMMU.mediumPages[1];
        entry.pageEnabled = AMMU.Enable_YES;
        entry.logicalAddress = 0x62088000;
        entry.translatedAddress = 0x42088000;
        entry.translationEnabled = AMMU.Enable_YES;
        entry.size = AMMU.Medium_256K;
        entry.L1_cacheable = AMMU.CachePolicy_NON_CACHEABLE;
        entry.L1_writePolicy = AMMU.WritePolicy_WRITE_THROUGH;
        entry.L1_allocate    = AMMU.AllocatePolicy_NON_ALLOCATE;
        entry.L1_posted = AMMU.PostedPolicy_POSTED;
        entry.L2_cacheable = AMMU.CachePolicy_NON_CACHEABLE;
        entry.L2_posted = AMMU.PostedPolicy_NON_POSTED;
    And MBOX0 is used by rpmsg. So it may have bad operation between EVE1 and IPU2 IPC.
  • Hi,

    Is there any suggest?

    I can't understand why eve operation can effect ipu2.

    Thanks!

    BR/Tim