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.

PROCESSOR-SDK-AM57X: /dev/rpmsg-dce not instantiated

Part Number: PROCESSOR-SDK-AM57X

Hello,

We're having an issue with testing IVA-HD on AM57x processors using the file to file video encoding pipeline example given in the documentation:

gst-launch-1.0 filesrc location=waterfall-352-288-nv12-inp.yuv ! videoparse width=352 height=288 format=nv12 ! video/x-raw, width=352, height=288 ! ducatih264enc ! filesink location=waterfall-352-288-nv12-inp_gst.h264
Setting pipeline to PAUSED ...
MmRpc_create: Error: open failed, name=/dev/rpmsg-dce
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstPipeline:pipeline0/GstDucatiH264Enc:ducatih264enc0: Could not initialize supporting library.
Additional debug info:
../../../../gst-plugins-base-1.14.4/gst-libs/gst/video/gstvideoencoder.c(1634): gst_video_encoder_change_state (): /GstPipeline:pipeline0/GstDucatiH264Enc:ducatih264enc0:
Failed to start encoder
../git/libdce.c:416:    dce_ipc_init    ERROR: Failed eError == DCE_EOK error val -4../git/libdce.c:479:        Engine_open     ERROR: Failed dce_ipc_init(coreIdx) == DCE_EOK error val -4Setting pipeline to NULL ...
Freeing pipeline ...

From what I've read in other posts on E2e, this stems from /dev/rpmsg-dce not being present. It is missing from our file system as well, despite libdce1 and ipumm-fw being present in our rootfs, as well as the IPUs seemingly initializing without error:

[    0.000000] OF: reserved mem: initialized node ipu1-memory@95800000, compatible id shared-dma-pool
[    0.000000] OF: reserved mem: initialized node ipu2-memory@9b800000, compatible id shared-dma-pool
[    0.496765] iommu: Adding device 58820000.ipu to group 1
[    0.496847] iommu: Adding device 55020000.ipu to group 2
[    8.127830] omap-rproc 58820000.ipu: ignoring dependency for device, assuming no driver
[    8.156225] omap-rproc 58820000.ipu: ignoring dependency for device, assuming no driver
[    8.176230] omap-rproc 58820000.ipu: assigned reserved memory node ipu1-memory@95800000
[    8.186541] remoteproc remoteproc0: 58820000.ipu is available
[    8.198093] omap-rproc 55020000.ipu: ignoring dependency for device, assuming no driver
[    8.208505] omap-rproc 55020000.ipu: ignoring dependency for device, assuming no driver
[    8.222832] omap-rproc 55020000.ipu: assigned reserved memory node ipu2-memory@9b800000
[    8.281392] remoteproc remoteproc1: 55020000.ipu is available
[    8.981164] remoteproc remoteproc1: powering up 55020000.ipu
[    8.987174] remoteproc remoteproc1: Booting fw image dra7-ipu2-fw.xem4, size 3747232
[    9.052254] remoteproc remoteproc0: powering up 58820000.ipu
[    9.061272] remoteproc remoteproc0: Booting fw image dra7-ipu1-fw.xem4, size 6803868
[    9.182927] remoteproc remoteproc1: remote processor 55020000.ipu is now up
[    9.256599] remoteproc remoteproc0: remote processor 58820000.ipu is now up

Any suggestions?

Thanks,
Matt McKee

  • Can someone from TI detail which package(s) govern the instantiation of /dev/rpmsg-dce? Our tisdk-rootfs-image includes ipumm-fw and libdce1. Are we missing anything? Should I be looking for anything in dmesg?

  • Matt,

    Sorry for the delay...I am escalating internally.

  • Hello Matt,

    Using PSDK6.0, I was not able to replicate your errors. However, after removing the "/lib/firmware/dra7-ipu2-fw.xem4" from the filesystem, I saw the same errors on the AM57EVM. By default, the firmware is already installed in the filesystem provided by TI. Please refer to the following thread for building the IPU firmware through Yocto.

    Regards,
    Krunal

  • Hi Krunal,

    Thank you for your response. With it I was able to isolate the issue to a reorganization of the reserved memory blocks in the Linux device tree files. I made these changes to better support a 512MiB population option. If I change the location of the ipu2_memory_region, remoteproc will load dra7-ipu2-fw.xem4 successfully but /dev/rpmsg-dce will not instantiate with no errors reported in dmesg.

    Can you help me identify what I need to modify in the ipumm-fw package and/or source to support a migrated ipu2 memory region? Can you confirm whether this issue will exhibit in other IPU or DSP firmwares if their reserved memory regions are moved?

    Thanks,
    Matt McKee

  • Hi Matt,

    With regards to the reserved memory regions, could you please share what changes you have made in the device tree files? 

    Regards,
    Krunal

  • Hi Krunal,

    I took 512MiB after memory base offset (0x A000 0000) and subtracted 16MiB (0x 100 0000) for the LISA map and aligned the memory regions from there:

    1c1
    < ipu2_memory_region: ipu2-memory@95800000 {
    ---
    > ipu2_memory_region: ipu2-memory@9b800000 {
    3c3
    < 	reg = <0x0 0x95800000 0x0 0x3800000>;
    ---
    > 	reg = <0x0 0x9b800000 0x0 0x3800000>;
    8c8
    < dsp1_memory_region: dsp1-memory@99000000 {
    ---
    > dsp1_memory_region: dsp1-memory@97800000 {
    10c10
    < 	reg = <0x0 0x99000000 0x0 0x4000000>;
    ---
    > 	reg = <0x0 0x97800000 0x0 0x4000000>;
    15c15
    < ipu1_memory_region: ipu1-memory@9d000000 {
    ---
    > ipu1_memory_region: ipu1-memory@95800000 {
    17c17
    < 	reg = <0x0 0x9d000000 0x0 0x2000000>;
    ---
    > 	reg = <0x0 0x95800000 0x0 0x2000000>;
    22c22
    < dsp2_memory_region: dsp2-memory@9f000000 {
    ---
    > dsp2_memory_region: dsp2-memory@95000000 {
    24c24
    < 	reg = <0x0 0x9f000000 0x0 0x800000>;
    ---
    > 	reg = <0x0 0x95000000 0x0 0x800000>;
    28d27
    < 

    Thanks,
    Matt McKee

  • I have now modified IPU_MEM_IPC_DATA and PHYS_MEM_IPC_VRING in ipumm-fw file platform/ti/dce/baseimage/custom_rsc_table_vayu_ipu.h to match the DSP2 and IPU2 memory region changes in the DTS files. Remoteproc fails to load this new firmware with a "remoteproc remoteproc1: erroneous trace resource entry" error. It seems that I likely need to make changes elsewhere in ipumm-fw or perhaps in other TI-RTOS components used to build the ipumm-fw. I'm not sure where to dig next so any suggestions on where to look would be greatly appreciated.

    Thanks,
    Matt McKee

  • Figured it out. I neglected to update the IPU2 memory map in build/config.bld. Now /dev/rpmsg-dce shows up as expected.

    Can you confirm that I will not need to make changes in other firmwares to accommodate changes in DTS memory regions? Right now we have no visible failures related to dsp1, ipu1, and dsp2, but would appreciate the expert opinion(s).

    Thanks,
    Matt McKee

  • Hi Matt,

    Your changes sound correct. The config.bld, resource table, and dts are the three files that need to be modified to match when updating the memory map. 

    For future reference, the following resources help explain this.

    http://software-dl.ti.com/processor-sdk-linux/esd/docs/latest/linux/Foundational_Components_IPC.html#ipc-for-am57xx

    http://www.ti.com/lit/an/sprac60/sprac60.pdf

    Regards,
    Sahin