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.

DRA726: ipu and dsp error messages

Part Number: DRA726
Other Parts Discussed in Thread: SYSBIOS

I am working on some code for 3 external CAN device from Microchip. I use Linux for the internal 2 CAN.

The reason for using M4 is that I do not have hardware interrupt connected and was doing polling in my kernel module.

It works fine on Linux until I need to receive many messages.

First I need to test buffer access between the processors. I use an example program ex02_messageq as modified by another TI customer

I modified his code to remove the part about dsp2 since there is not such thing on the dra726

First the code changes (I omit the dsp2 and ipu2 removed directories in the patch) :

------------------------------------------------------------------------------------------------------------------------

diff -rNuw ex02_messageq/dsp1/Dsp1.cfg my_ex02_messageq/dsp1/Dsp1.cfg
--- ex02_messageq/dsp1/Dsp1.cfg    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/dsp1/Dsp1.cfg    2020-11-18 10:47:02.390406919 -0500
@@ -61,6 +61,10 @@
 var BIOS        = xdc.useModule('ti.sysbios.BIOS');
 BIOS.addUserStartupFunction('&IpcMgr_ipcStartup');
 
+/* Override the default resource table to add CMEM */
+var Resource = xdc.useModule('ti.ipc.remoteproc.Resource');
+Resource.customTable = true;
+
 /*
  *  ======== SYS/BIOS Configuration ========
  */
diff -rNuw ex02_messageq/dsp1/MainDsp1.c my_ex02_messageq/dsp1/MainDsp1.c
--- ex02_messageq/dsp1/MainDsp1.c    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/dsp1/MainDsp1.c    2020-11-18 10:47:02.390406919 -0500
@@ -47,6 +47,8 @@
 #include <ti/sysbios/BIOS.h>
 #include <ti/sysbios/knl/Task.h>
 
+#include "rsc_table_dsp.h"
+
 /* local header files */
 #include "Server.h"
 
diff -rNuw ex02_messageq/dsp1/makefile my_ex02_messageq/dsp1/makefile
--- ex02_messageq/dsp1/makefile    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/dsp1/makefile    2020-11-18 10:47:02.390406919 -0500
@@ -51,7 +51,6 @@
 
 all: debug release
 
-
 debug:
     $(MAKE) PROFILE=debug PROCLIST="$(PROCLIST)" server_dsp1.x
 
@@ -91,14 +90,6 @@
     @$(MKDIR) $(EXEC_DIR)/release
     $(CP) bin/release/server_dsp1.xe66 $(EXEC_DIR)/release
 
-install_rov:
-    @$(ECHO) "#"
-    @$(ECHO) "# Making $@ ..."
-    @$(MKDIR) $(EXEC_DIR)/debug
-    $(CP) bin/debug/configuro/package/cfg/Dsp1_pe66.rov.xs $(EXEC_DIR)/debug
-    @$(MKDIR) $(EXEC_DIR)/release
-    $(CP) bin/release/configuro/package/cfg/Dsp1_pe66.rov.xs $(EXEC_DIR)/release
-
 help:
     @$(ECHO) "make                   # build executable"
     @$(ECHO) "make clean             # clean everything"
diff -rNuw ex02_messageq/dsp1/rsc_table_dsp.h my_ex02_messageq/dsp1/rsc_table_dsp.h
--- ex02_messageq/dsp1/rsc_table_dsp.h    1969-12-31 19:00:00.000000000 -0500
+++ my_ex02_messageq/dsp1/rsc_table_dsp.h    2020-11-18 10:47:02.390406919 -0500
@@ -0,0 +1,330 @@
+/*
+ * Copyright (c) 2012-2014, Texas Instruments Incorporated
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * *  Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ *
+ * *  Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * *  Neither the name of Texas Instruments Incorporated nor the names of
+ *    its contributors may be used to endorse or promote products derived
+ *    from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+ * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+ * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+ * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ *  ======== rsc_table_dsp.h ========
+ *
+ *  Define the resource table entries for all DSP cores. This will be
+ *  incorporated into corresponding base images, and used by the remoteproc
+ *  on the host-side to allocated/reserve resources.
+ *
+ */
+
+#ifndef _RSC_TABLE_DSP_H_
+#define _RSC_TABLE_DSP_H_
+
+#include <ti/ipc/remoteproc/rsc_types.h>
+
+/* DSP Memory Map */
+#define L4_DRA7XX_BASE          0x4A000000
+
+#define L4_PERIPHERAL_L4CFG     (L4_DRA7XX_BASE)
+#define DSP_PERIPHERAL_L4CFG    0x4A000000
+
+#define L4_PERIPHERAL_L4PER1    0x48000000
+#define DSP_PERIPHERAL_L4PER1   0x48000000
+
+#define L4_PERIPHERAL_L4PER2    0x48400000
+#define DSP_PERIPHERAL_L4PER2   0x48400000
+
+#define L4_PERIPHERAL_L4PER3    0x48800000
+#define DSP_PERIPHERAL_L4PER3   0x48800000
+
+#define L4_PERIPHERAL_L4EMU     0x54000000
+#define DSP_PERIPHERAL_L4EMU    0x54000000
+
+#define L3_PERIPHERAL_DMM       0x4E000000
+#define DSP_PERIPHERAL_DMM      0x4E000000
+
+#define L3_TILER_MODE_0_1       0x60000000
+#define DSP_TILER_MODE_0_1      0x60000000
+
+#define L3_TILER_MODE_2         0x70000000
+#define DSP_TILER_MODE_2        0x70000000
+
+#define L3_TILER_MODE_3         0x78000000
+#define DSP_TILER_MODE_3        0x78000000
+
+#define DSP_MEM_TEXT            0x95000000
+/* Co-locate alongside TILER region for easier flushing */
+#define DSP_MEM_IOBUFS          0x80000000
+#define DSP_MEM_DATA            0x95100000
+#define DSP_MEM_HEAP            0x95200000
+
+#define DSP_MEM_IPC_DATA        0x9F000000
+#define DSP_MEM_IPC_VRING       0xB0000000
+#define DSP_MEM_RPMSG_VRING0    0xB0000000
+#define DSP_MEM_RPMSG_VRING1    0xB0004000
+#define DSP_MEM_VRING_BUFS0     0xB0040000
+#define DSP_MEM_VRING_BUFS1     0xB0080000
+
+#define DSP_MEM_IPC_VRING_SIZE  SZ_1M
+#define DSP_MEM_IPC_DATA_SIZE   SZ_1M
+#define DSP_MEM_TEXT_SIZE       SZ_1M
+#define DSP_MEM_DATA_SIZE       SZ_1M
+#define DSP_MEM_HEAP_SIZE       (SZ_1M * 3)
+#define DSP_MEM_IOBUFS_SIZE     (SZ_1M * 90)
+
+#define DSP_CMEM_IOBUFS         0x85000000
+#define PHYS_CMEM_IOBUFS        0xA0000000
+#define DSP_CMEM_IOBUFS_SIZE    (SZ_1M * 192)
+
+#define VAYU_DSP_1
+/*
+ * Assign fixed RAM addresses to facilitate a fixed MMU table.
+ */
+/* See CMA BASE addresses in Linux side: arch/arm/mach-omap2/remoteproc.c */
+#if defined (VAYU_DSP_1)
+#define PHYS_MEM_IPC_VRING      0x99000000
+#elif defined (VAYU_DSP_2)
+#define PHYS_MEM_IPC_VRING      0x9F000000
+#endif
+
+/* Need to be identical to that of IPU */
+#define PHYS_MEM_IOBUFS         0xBA300000
+
+/*
+ * Sizes of the virtqueues (expressed in number of buffers supported,
+ * and must be power of 2)
+ */
+#define DSP_RPMSG_VQ0_SIZE      256
+#define DSP_RPMSG_VQ1_SIZE      256
+
+/* flip up bits whose indices represent features we support */
+#define RPMSG_DSP_C0_FEATURES         1
+
+struct my_resource_table {
+    struct resource_table base;
+
+    UInt32 offset[19];  /* Should match 'num' in actual definition */
+
+    /* rpmsg vdev entry */
+    struct fw_rsc_vdev rpmsg_vdev;
+    struct fw_rsc_vdev_vring rpmsg_vring0;
+    struct fw_rsc_vdev_vring rpmsg_vring1;
+
+    /* text carveout entry */
+    struct fw_rsc_carveout text_cout;
+
+    /* data carveout entry */
+    struct fw_rsc_carveout data_cout;
+
+    /* heap carveout entry */
+    struct fw_rsc_carveout heap_cout;
+
+    /* ipcdata carveout entry */
+    struct fw_rsc_carveout ipcdata_cout;
+
+    /* trace entry */
+    struct fw_rsc_trace trace;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem0;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem1;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem2;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem3;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem4;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem5;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem6;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem7;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem8;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem9;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem10;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem11;
+};
+
+extern char ti_trace_SysMin_Module_State_0_outbuf__A;
+#define TRACEBUFADDR (UInt32)&ti_trace_SysMin_Module_State_0_outbuf__A
+
+#pragma DATA_SECTION(ti_ipc_remoteproc_ResourceTable, ".resource_table")
+#pragma DATA_ALIGN(ti_ipc_remoteproc_ResourceTable, 4096)
+
+struct my_resource_table ti_ipc_remoteproc_ResourceTable = {
+    1,      /* we're the first version that implements this */
+    18,     /* number of entries in the table */
+    0, 0,   /* reserved, must be zero */
+    /* offsets to entries */
+    {
+        offsetof(struct my_resource_table, rpmsg_vdev),
+        offsetof(struct my_resource_table, text_cout),
+        offsetof(struct my_resource_table, data_cout),
+        offsetof(struct my_resource_table, heap_cout),
+        offsetof(struct my_resource_table, ipcdata_cout),
+        offsetof(struct my_resource_table, trace),
+        offsetof(struct my_resource_table, devmem0),
+        offsetof(struct my_resource_table, devmem1),
+        offsetof(struct my_resource_table, devmem2),
+        offsetof(struct my_resource_table, devmem3),
+        offsetof(struct my_resource_table, devmem4),
+        offsetof(struct my_resource_table, devmem5),
+        offsetof(struct my_resource_table, devmem6),
+        offsetof(struct my_resource_table, devmem7),
+        offsetof(struct my_resource_table, devmem8),
+        offsetof(struct my_resource_table, devmem9),
+        offsetof(struct my_resource_table, devmem10),
+        offsetof(struct my_resource_table, devmem11),
+    },
+
+    /* rpmsg vdev entry */
+    {
+        TYPE_VDEV, VIRTIO_ID_RPMSG, 0,
+        RPMSG_DSP_C0_FEATURES, 0, 0, 0, 2, { 0, 0 },
+        /* no config data */
+    },
+    /* the two vrings */
+    { DSP_MEM_RPMSG_VRING0, 4096, DSP_RPMSG_VQ0_SIZE, 1, 0 },
+    { DSP_MEM_RPMSG_VRING1, 4096, DSP_RPMSG_VQ1_SIZE, 2, 0 },
+
+    {
+        TYPE_CARVEOUT,
+        DSP_MEM_TEXT, 0,
+        DSP_MEM_TEXT_SIZE, 0, 0, "DSP_MEM_TEXT",
+    },
+
+    {
+        TYPE_CARVEOUT,
+        DSP_MEM_DATA, 0,
+        DSP_MEM_DATA_SIZE, 0, 0, "DSP_MEM_DATA",
+    },
+
+    {
+        TYPE_CARVEOUT,
+        DSP_MEM_HEAP, 0,
+        DSP_MEM_HEAP_SIZE, 0, 0, "DSP_MEM_HEAP",
+    },
+
+    {
+        TYPE_CARVEOUT,
+        DSP_MEM_IPC_DATA, 0,
+        DSP_MEM_IPC_DATA_SIZE, 0, 0, "DSP_MEM_IPC_DATA",
+    },
+
+    {
+        TYPE_TRACE, TRACEBUFADDR, 0x8000, 0, "trace:dsp",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_MEM_IPC_VRING, PHYS_MEM_IPC_VRING,
+        DSP_MEM_IPC_VRING_SIZE, 0, 0, "DSP_MEM_IPC_VRING",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_MEM_IOBUFS, PHYS_MEM_IOBUFS,
+        DSP_MEM_IOBUFS_SIZE, 0, 0, "DSP_MEM_IOBUFS",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_TILER_MODE_0_1, L3_TILER_MODE_0_1,
+        SZ_256M, 0, 0, "DSP_TILER_MODE_0_1",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_TILER_MODE_2, L3_TILER_MODE_2,
+        SZ_128M, 0, 0, "DSP_TILER_MODE_2",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_TILER_MODE_3, L3_TILER_MODE_3,
+        SZ_128M, 0, 0, "DSP_TILER_MODE_3",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_PERIPHERAL_L4CFG, L4_PERIPHERAL_L4CFG,
+        SZ_16M, 0, 0, "DSP_PERIPHERAL_L4CFG",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_PERIPHERAL_L4PER1, L4_PERIPHERAL_L4PER1,
+        SZ_2M, 0, 0, "DSP_PERIPHERAL_L4PER1",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_PERIPHERAL_L4PER2, L4_PERIPHERAL_L4PER2,
+        SZ_4M, 0, 0, "DSP_PERIPHERAL_L4PER2",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_PERIPHERAL_L4PER3, L4_PERIPHERAL_L4PER3,
+        SZ_8M, 0, 0, "DSP_PERIPHERAL_L4PER3",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_PERIPHERAL_L4EMU, L4_PERIPHERAL_L4EMU,
+        SZ_16M, 0, 0, "DSP_PERIPHERAL_L4EMU",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_PERIPHERAL_DMM, L3_PERIPHERAL_DMM,
+        SZ_1M, 0, 0, "DSP_PERIPHERAL_DMM",
+    },
+
+    {
+        TYPE_DEVMEM,
+        DSP_CMEM_IOBUFS, PHYS_CMEM_IOBUFS,
+        DSP_CMEM_IOBUFS_SIZE, 0, 0, "DSP_CMEM_IOBUFS",
+    },
+};
+
+#endif /* _RSC_TABLE_VAYU_DSP_H_ */
diff -rNuw ex02_messageq/dsp1/Server.c my_ex02_messageq/dsp1/Server.c
--- ex02_messageq/dsp1/Server.c    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/dsp1/Server.c    2020-11-18 10:47:02.390406919 -0500
@@ -54,6 +54,7 @@
 
 #include <ti/sysbios/BIOS.h>
 #include <ti/sysbios/knl/Task.h>
+#include <ti/ipc/remoteproc/Resource.h>
 
 /* local header files */
 #include "../shared/AppCommon.h"
@@ -129,6 +130,11 @@
     Bool                running = TRUE;
     App_Msg *           msg;
     MessageQ_QueueId    queId;
+    Int                 i, j;
+    uint8_t *           data_ptr;
+    UInt32              virtualAddrIn[1];
+    UInt32              virtualAddrOut;
+    uint32_t            dataXor;
 
     Log_print0(Diags_ENTRY | Diags_INFO, "--> Server_exec:");
 
@@ -142,6 +148,28 @@
             goto leave;
         }
 
+        for (i = 0; i < 1; i++) {
+            if(Resource_physToVirt(msg->dataInPhys[i], &virtualAddrIn[i]) != Resource_S_SUCCESS) {
+                Log_print1(Diags_INFO, "Server_exec: not found resource for phys 0x%x\n",
+                                        msg->dataInPhys[i]);
+                continue;
+            }
+            Log_print4(Diags_INFO, "Server_exec: addrPhys[%d] = 0x%x addrIn[%d]=0x%x",
+                       i, msg->dataInPhys[i], i, virtualAddrIn[i]);
+
+            data_ptr = (uint8_t*)virtualAddrIn[i];
+
+            dataXor = 0;
+
+            for (j = 0; j < msg->dataByteSize; j++) {
+                 dataXor ^= data_ptr[j];
+            }
+
+            Log_print2(Diags_INFO, "Server_exec: xorIn[%d]=0x%x", i, dataXor);
+        }
+
+        msg->outXor = dataXor;
+
         if (msg->cmd == App_CMD_SHUTDOWN) {
             running = FALSE;
         }
@@ -152,6 +180,7 @@
         /* send message back */
         queId = MessageQ_getReplyQueue(msg); /* type-cast not needed */
         MessageQ_put(queId, (MessageQ_Msg)msg);
+
     } /* while (running) */
 
 leave:
diff -rNuw ex02_messageq/host/App.c my_ex02_messageq/host/App.c
--- ex02_messageq/host/App.c    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/host/App.c    2020-11-18 10:47:02.506408592 -0500
@@ -43,6 +43,9 @@
 #include <ti/ipc/Std.h>
 #include <ti/ipc/MessageQ.h>
 
+/* cmem header file */
+#include <ti/cmem.h>
+
 /* local header files */
 #include "../shared/AppCommon.h"
 #include "App.h"
@@ -59,6 +62,8 @@
 static App_Module Module;
 
 
+#define PAYLOADSIZE        (0x100000 * 16) // 16MB
+
 /*
  *  ======== App_create ========
  */
@@ -71,6 +76,16 @@
 
     printf("--> App_create:\n");
 
+    status = CMEM_init();
+
+    if (status < 0) {
+        printf("CMEM_init failed\n");
+        goto leave;
+    }
+    else {
+        printf("CMEM_init success\n");
+    }
+
     /* setting default values */
     Module.hostQue = NULL;
     Module.slaveQue = MessageQ_INVALIDMESSAGEQ;
@@ -143,15 +158,16 @@
  */
 Int App_exec(Void)
 {
-    Int         status;
-    Int         i;
+    Int         status = 0;
+    Int         i, j;
     App_Msg *   msg;
+    CMEM_AllocParams        cmemAttrs;
 
-    printf("--> App_exec:\n");
+    cmemAttrs.type = CMEM_HEAP;
+    cmemAttrs.flags =  CMEM_NONCACHED;
+    cmemAttrs.alignment = 0;
 
-    /* fill process pipeline */
-    for (i = 1; i <= 3; i++) {
-        printf("App_exec: sending message %d\n", i);
+    printf("--> App_exec:\n");
 
         /* allocate message */
         msg = (App_Msg *)MessageQ_alloc(Module.heapId, Module.msgSize);
@@ -161,61 +177,36 @@
             goto leave;
         }
 
-        /* set the return address in the message header */
-        MessageQ_setReplyQueue(Module.hostQue, (MessageQ_Msg)msg);
-
-        /* fill in message payload */
-        msg->cmd = App_CMD_NOP;
-
-        /* send message */
-        MessageQ_put(Module.slaveQue, (MessageQ_Msg)msg);
-    }
-
-    /* process steady state (keep pipeline full) */
-    for (i = 4; i <= 15; i++) {
+    msg->dataByteSize = PAYLOADSIZE;
 
-        /* wait for return message */
-        status = MessageQ_get(Module.hostQue, (MessageQ_Msg *)&msg,
-            MessageQ_FOREVER);
-
-        if (status < 0) {
+    for (i = 0; i < 1; i++) {
+        msg->dataIn[i] = CMEM_allocPool(CMEM_getPool(PAYLOADSIZE), &cmemAttrs);
+         if (msg->dataIn[i] == NULL) {
+             printf("CMEM_alloc() failed (returned NULL)\n");
+             status = -1;
             goto leave;
         }
+         msg->dataInPhys[i] = CMEM_getPhys(msg->dataIn[i]);
 
-        /* extract message payload */
-
-        /* free the message */
-        MessageQ_free((MessageQ_Msg)msg);
+         printf("user: %p phys: 0x%x\n", msg->dataIn[i], msg->dataInPhys[i]);
 
-        printf("App_exec: message received, sending message %d\n", i);
+         uint8_t *dataIn = (uint8_t*)msg->dataIn[i];
 
-        /* allocate message */
-        msg = (App_Msg *)MessageQ_alloc(Module.heapId, Module.msgSize);
+         msg->inXor[i] = 0;
 
-        if (msg == NULL) {
-            status = -1;
-            goto leave;
+         for (j = 0; j < PAYLOADSIZE; j++) {
+             dataIn[j] = rand();
+             msg->inXor[i] ^= dataIn[j];
+         }
         }
 
         /* set the return address in the message header */
         MessageQ_setReplyQueue(Module.hostQue, (MessageQ_Msg)msg);
 
         /* fill in message payload */
-        if (i == 15) {
-            /* Last message will tell the slave to shutdown */
             msg->cmd = App_CMD_SHUTDOWN;
-        }
-        else {
-            msg->cmd = App_CMD_NOP;
-        }
 
-        /* send message */
         MessageQ_put(Module.slaveQue, (MessageQ_Msg)msg);
-    }
-
-    /* drain process pipeline */
-    for (i = 1; i <= 3; i++) {
-        printf("App_exec: message received\n");
 
         /* wait for return message */
         status = MessageQ_get(Module.hostQue, (MessageQ_Msg *)&msg,
@@ -225,11 +216,11 @@
             goto leave;
         }
 
-        /* extract message payload */
+    printf("The size of data is %d MB\n", PAYLOADSIZE / 1024 / 1024);
+    printf("slave data xor result 0x%x, host(arm) 0x%x\n", msg->outXor, msg->inXor[0]);
 
-        /* free the message */
+    CMEM_free(msg->dataIn[0], &cmemAttrs);
         MessageQ_free((MessageQ_Msg)msg);
-    }
 
 leave:
     printf("<-- App_exec: %d\n", status);
diff -rNuw ex02_messageq/host/configure.ac my_ex02_messageq/host/configure.ac
--- ex02_messageq/host/configure.ac    1969-12-31 19:00:00.000000000 -0500
+++ my_ex02_messageq/host/configure.ac    2020-11-18 10:47:02.506408592 -0500
@@ -0,0 +1,37 @@
+#                                               -*- Autoconf -*-
+# Process this file with autoconf to produce a configure script.
+
+AC_PREREQ([2.69])
+AC_INIT([app_host],[1.0])
+AC_CONFIG_SRCDIR([App.c])
+AM_INIT_AUTOMAKE([subdir-objects])
+AC_CONFIG_HEADERS([config.h])
+AC_CONFIG_MACRO_DIR([m4])
+AC_PREFIX_DEFAULT(/usr)
+
+# Checks for programs.
+AC_PROG_CXX
+AC_PROG_AWK
+AC_PROG_CC
+AC_PROG_CPP
+AC_PROG_INSTALL
+AC_PROG_LN_S
+AC_PROG_MAKE_SET
+
+LT_INIT
+
+# Checks for libraries.
+
+# Checks for header files.
+AC_CHECK_HEADERS([stdlib.h string.h sys/time.h])
+
+# Checks for typedefs, structures, and compiler characteristics.
+AC_TYPE_SIZE_T
+
+# Checks for library functions.
+AC_FUNC_MALLOC
+AC_CHECK_FUNCS([clock_gettime gettimeofday memmove memset])
+
+AC_CONFIG_FILES([Makefile])
+AC_OUTPUT
+
diff -rNuw ex02_messageq/host/makefile my_ex02_messageq/host/makefile
--- ex02_messageq/host/makefile    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/host/makefile    1969-12-31 19:00:00.000000000 -0500
@@ -1,163 +0,0 @@
-#
-#  Copyright (c) 2013-2015 Texas Instruments Incorporated - http://www.ti.com
-#  All rights reserved.
-#
-#  Redistribution and use in source and binary forms, with or without
-#  modification, are permitted provided that the following conditions
-#  are met:
-#
-#  *  Redistributions of source code must retain the above copyright
-#     notice, this list of conditions and the following disclaimer.
-#
-#  *  Redistributions in binary form must reproduce the above copyright
-#     notice, this list of conditions and the following disclaimer in the
-#     documentation and/or other materials provided with the distribution.
-#
-#  *  Neither the name of Texas Instruments Incorporated nor the names of
-#     its contributors may be used to endorse or promote products derived
-#     from this software without specific prior written permission.
-#
-#  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-#  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
-#  THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-#  PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
-#  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
-#  EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
-#  PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
-#  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
-#  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
-#  OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
-#  EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-#
-
-#
-#  ======== Makefile ========
-#
-
-srcs = main_host.c App.c
-
-EXBASE = ..
-include $(EXBASE)/products.mak
--include $(addprefix bin/$(PROFILE)/obj/,$(patsubst %.c,%.ov7A.dep,$(srcs)))
-
-objs = $(addprefix bin/$(PROFILE)/obj/,$(patsubst %.c,%.ov7A,$(srcs)))
-
-ifdef LIBS_STATIC
-libs = libtitransportrpmsg.a \
-       libtiipc.a \
-       libtiipcutils.a
-else
-# Use dynamic or shared libs
-#libs = $(IPC_INSTALL_DIR)/linux/src/api/.libs/libtiipc.so \
-#       $(IPC_INSTALL_DIR)/linux/src/utils/.libs/libtiipcutils.so \
-#       $(IPC_INSTALL_DIR)/linux/src/transport/.libs/libtitransportrpmsg.so
-libs =
-endif
-
-all:
-    @$(ECHO) "#"
-    @$(ECHO) "# Making $@ ..."
-    $(MAKE) PROFILE=debug app_host
-    $(MAKE) PROFILE=release app_host
-
-help:
-    @$(ECHO) "make                  # build executables"
-    @$(ECHO) "make clean            # clean everything"
-
-install:
-    @$(ECHO) "#"
-    @$(ECHO) "# Making $@ ..."
-    @$(MKDIR) $(EXEC_DIR)/debug
-    $(CP) bin/debug/app_host $(EXEC_DIR)/debug
-    @$(MKDIR) $(EXEC_DIR)/release
-    $(CP) bin/release/app_host $(EXEC_DIR)/release
-
-clean::
-    $(RMDIR) bin
-
-
-#
-#  ======== rules ========
-#
-app_host: bin/$(PROFILE)/app_host
-bin/$(PROFILE)/app_host: $(objs) $(libs)
-    @$(ECHO) "#"
-    @$(ECHO) "# Making $@ ..."
-    $(LD) $(LDFLAGS) -o $@ $^ $(LDLIBS)
-
-bin/$(PROFILE)/obj/%.ov7A: %.c
-    @$(ECHO) "#"
-    @$(ECHO) "# Making $@ ..."
-    $(CC) $(CPPFLAGS) $(CFLAGS) -o $@ $<
-
-#  ======== install validation ========
-ifeq (install,$(MAKECMDGOALS))
-ifeq (,$(EXEC_DIR))
-$(error must specify EXEC_DIR)
-endif
-endif
-
-#  ======== toolchain macros ========
-ifndef LINUX_SYSROOT_DIR
-CC = $(TOOLCHAIN_PREFIX)gcc
-AR = $(TOOLCHAIN_PREFIX)ar
-LD = $(TOOLCHAIN_PREFIX)gcc
-CFLAGS =
-CPPFLAGS =
-LDFLAGS = -L$(IPC_INSTALL_DIR)/linux/src/api/.libs/ \
-    -L$(IPC_INSTALL_DIR)/linux/src/utils/.libs \
-    -L$(IPC_INSTALL_DIR)/linux/src/transport/.libs
-else
-LD = $(CC)
-endif
-
-CFLAGS += -c -MD -MF $@.dep
-ARFLAGS = cr
-
-CPPFLAGS += -D_REENTRANT
-
-CFLAGS += -Wall -ffloat-store -fPIC -Wunused -pthread -Dfar= $(CCPROFILE_$(PROFILE)) \
-    -I. -I..
-ifdef LINUX_SYSROOT_DIR
-CFLAGS += -I$(LINUX_SYSROOT_DIR)
-else
-CFLAGS += -I$(IPC_INSTALL_DIR)/linux/include -I$(IPC_INSTALL_DIR)/packages
-endif
-
-LDFLAGS += $(LDPROFILE_$(PROFILE)) -Wall -Wl,-Map=$@.map
-
-LDLIBS = -lpthread -lc -lrt
-ifndef LIBS_STATIC
-LDLIBS +=-ltiipc -ltiipcutils -ltitransportrpmsg
-endif
-CCPROFILE_debug = -ggdb -D DEBUG
-CCPROFILE_release = -O3 -D NDEBUG
-
-LDPROFILE_debug = -ggdb
-LDPROFILE_release = -O3
-
-#  ======== standard macros ========
-ifneq (,$(wildcard $(XDC_INSTALL_DIR)/bin/echo.exe))
-    # use these on Windows
-    CP      = $(XDC_INSTALL_DIR)/bin/cp
-    ECHO    = $(XDC_INSTALL_DIR)/bin/echo
-    MKDIR   = $(XDC_INSTALL_DIR)/bin/mkdir -p
-    RM      = $(XDC_INSTALL_DIR)/bin/rm -f
-    RMDIR   = $(XDC_INSTALL_DIR)/bin/rm -rf
-else
-    # use these on Linux
-    CP      = cp
-    ECHO    = echo
-    MKDIR   = mkdir -p
-    RM      = rm -f
-    RMDIR   = rm -rf
-endif
-
-#  ======== create output directories ========
-ifneq (clean,$(MAKECMDGOALS))
-ifneq (,$(PROFILE))
-ifeq (,$(wildcard bin/$(PROFILE)/obj))
-    $(shell $(MKDIR) -p bin/$(PROFILE)/obj)
-endif
-endif
-endif
diff -rNuw ex02_messageq/host/Makefile.am my_ex02_messageq/host/Makefile.am
--- ex02_messageq/host/Makefile.am    1969-12-31 19:00:00.000000000 -0500
+++ my_ex02_messageq/host/Makefile.am    2020-11-18 10:47:02.506408592 -0500
@@ -0,0 +1,8 @@
+AUTOMAKE_OPTIONS = foreign
+ACLOCAL_AMFLAGS = -I m4
+
+bin_PROGRAMS = app_host
+app_host_SOURCES = App.c main_host.c
+
+AM_LDFLAGS =  -lrt -ltiipc -ltiipcutils -ltitransportrpmsg -lticmem
+
diff -rNuw ex02_messageq/ipu1/Ipu1.cfg my_ex02_messageq/ipu1/Ipu1.cfg
--- ex02_messageq/ipu1/Ipu1.cfg    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/ipu1/Ipu1.cfg    2020-11-18 10:47:02.654410729 -0500
@@ -65,6 +65,10 @@
 var BIOS        = xdc.useModule('ti.sysbios.BIOS');
 BIOS.addUserStartupFunction('&IpcMgr_ipcStartup');
 
+/* Override the default resource table to add CMEM */
+var Resource = xdc.useModule('ti.ipc.remoteproc.Resource');
+Resource.customTable = true;
+
 /*
  *  ======== SYS/BIOS Configuration ========
  */
diff -rNuw ex02_messageq/ipu1/MainIpu1.c my_ex02_messageq/ipu1/MainIpu1.c
--- ex02_messageq/ipu1/MainIpu1.c    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/ipu1/MainIpu1.c    2020-11-18 10:47:02.654410729 -0500
@@ -47,6 +47,8 @@
 #include <ti/sysbios/BIOS.h>
 #include <ti/sysbios/knl/Task.h>
 
+#include "rsc_table_ipu.h"
+
 /* local header files */
 #include "Server.h"
 
diff -rNuw ex02_messageq/ipu1/makefile my_ex02_messageq/ipu1/makefile
--- ex02_messageq/ipu1/makefile    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/ipu1/makefile    2020-11-18 10:47:02.654410729 -0500
@@ -53,13 +53,13 @@
 
 
 debug:
-    $(MAKE) PROFILE=debug PROCLIST="$(PROCLIST)" server_ipu1.x
+    $(MAKE) PROFILE=debug PROCLIST="$(PROCLIST)" dra7-ipu1-fw.x
 
 release:
-    $(MAKE) PROFILE=release PROCLIST="$(PROCLIST)" server_ipu1.x
+    $(MAKE) PROFILE=release PROCLIST="$(PROCLIST)" dra7-ipu1-fw.x
 
-server_ipu1.x: bin/$(PROFILE)/server_ipu1.xem4
-bin/$(PROFILE)/server_ipu1.xem4: $(objs) $(libs) $(CONFIG)/linker.cmd
+dra7-ipu1-fw.x: bin/$(PROFILE)/dra7-ipu1-fw.xem4
+bin/$(PROFILE)/dra7-ipu1-fw.xem4: $(objs) $(libs) $(CONFIG)/linker.cmd
     @$(ECHO) "#"
     @$(ECHO) "# Making $@ ..."
     $(LD) $(LDFLAGS) -o $@ $(objs) \
@@ -88,17 +88,10 @@
     @$(ECHO) "#"
     @$(ECHO) "# Making $@ ..."
     @$(MKDIR) $(EXEC_DIR)/debug
-    $(CP) bin/debug/server_ipu1.xem4 $(EXEC_DIR)/debug
+    $(CP) bin/debug/dra7-ipu1-fw.xem4 $(EXEC_DIR)/debug
     @$(MKDIR) $(EXEC_DIR)/release
-    $(CP) bin/release/server_ipu1.xem4 $(EXEC_DIR)/release
+    $(CP) bin/release/dra7-ipu1-fw.xem4 $(EXEC_DIR)/release
 
-install_rov:
-    @$(ECHO) "#"
-    @$(ECHO) "# Making $@ ..."
-    @$(MKDIR) $(EXEC_DIR)/debug
-    $(CP) bin/debug/configuro/package/cfg/Ipu1_pem4.rov.xs $(EXEC_DIR)/debug
-    @$(MKDIR) $(EXEC_DIR)/release
-    $(CP) bin/release/configuro/package/cfg/Ipu1_pem4.rov.xs $(EXEC_DIR)/release
 
 help:
     @$(ECHO) "make                   # build executable"
diff -rNuw ex02_messageq/ipu1/rsc_table_ipu.h my_ex02_messageq/ipu1/rsc_table_ipu.h
--- ex02_messageq/ipu1/rsc_table_ipu.h    1969-12-31 19:00:00.000000000 -0500
+++ my_ex02_messageq/ipu1/rsc_table_ipu.h    2020-11-18 10:47:02.654410729 -0500
@@ -0,0 +1,357 @@
+/*
+ * Copyright (c) 2012-2014, Texas Instruments Incorporated
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * *  Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ *
+ * *  Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * *  Neither the name of Texas Instruments Incorporated nor the names of
+ *    its contributors may be used to endorse or promote products derived
+ *    from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+ * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+ * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+ * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+ *  ======== rsc_table_ipu.h ========
+ *
+ *  Define the resource table entries for all IPU cores. This will be
+ *  incorporated into corresponding base images, and used by the remoteproc
+ *  on the host-side to allocated/reserve resources.
+ *
+ */
+
+#ifndef _RSC_TABLE_IPU_H_
+#define _RSC_TABLE_IPU_H_
+
+#include <ti/ipc/remoteproc/rsc_types.h>
+
+/* IPU Memory Map */
+#define L4_DRA7XX_BASE          0x4A000000
+
+/* L4_CFG & L4_WKUP */
+#define L4_PERIPHERAL_L4CFG     (L4_DRA7XX_BASE)
+#define IPU_PERIPHERAL_L4CFG    0x6A000000
+
+#define L4_PERIPHERAL_L4PER1    0x48000000
+#define IPU_PERIPHERAL_L4PER1   0x68000000
+
+#define L4_PERIPHERAL_L4PER2    0x48400000
+#define IPU_PERIPHERAL_L4PER2   0x68400000
+
+#define L4_PERIPHERAL_L4PER3    0x48800000
+#define IPU_PERIPHERAL_L4PER3   0x68800000
+
+#define L4_PERIPHERAL_L4EMU     0x54000000
+#define IPU_PERIPHERAL_L4EMU    0x74000000
+
+#define L3_PERIPHERAL_DMM       0x4E000000
+#define IPU_PERIPHERAL_DMM      0x6E000000
+
+#define L3_IVAHD_CONFIG         0x5A000000
+#define IPU_IVAHD_CONFIG        0x7A000000
+
+#define L3_IVAHD_SL2            0x5B000000
+#define IPU_IVAHD_SL2           0x7B000000
+
+#define L3_TILER_MODE_0_1       0x60000000
+#define IPU_TILER_MODE_0_1      0xA0000000
+
+#define L3_TILER_MODE_2         0x70000000
+#define IPU_TILER_MODE_2        0xB0000000
+
+#define L3_TILER_MODE_3         0x78000000
+#define IPU_TILER_MODE_3        0xB8000000
+
+#define IPU_MEM_TEXT            0x0
+#define IPU_MEM_DATA            0x80000000
+
+#define IPU_MEM_IOBUFS          0x90000000
+
+#define IPU_MEM_IPC_DATA        0x9F000000
+#define IPU_MEM_IPC_VRING       0x60000000
+#define IPU_MEM_RPMSG_VRING0    0x60000000
+#define IPU_MEM_RPMSG_VRING1    0x60004000
+#define IPU_MEM_VRING_BUFS0     0x60040000
+#define IPU_MEM_VRING_BUFS1     0x60080000
+
+#define IPU_MEM_IPC_VRING_SIZE  SZ_1M
+#define IPU_MEM_IPC_DATA_SIZE   SZ_1M
+
+#define VAYU_IPU_1
+
+#if defined(VAYU_IPU_1)
+#define IPU_MEM_TEXT_SIZE       (SZ_1M)
+#elif defined(VAYU_IPU_2)
+#define IPU_MEM_TEXT_SIZE       (SZ_1M * 6)
+#endif
+
+#if defined(VAYU_IPU_1)
+#define IPU_MEM_DATA_SIZE       (SZ_1M * 5)
+#elif defined(VAYU_IPU_2)
+#define IPU_MEM_DATA_SIZE       (SZ_1M * 48)
+#endif
+
+#define IPU_MEM_IOBUFS_SIZE     (SZ_1M * 90)
+
+/*
+ * Assign fixed RAM addresses to facilitate a fixed MMU table.
+ * PHYS_MEM_IPC_VRING & PHYS_MEM_IPC_DATA MUST be together.
+ */
+/* See CMA BASE addresses in Linux side: arch/arm/mach-omap2/remoteproc.c */
+#if defined(VAYU_IPU_1)
+#define PHYS_MEM_IPC_VRING      0x9D000000
+#elif defined (VAYU_IPU_2)
+#define PHYS_MEM_IPC_VRING      0x95800000
+#endif
+
+#define IPU_CMEM_IOBUFS         0x85000000
+#define PHYS_CMEM_IOBUFS        0xA0000000
+#define IPU_CMEM_IOBUFS_SIZE    (SZ_1M * 192)
+
+#define PHYS_MEM_IOBUFS         0xBA300000
+
+/*
+ * Sizes of the virtqueues (expressed in number of buffers supported,
+ * and must be power of 2)
+ */
+#define IPU_RPMSG_VQ0_SIZE      256
+#define IPU_RPMSG_VQ1_SIZE      256
+
+/* flip up bits whose indices represent features we support */
+#define RPMSG_IPU_C0_FEATURES   1
+
+struct my_resource_table {
+    struct resource_table base;
+
+    UInt32 offset[19];  /* Should match 'num' in actual definition */
+
+    /* rpmsg vdev entry */
+    struct fw_rsc_vdev rpmsg_vdev;
+    struct fw_rsc_vdev_vring rpmsg_vring0;
+    struct fw_rsc_vdev_vring rpmsg_vring1;
+
+    /* text carveout entry */
+    struct fw_rsc_carveout text_cout;
+
+    /* data carveout entry */
+    struct fw_rsc_carveout data_cout;
+
+    /* ipcdata carveout entry */
+    struct fw_rsc_carveout ipcdata_cout;
+
+    /* trace entry */
+    struct fw_rsc_trace trace;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem0;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem1;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem2;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem3;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem4;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem5;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem6;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem7;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem8;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem9;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem10;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem11;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem12;
+
+    /* devmem entry */
+    struct fw_rsc_devmem devmem13;
+};
+
+extern char ti_trace_SysMin_Module_State_0_outbuf__A;
+#define TRACEBUFADDR (UInt32)&ti_trace_SysMin_Module_State_0_outbuf__A
+
+#pragma DATA_SECTION(ti_ipc_remoteproc_ResourceTable, ".resource_table")
+#pragma DATA_ALIGN(ti_ipc_remoteproc_ResourceTable, 4096)
+
+struct my_resource_table ti_ipc_remoteproc_ResourceTable = {
+    1,      /* we're the first version that implements this */
+    19,     /* number of entries in the table */
+    0, 0,   /* reserved, must be zero */
+    /* offsets to entries */
+    {
+        offsetof(struct my_resource_table, rpmsg_vdev),
+        offsetof(struct my_resource_table, text_cout),
+        offsetof(struct my_resource_table, data_cout),
+        offsetof(struct my_resource_table, ipcdata_cout),
+        offsetof(struct my_resource_table, trace),
+        offsetof(struct my_resource_table, devmem0),
+        offsetof(struct my_resource_table, devmem1),
+        offsetof(struct my_resource_table, devmem2),
+        offsetof(struct my_resource_table, devmem3),
+        offsetof(struct my_resource_table, devmem4),
+        offsetof(struct my_resource_table, devmem5),
+        offsetof(struct my_resource_table, devmem6),
+        offsetof(struct my_resource_table, devmem7),
+        offsetof(struct my_resource_table, devmem8),
+        offsetof(struct my_resource_table, devmem9),
+        offsetof(struct my_resource_table, devmem10),
+        offsetof(struct my_resource_table, devmem11),
+        offsetof(struct my_resource_table, devmem12),
+        offsetof(struct my_resource_table, devmem13),
+    },
+
+    /* rpmsg vdev entry */
+    {
+        TYPE_VDEV, VIRTIO_ID_RPMSG, 0,
+        RPMSG_IPU_C0_FEATURES, 0, 0, 0, 2, { 0, 0 },
+        /* no config data */
+    },
+    /* the two vrings */
+    { IPU_MEM_RPMSG_VRING0, 4096, IPU_RPMSG_VQ0_SIZE, 1, 0 },
+    { IPU_MEM_RPMSG_VRING1, 4096, IPU_RPMSG_VQ1_SIZE, 2, 0 },
+
+    {
+        TYPE_CARVEOUT,
+        IPU_MEM_TEXT, 0,
+        IPU_MEM_TEXT_SIZE, 0, 0, "IPU_MEM_TEXT",
+    },
+
+    {
+        TYPE_CARVEOUT,
+        IPU_MEM_DATA, 0,
+        IPU_MEM_DATA_SIZE, 0, 0, "IPU_MEM_DATA",
+    },
+
+    {
+        TYPE_CARVEOUT,
+        IPU_MEM_IPC_DATA, 0,
+        IPU_MEM_IPC_DATA_SIZE, 0, 0, "IPU_MEM_IPC_DATA",
+    },
+
+    {
+        TYPE_TRACE, TRACEBUFADDR, 0x8000, 0, "trace:sysm3",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_MEM_IPC_VRING, PHYS_MEM_IPC_VRING,
+        IPU_MEM_IPC_VRING_SIZE, 0, 0, "IPU_MEM_IPC_VRING",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_MEM_IOBUFS, PHYS_MEM_IOBUFS,
+        IPU_MEM_IOBUFS_SIZE, 0, 0, "IPU_MEM_IOBUFS",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_TILER_MODE_0_1, L3_TILER_MODE_0_1,
+        SZ_256M, 0, 0, "IPU_TILER_MODE_0_1",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_TILER_MODE_2, L3_TILER_MODE_2,
+        SZ_128M, 0, 0, "IPU_TILER_MODE_2",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_TILER_MODE_3, L3_TILER_MODE_3,
+        SZ_128M, 0, 0, "IPU_TILER_MODE_3",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_PERIPHERAL_L4CFG, L4_PERIPHERAL_L4CFG,
+        SZ_16M, 0, 0, "IPU_PERIPHERAL_L4CFG",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_PERIPHERAL_L4PER1, L4_PERIPHERAL_L4PER1,
+        SZ_2M, 0, 0, "IPU_PERIPHERAL_L4PER1",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_PERIPHERAL_L4PER2, L4_PERIPHERAL_L4PER2,
+        SZ_4M, 0, 0, "IPU_PERIPHERAL_L4PER2",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_PERIPHERAL_L4PER3, L4_PERIPHERAL_L4PER3,
+        SZ_8M, 0, 0, "IPU_PERIPHERAL_L4PER3",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_PERIPHERAL_L4EMU, L4_PERIPHERAL_L4EMU,
+        SZ_16M, 0, 0, "IPU_PERIPHERAL_L4EMU",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_IVAHD_CONFIG, L3_IVAHD_CONFIG,
+        SZ_16M, 0, 0, "IPU_IVAHD_CONFIG",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_IVAHD_SL2, L3_IVAHD_SL2,
+        SZ_16M, 0, 0, "IPU_IVAHD_SL2",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_PERIPHERAL_DMM, L3_PERIPHERAL_DMM,
+        SZ_1M, 0, 0, "IPU_PERIPHERAL_DMM",
+    },
+
+    {
+        TYPE_DEVMEM,
+        IPU_CMEM_IOBUFS, PHYS_CMEM_IOBUFS,
+        IPU_CMEM_IOBUFS_SIZE, 0, 0, "IPU_CMEM_IOBUFS",
+    },
+};
+
+#endif /* _RSC_TABLE_VAYU_IPU_H_ */
diff -rNuw ex02_messageq/ipu1/Server.c my_ex02_messageq/ipu1/Server.c
--- ex02_messageq/ipu1/Server.c    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/ipu1/Server.c    2020-11-18 10:47:02.654410729 -0500
@@ -54,6 +54,7 @@
 
 #include <ti/sysbios/BIOS.h>
 #include <ti/sysbios/knl/Task.h>
+#include <ti/ipc/remoteproc/Resource.h>
 
 /* local header files */
 #include "../shared/AppCommon.h"
@@ -129,6 +130,11 @@
     Bool                running = TRUE;
     App_Msg *           msg;
     MessageQ_QueueId    queId;
+    Int                 i, j;
+    uint8_t *           data_ptr;
+    UInt32              virtualAddrIn[1];
+    UInt32              virtualAddrOut;
+    uint32_t            dataXor;
 
     Log_print0(Diags_ENTRY | Diags_INFO, "--> Server_exec:");
 
@@ -142,6 +148,28 @@
             goto leave;
         }
 
+        for (i = 0; i < 1; i++) {
+            if(Resource_physToVirt(msg->dataInPhys[i], &virtualAddrIn[i]) != Resource_S_SUCCESS) {
+                Log_print1(Diags_INFO, "Server_exec: not found resource for phys 0x%x\n",
+                                        msg->dataInPhys[i]);
+                continue;
+            }
+            Log_print4(Diags_INFO, "Server_exec: addrPhys[%d] = 0x%x addrIn[%d]=0x%x",
+                       i, msg->dataInPhys[i], i, virtualAddrIn[i]);
+
+            data_ptr = (uint8_t*)virtualAddrIn[i];
+
+            dataXor = 0;
+
+            for (j = 0; j < msg->dataByteSize; j++) {
+                 dataXor ^= data_ptr[j];
+            }
+
+            Log_print2(Diags_INFO, "Server_exec: xorIn[%d]=0x%x", i, dataXor);
+        }
+
+        msg->outXor = dataXor;
+
         if (msg->cmd == App_CMD_SHUTDOWN) {
             running = FALSE;
         }
@@ -152,6 +180,7 @@
         /* send message back */
         queId = MessageQ_getReplyQueue(msg); /* type-cast not needed */
         MessageQ_put(queId, (MessageQ_Msg)msg);
+
     } /* while (running) */
 
 leave:
diff -rNuw ex02_messageq/makefile my_ex02_messageq/makefile
--- ex02_messageq/makefile    2020-11-18 11:00:52.997251270 -0500
+++ my_ex02_messageq/makefile    2020-11-18 10:47:02.654410729 -0500
@@ -35,10 +35,12 @@
 #
 
 # edit PROCLIST list to control how many executables to build
-PROCLIST = dsp1 dsp2 ipu1 ipu2 host
+PROCLIST = dsp1 ipu1
 
 EXBASE = .
+
 include $(EXBASE)/products.mak
+
 .PHONY: $(PROCLIST)
 
 .PHONY: install
@@ -56,12 +58,7 @@
     @$(ECHO) "make install EXEC_DIR=/.../testbench  # install folder"
 
 # setup install goal
-ifeq ($(filter $(MAKECMDGOALS),install install_rov),$(MAKECMDGOALS))
-ifeq (,$(EXEC_DIR))
 EXEC_DIR=$(CURDIR)/install
-endif
-override EXEC_DIR:=$(EXEC_DIR)/ex02_messageq
-endif
 
 install: $(PROCLIST) $(addsuffix _install,$(PROCLIST))
 $(addsuffix _install,$(PROCLIST)):
@@ -87,20 +84,9 @@
 
 
 #  ======== standard macros ========
-ifneq (,$(wildcard $(XDC_INSTALL_DIR)/xdc.exe))
-    # use these on Windows
-    CP      = $(XDC_INSTALL_DIR)/bin/cp
-    ECHO    = $(XDC_INSTALL_DIR)/bin/echo
-    INSTALL = $(XDC_INSTALL_DIR)/bin/cp
-    MKDIR   = $(XDC_INSTALL_DIR)/bin/mkdir -p
-    RM      = $(XDC_INSTALL_DIR)/bin/rm -f
-    RMDIR   = $(XDC_INSTALL_DIR)/bin/rm -rf
-else
-    # use these on Linux
     CP      = cp
     ECHO    = echo
     INSTALL = install
     MKDIR   = mkdir -p
     RM      = rm -f
     RMDIR   = rm -rf
-endif
diff -rNuw ex02_messageq/products.mak my_ex02_messageq/products.mak
--- ex02_messageq/products.mak    2020-11-18 11:00:52.997251270 -0500
+++ my_ex02_messageq/products.mak    2020-11-18 10:47:02.506408592 -0500
@@ -30,53 +30,31 @@
 #  EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 #
 
-#
-#  ======== products.mak ========
-#
+DEPOT = /home/michel/ti
+SDK_DIR = /home/michel/work/custombus-sdk
 
-# look for other products.mak file to override local settings
-ifneq (,$(wildcard $(EXBASE)/../products.mak))
-include $(EXBASE)/../products.mak
-else
-ifneq (,$(wildcard $(EXBASE)/../../products.mak))
-include $(EXBASE)/../../products.mak
-# Define IPC_INSTALL_DIR since not defined in IPC top-level products.mak
-IPC_INSTALL_DIR = $(word 1,$(subst /examples, examples,$(CURDIR)))
-else
-ifneq (,$(wildcard $(EXBASE)/../../../products.mak))
-# Define IPC_INSTALL_DIR since not defined in IPC top-level products.mak
-IPC_INSTALL_DIR = $(word 1,$(subst /examples, examples,$(CURDIR)))
-include $(EXBASE)/../../../products.mak
-endif
-endif
-endif
-
-# By default, the necessary build variables are found/assigned via
-# ../products.mak or ../../products.mak, included above.  If you want to
-# override these variables, or are building this example without
-# ../products.mak or ../../products.mak, uncomment and assign the variables
-# below.
-
-#DEPOT = _your_depot_folder_
 #### Linux toolchain ####
-#TOOLCHAIN_LONGNAME     = arm-none-linux-gnueabi
-#TOOLCHAIN_INSTALL_DIR  = $(DEPOT)/_your_linux_gcc_toolchain_install_
-#TOOLCHAIN_PREFIX       = $(TOOLCHAIN_INSTALL_DIR)/bin/$(TOOLCHAIN_LONGNAME)-
+TOOLCHAIN_PREFIX = $(SDK_DIR)/sysroots/x86_64-ACTIA-linux/usr/bin/arm-actia-linux-gnueabi/arm-actia-linux-gnueabi-
 
 #### BIOS-side dependencies ####
-#BIOS_INSTALL_DIR       = $(DEPOT)/_your_bios_install_
-#IPC_INSTALL_DIR        = $(DEPOT)/_your_ipc_install_
-#XDC_INSTALL_DIR        = $(DEPOT)/_your_xdctools_install_
+BIOS_INSTALL_DIR = $(DEPOT)/bios_6_52_00_12
+IPC_INSTALL_DIR  = $(DEPOT)/ipc_3_47_01_00
+#XDC_INSTALL_DIR  = $(DEPOT)/xdctools_3_32_02_25_core
+XDC_INSTALL_DIR  = $(DEPOT)/xdctools_3_50_03_33_core
+#XDC_INSTALL_DIR  = $(DEPOT)/xdctools_3_50_07_20_core
+#XDC_INSTALL_DIR  = $(DEPOT)/xdctools_3_51_01_18_core
 
 #### BIOS-side toolchains ####
-#ti.targets.arm.elf.M4  = $(DEPOT)/_your_ti_arm_codegen_install_
-#ti.targets.elf.C66     = $(DEPOT)/_your_ti_dsp_codegen_install_
+ti.targets.arm.elf.M4  = $(DEPOT)/ti-cgt-arm_16.9.3.LTS
+ti.targets.elf.C66     = $(DEPOT)/ti-cgt-c6000_8.2.2
 
 # Use this goal to print your product variables.
 .show:
+    @echo "LINUX_SYSROOT_DIR     = $(TOOLCHAIN_PREFIX)"
     @echo "HOST TOOLCHAIN_PREFIX = $(TOOLCHAIN_PREFIX)"
     @echo "BIOS_INSTALL_DIR      = $(BIOS_INSTALL_DIR)"
     @echo "IPC_INSTALL_DIR       = $(IPC_INSTALL_DIR)"
     @echo "XDC_INSTALL_DIR       = $(XDC_INSTALL_DIR)"
     @echo "ti.targets.arm.elf.M4 = $(ti.targets.arm.elf.M4)"
     @echo "ti.targets.elf.C66    = $(ti.targets.elf.C66)"
+
diff -rNuw ex02_messageq/shared/AppCommon.h my_ex02_messageq/shared/AppCommon.h
--- ex02_messageq/shared/AppCommon.h    2020-11-18 11:00:52.993251224 -0500
+++ my_ex02_messageq/shared/AppCommon.h    2020-11-18 10:47:02.206404268 -0500
@@ -41,6 +41,7 @@
 extern "C" {
 #endif
 
+#include <stdint.h>
 
 /*
  *  ======== Application Configuration ========
@@ -55,6 +56,14 @@
 typedef struct {
     MessageQ_MsgHeader  reserved;
     UInt32              cmd;
+    UInt8               payload[8];
+    void*               dataIn[1];
+    unsigned long       dataInPhys[1];
+    void*               dataOut;
+    unsigned long       dataOutPhys;
+    uint32_t            inXor[1];
+    uint32_t            outXor;
+    size_t              dataByteSize;
 } App_Msg;
 
 #define App_MsgHeapId           0
diff -rNuw ex02_messageq/shared/config.bld my_ex02_messageq/shared/config.bld
--- ex02_messageq/shared/config.bld    2020-11-18 11:00:52.989251172 -0500
+++ my_ex02_messageq/shared/config.bld    2020-11-18 10:47:02.206404268 -0500
@@ -36,7 +36,7 @@
  */
 var Build = xdc.useModule('xdc.bld.BuildEnvironment');
 
-/*  Memory Map for ti.platforms.evmDRA7XX:dsp1 and ti.platforms.evmDRA7XX:dsp2
+/*  Memory Map for ti.platforms.evmDRA7XX:dsp1
  *
  *  --- External Memory ---
  *  Virtual     Physical        Size            Comment
@@ -47,7 +47,15 @@
  *  9F00_0000   9F00_0000     6_0000  ( 384 kB) TRACE_BUF
  *  9F06_0000   9F06_0000     1_0000  (  64 kB) EXC_DATA
  *  9F07_0000   9F07_0000     2_0000  ( 128 kB) PM_DATA (Power mgmt)
+ *  A000_0000   A000_0000    C00_0000 (192 MB)  CMEM Memory (192 MB)
  */
+
+var evmDRA7XX_CMEM = {
+    name: "CMEM", space: "data", access: "RW",
+    base: 0xA0000000, len: 0xC000000,
+    comment: "CMEM Memory (192 MB)"
+};
+
 var evmDRA7XX_ExtMemMapDsp = {
     EXT_CODE: {
         name: "EXT_CODE",
@@ -91,6 +99,13 @@
         space: "data",
         access: "RWX"  /* should this have execute perm? */
     },
+    CMEM: {
+        name: evmDRA7XX_CMEM.name,
+        base: evmDRA7XX_CMEM.base,
+        len:  evmDRA7XX_CMEM.len,
+        space: "data",
+        access: "RW"
+    },
 };
 
 Build.platformTable["ti.platforms.evmDRA7XX:dsp1"] = {
@@ -101,15 +116,12 @@
         [ "TRACE_BUF", evmDRA7XX_ExtMemMapDsp.TRACE_BUF ],
         [ "EXC_DATA", evmDRA7XX_ExtMemMapDsp.EXC_DATA ],
         [ "PM_DATA", evmDRA7XX_ExtMemMapDsp.PM_DATA ],
+        [ evmDRA7XX_CMEM.name, evmDRA7XX_ExtMemMapDsp.CMEM ],
     ],
     codeMemory: "EXT_CODE",
     dataMemory: "EXT_DATA",
     stackMemory: "EXT_DATA",
 };
-Build.platformTable["ti.platforms.evmDRA7XX:dsp2"] =
-    Build.platformTable["ti.platforms.evmDRA7XX:dsp1"];
-
-
 
 /*  Memory Map for ti.platforms.evmDRA7XX:ipu2
  *
@@ -122,6 +134,7 @@
  *  9F00_0000   9F00_0000     6_0000  ( 384 kB) TRACE_BUF
  *  9F06_0000   9F06_0000     1_0000  (  64 kB) EXC_DATA
  *  9F07_0000   9F07_0000     2_0000  ( 128 kB) PM_DATA (Power mgmt)
+ *  A000_0000   A000_0000    C00_0000 (192 MB)  CMEM Memory (192 MB)
  */
 var evmDRA7XX_ExtMemMapIpu2 = {
     EXT_CODE: {
@@ -165,7 +178,16 @@
         len:  0x00020000,
         space: "data",
         access: "RWX"  /* should this have execute perm? */
-    }
+    },
+/*
+    CMEM: {
+        name: evmDRA7XX_CMEM.name,
+        base: evmDRA7XX_CMEM.base,
+        len:  evmDRA7XX_CMEM.len,
+        space: "data",
+        access: "RW"
+    },
+*/
 };
 
 Build.platformTable["ti.platforms.evmDRA7XX:ipu2"] = {
@@ -193,6 +215,7 @@
  *  9F00_0000   9F00_0000     6_0000  ( 384 kB) TRACE_BUF
  *  9F06_0000   9F06_0000     1_0000  (  64 kB) EXC_DATA
  *  9F07_0000   9F07_0000     2_0000  ( 128 kB) PM_DATA (Power mgmt)
+ *  A000_0000   A000_0000    C00_0000 (192 MB)  CMEM Memory (192 MB)
  */
 var evmDRA7XX_ExtMemMapIpu1 = {
     EXT_CODE: {
@@ -236,7 +259,14 @@
         len:  0x00020000,
         space: "data",
         access: "RWX"  /* should this have execute perm? */
-    }
+    },
+    CMEM: {
+        name: evmDRA7XX_CMEM.name,
+        base: evmDRA7XX_CMEM.base,
+        len:  evmDRA7XX_CMEM.len,
+        space: "data",
+        access: "RW"
+    },
 };
 
 Build.platformTable["ti.platforms.evmDRA7XX:ipu1"] = {
@@ -246,7 +276,8 @@
         [ "EXT_HEAP", evmDRA7XX_ExtMemMapIpu1.EXT_HEAP ],
         [ "TRACE_BUF", evmDRA7XX_ExtMemMapIpu1.TRACE_BUF ],
         [ "EXC_DATA", evmDRA7XX_ExtMemMapIpu1.EXC_DATA ],
-        [ "PM_DATA", evmDRA7XX_ExtMemMapIpu1.PM_DATA ]
+        [ "PM_DATA", evmDRA7XX_ExtMemMapIpu1.PM_DATA ],
+        [ evmDRA7XX_CMEM.name, evmDRA7XX_ExtMemMapIpu1.CMEM ],
     ],
     codeMemory: "EXT_CODE",
     dataMemory: "EXT_DATA",

--------------------------------------------

In devicetree

       memory {
                device_type = "memory";
                reg = <0x0 0x80000000
                       0x0 0x40000000>; /* 1GB */
        };

        reserved_mem: reserved-memory {
                #address-cells = <2>;
                #size-cells = <2>;
                ranges;

        ipu2_cma_pool: ipu2_cma@95800000 {
            compatible = "shared-dma-pool";
            reg = <0x0 0x95800000 0x0 0x3800000>;
            reusable;
            status = "okay";
        };

        dsp1_cma_pool: dsp1_cma@99000000 {
            compatible = "shared-dma-pool";
            reg = <0x0 0x99000000 0x0 0x4000000>;
            reusable;
            status = "okay";
        };

        ipu1_cma_pool: ipu1_cma@9d000000 {
            compatible = "shared-dma-pool";
            reg = <0x0 0x9d000000 0x0 0x2000000>;
            reusable;
            status = "okay";
        };

                cmem_block_mem_0: cmem_block_mem@a0000000 {
                        reg = <0x0 0xa0000000 0x0 0x0c000000>;
                        no-map;
                        status = "okay";
                };
        };

        cmem {
                compatible = "ti,cmem";
                #address-cells = <1>;
                #size-cells = <0>;

                #pool-size-cells = <2>;

                status = "okay";

                cmem_block_0: cmem_block@0 {
                        reg = <0>;
                        memory-region = <&cmem_block_mem_0>;
                        cmem-buf-pools = <1 0x0 0x0c000000>;
                };
       };

&mailbox5 {
    status = "okay";
    mbox_ipu1_ipc3x: mbox_ipu1_ipc3x {
        status = "okay";
    };
    mbox_dsp1_ipc3x: mbox_dsp1_ipc3x {
        status = "okay";
    };
};

&mailbox6 {
       status = "okay";
       mbox_ipu2_ipc3x: mbox_ipu2_ipc3x {
       status = "okay";
       };
};

&mmu_ipu1 {
        status = "okay";
};

&mmu_ipu2 {
       status = "okay";
};

&mmu0_dsp1 {
    status = "okay";
};

&mmu1_dsp1 {
    status = "okay";
};

&ipu1 {
        status = "okay";
        memory-region = <&ipu2_cma_pool>;
        mboxes = <&mailbox5 &mbox_ipu1_ipc3x>;
        timers = <&timer11>;
        watchdog-timers = <&timer7>, <&timer8>;
};

&ipu2 {
       status = "okay";
       memory-region = <&ipu2_cma_pool>;
       mboxes = <&mailbox6 &mbox_ipu2_ipc3x>;
       timers = <&timer3>;
       watchdog-timers = <&timer4>, <&timer9>;
};

&dsp1 {
    status = "okay";
    memory-region = <&dsp1_cma_pool>;
    mboxes = <&mailbox5 &mbox_dsp1_ipc3x>;
    timers = <&timer5>;
    watchdog-timers = <&timer10>;
};


----------------------------------------------

I get this with dmesg

root@actia-gd:~#  dmesg | grep ipu
[    0.000000] Reserved memory: initialized node ipu2_cma@95800000, compatible id shared-dma-pool
[    0.000000] Reserved memory: initialized node ipu1_cma@9d000000, compatible id shared-dma-pool
[    3.510951] omap-rproc 58820000.ipu: assigned reserved memory node ipu2_cma@95800000
[    3.532419]  remoteproc0: 58820000.ipu is available
[    3.582496]  remoteproc0: Direct firmware load for dra7-ipu1-fw.xem4 failed with error -2
[    3.595935] omap-rproc 55020000.ipu: assigned reserved memory node ipu2_cma@95800000
[    3.612440]  remoteproc1: 55020000.ipu is available
[    3.662477]  remoteproc1: Direct firmware load for dra7-ipu2-fw.xem4 failed with error -2
[   15.512152]  remoteproc1: powering up 55020000.ipu
[   15.552978]  remoteproc1: Booting fw image dra7-ipu2-fw.xem4, size 3739020
[   15.775976]  remoteproc0: powering up 58820000.ipu
[   15.780795]  remoteproc0: Booting fw image dra7-ipu1-fw.xem4, size 3971716
[   16.001621] omap-rproc 58820000.ipu: dma_alloc_coherent err: 5242880
[   16.798044]  remoteproc1: remote processor 55020000.ipu is now up
root@actia-gd:~#  dmesg | grep dsp
[    0.000000] Reserved memory: initialized node dsp1_cma@99000000, compatible id shared-dma-pool
[    3.675921] omap-rproc 40800000.dsp: assigned reserved memory node dsp1_cma@99000000
[    3.692439]  remoteproc2: 40800000.dsp is available
[    3.766448]  remoteproc2: Direct firmware load for dra7-dsp1-fw.xe66 failed with error -2
[   12.557343]  remoteproc2: powering up 40800000.dsp
[   12.660097]  remoteproc2: Booting fw image dra7-dsp1-fw.xe66, size 4183496
[   12.688748] omap_hwmod: mmu0_dsp1: _wait_target_disable failed
[   13.015374]  remoteproc2: remote processor 40800000.dsp is now up

My yocto uses recipes from the one that is used for automotive SDK 3.04, kernel 4.4.45

I will need to get code working on kernel 4.19.73 later but my priority is this old kernel for now.

Michel Catudal

ACTIA Corp

  • I had forgotten to remove the part about IPU2 and now it works except that I still get errors on boot

    root@actia-gd:~# dmesg | grep dsp
    [    0.000000] Reserved memory: initialized node dsp1_cma@99000000, compatible id shared-dma-pool
    [    3.665929] omap-rproc 40800000.dsp: assigned reserved memory node dsp1_cma@99000000
    [    3.682443]  remoteproc2: 40800000.dsp is available
    [    3.756466]  remoteproc2: Direct firmware load for dra7-dsp1-fw.xe66 failed with error -2
    [   12.515374]  remoteproc2: powering up 40800000.dsp
    [   12.520190]  remoteproc2: Booting fw image dra7-dsp1-fw.xe66, size 4182784
    [   12.618688] omap_hwmod: mmu0_dsp1: _wait_target_disable failed
    [   12.925133]  remoteproc2: remote processor 40800000.dsp is now up
    root@actia-gd:~# dmesg | grep ipu1
    [    0.000000] Reserved memory: initialized node ipu1_cma@9d000000, compatible id shared-dma-pool
    [    3.572499]  remoteproc0: Direct firmware load for dra7-ipu1-fw.xem4 failed with error -2
    [   15.908040]  remoteproc0: Booting fw image dra7-ipu1-fw.xem4, size 3971700
    root@actia-gd:~# dir
    total 40
    drwx------ 2 root root  4096 Nov 18 20:06 .
    drwxr-xr-x 3 root root  4096 Nov 18 19:41 ..
    -rwxr-xr-x 1 root root 26252 Nov 18 20:06 app_host
    -rwxr-xr-x 1 root root   300 Nov 18 19:56 fixScreen.sh
    root@actia-gd:~# ./app_host DSP1
    --> main:
    --> Main_main:
    --> App_create:
    CMEM_init success
    App_create: Host is ready
    <-- App_create:
    --> App_exec:
    user: 0xaa588000 phys: 0xa0000000

    ^CIpc: Caught SIGINT, calling Ipc_stop...
    root@actia-gd:~# ./app_host IPU1
    --> main:
    --> Main_main:
    --> App_create:
    CMEM_init success

    Michel Catudal

    ACTIA Corp

  • Hi Michel,

    Do you mean these lines when you say you see an error?

    Michel Catudal said:

    [    3.756466]  remoteproc2: Direct firmware load for dra7-dsp1-fw.xe66 failed with error -2

    Michel Catudal said:

    [    3.572499]  remoteproc0: Direct firmware load for dra7-ipu1-fw.xem4 failed with error -2

    If so, the "direct firmware load" error is seen if the module is loaded before the filesystem is available. In this case, it will fall back to the user helper and loading will continue when the filesystem is available.

    You can check the state of the remote core after linux is booted with the following to verify that the cores are loaded and running:

    cat /sys/kernel/debug/remoteproc/remoteprocX/state

    Thanks,

    Angela

  • Angela,

    No. On first boot I get this, only happens once on a very cold boot (power off for a while) and when I modify the rootfs.

    root@actia-gd:~# ./app_host_dsp

    Ipc_start: LAD_connect() failed: 4
    <-- main:
    root@actia-gd:~# ./app_host_ipu1
    --> main:
    Ipc_start: LAD_connect() failed: 4
    <-- main:

    It works fine after a reboot except for the DSP

    root@actia-gd:~# cat /sys/kernel/debug/remoteproc/remoteproc2/trace0
    [      0.000] Watchdog disabled: TimerBase = 0x48086000 ClkCtrl = 0x4a009728
    [      0.000] 18 Resource entries at 0x95000000
    [      0.000] [t=0x000489ea] xdc.runtime.Main: --> main:
    [      0.000] registering rpmsg-proto:rpmsg-proto service on 61 with HOST
    [      0.000] [t=0x01d3446e] xdc.runtime.Main: NameMap_sendMessage: HOST 53, port=61
    [      0.000] Watchdog disabled: TimerBase = 0x48086000 ClkCtrl = 0x4a009728
    [      0.000] [t=0x01d55d01] xdc.runtime.Main: --> smain:
    [      0.000] [t=0x01d71c09] Server: Server_create: server is ready
    [      0.000] [t=0x01d7aaa8] Server: <-- Server_create: 0
    [      0.000] [t=0x01d82598] Server: --> Server_exec:

    root@actia-gd:~# cat /sys/kernel/debug/remoteproc/remoteproc0/trace0
    [0][      0.000] Watchdog disabled: TimerBase = 0x68824000 ClkCtrl = 0x6a005568
    [0][      0.000] Watchdog disabled: TimerBase = 0x68826000 ClkCtrl = 0x6a005570
    [0][      0.000] 19 Resource entries at 0x3000
    [0][      0.000] [t=0x000eea47] xdc.runtime.Main: --> main:
    [0][      0.000] registering rpmsg-proto:rpmsg-proto service on 61 with HOST
    [0][      0.000] [t=0x10954a33] xdc.runtime.Main: NameMap_sendMessage: HOST 53, port=61
    [0][      0.000] Watchdog disabled: TimerBase = 0x68824000 ClkCtrl = 0x6a005568
    [0][      0.000] Watchdog disabled: TimerBase = 0x68826000 ClkCtrl = 0x6a005570
    [0][      0.000] [t=0x1099bbf3] xdc.runtime.Main: --> smain:
    [0][      0.000] [t=0x109cabbb] Server: Server_create: server is ready
    [0][      0.000] [t=0x109da26d] Server: <-- Server_create: 0
    [0][      0.000] [t=0x109e64f5] Server: --> Server_exec:
    [0][      0.001] [t=0x109f184d] Server: --> Server_exec: nothing
    [0][     21.237] [t=0x00000002:15c893c3] Server: Server_exec: processed cmd=0x0
    [0][     21.237] [t=0x00000002:15c9e1d1] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.237] [t=0x00000002:15cb9ae1] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.237] [t=0x00000002:15cd2c13] Server:  rxFrames[0].data[0] 0xc
    [0][     21.237]
    [0][     21.238] [t=0x00000002:15cea993] Server: --> Server_exec: nothing
    [0][     21.238] [t=0x00000002:15cfcc67] Server: Server_exec: processed cmd=0x0
    [0][     21.238] [t=0x00000002:15d0e16d] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.238] [t=0x00000002:15d28fb1] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.238] [t=0x00000002:15d41a0f] Server:  rxFrames[0].data[0] 0xd
    [0][     21.238]
    [0][     21.239] [t=0x00000002:15d585a1] Server: --> Server_exec: nothing
    [0][     21.239] [t=0x00000002:15d69045] Server: Server_exec: processed cmd=0x0
    [0][     21.239] [t=0x00000002:15d7a6c3] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.240] [t=0x00000002:15da474f] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.240] [t=0x00000002:15dbee09] Server:  rxFrames[0].data[0] 0xe
    [0][     21.240]
    [0][     21.240] [t=0x00000002:15dd46d1] Server: --> Server_exec: nothing
    [0][     21.240] [t=0x00000002:15decfbf] Server: Server_exec: processed cmd=0x0
    [0][     21.240] [t=0x00000002:15dfe5d5] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.241] [t=0x00000002:15e1985d] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.241] [t=0x00000002:15e3329b] Server:  rxFrames[0].data[0] 0xf
    [0][     21.241]
    [0][     21.241] [t=0x00000002:15e4886d] Server: --> Server_exec: nothing
    [0][     21.241] [t=0x00000002:15e614f9] Server: Server_exec: processed cmd=0x0
    [0][     21.242] [t=0x00000002:15e72d13] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.242] [t=0x00000002:15e8efa5] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.242] [t=0x00000002:15ea7e29] Server:  rxFrames[0].data[0] 0x10
    [0][     21.242]
    [0][     21.242] [t=0x00000002:15ebd717] Server: --> Server_exec: nothing
    [0][     21.243] [t=0x00000002:15ed6565] Server: Server_exec: processed cmd=0x0
    [0][     21.243] [t=0x00000002:15ee8b33] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.243] [t=0x00000002:15f03e85] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.243] [t=0x00000002:15f1c95d] Server:  rxFrames[0].data[0] 0x11
    [0][     21.243]
    [0][     21.244] [t=0x00000002:15f3243b] Server: --> Server_exec: nothing
    [0][     21.244] [t=0x00000002:15f4d1ed] Server: Server_exec: processed cmd=0x0
    [0][     21.244] [t=0x00000002:15f5e87f] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.244] [t=0x00000002:15f79b3d] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.244] [t=0x00000002:15f926a9] Server:  rxFrames[0].data[0] 0x12
    [0][     21.244]
    [0][     21.245] [t=0x00000002:15fa7fcb] Server: --> Server_exec: nothing
    [0][     21.245] [t=0x00000002:15fc1d19] Server: Server_exec: processed cmd=0x0
    [0][     21.245] [t=0x00000002:15fd35cb] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.245] [t=0x00000002:15fee9c5] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.246] [t=0x00000002:160074cb] Server:  rxFrames[0].data[0] 0x13
    [0][     21.246]
    [0][     21.246] [t=0x00000002:1601df5f] Server: --> Server_exec: nothing
    [0][     21.246] [t=0x00000002:16036edd] Server: Server_exec: processed cmd=0x0
    [0][     21.246] [t=0x00000002:160488af] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.247] [t=0x00000002:160639d9] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.247] [t=0x00000002:1607d531] Server:  rxFrames[0].data[0] 0x14
    [0][     21.247]
    [0][     21.247] [t=0x00000002:16092f41] Server: --> Server_exec: nothing
    [0][     21.247] [t=0x00000002:160abccd] Server: Server_exec: processed cmd=0x0
    [0][     21.247] [t=0x00000002:160bd475] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.248] [t=0x00000002:160d93ab] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.248] [t=0x00000002:160f2137] Server:  rxFrames[0].data[0] 0x15
    [0][     21.248]
    [0][     21.248] [t=0x00000002:16107999] Server: --> Server_exec: nothing
    [0][     21.248] [t=0x00000002:16120b23] Server: Server_exec: processed cmd=0x0
    [0][     21.249] [t=0x00000002:16132157] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.249] [t=0x00000002:1614e437] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.249] [t=0x00000002:16167c13] Server:  rxFrames[0].data[0] 0x16
    [0][     21.249]
    [0][     21.249] [t=0x00000002:1617d369] Server: --> Server_exec: nothing
    [0][     21.250] [t=0x00000002:16195dbd] Server: Server_exec: processed cmd=0x0
    [0][     21.250] [t=0x00000002:161a84e3] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.250] [t=0x00000002:161c384f] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.250] [t=0x00000002:161dc2f1] Server:  rxFrames[0].data[0] 0x17
    [0][     21.250]
    [0][     21.251] [t=0x00000002:161f1ddb] Server: --> Server_exec: nothing
    [0][     21.251] [t=0x00000002:1620baa7] Server: Server_exec: processed cmd=0x0
    [0][     21.251] [t=0x00000002:1621d175] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.251] [t=0x00000002:16238435] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.251] [t=0x00000002:16250f9b] Server:  rxFrames[0].data[0] 0x18
    [0][     21.251]
    [0][     21.252] [t=0x00000002:16267387] Server: --> Server_exec: nothing
    [0][     21.252] [t=0x00000002:162780ef] Server: Server_exec: processed cmd=0x0
    [0][     21.252] [t=0x00000002:162896cb] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.252] [t=0x00000002:162a4973] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.253] [t=0x00000002:162bd4cb] Server:  rxFrames[0].data[0] 0x19
    [0][     21.253]
    [0][     21.253] [t=0x00000002:162d31ed] Server: --> Server_exec: nothing
    [0][     21.253] [t=0x00000002:162e3d27] Server: Server_exec: processed cmd=0x0
    [0][     21.253] [t=0x00000002:162f5313] Server: Server_exec: physical memory address =0xa1000000
    [0][     21.253] [t=0x00000002:16310567] Server: Server_exec: RX_dataPhys = 0xa1000000 addrIn=0x86000000
    [0][     21.254] [t=0x00000002:1632906b] Server:  rxFrames[0].data[0] 0x1a
    [0][     21.254]
    [0][     21.254] [t=0x00000002:1633f079] Server: --> Server_exec: nothing
    [0][     26.327] [t=0x00000002:91c074fd] Server: Server_exec: processed cmd=0x2000000
    [0][     26.327] [t=0x00000002:91c1c8ef] Server: Server_exec: physical memory address =0x0
    [0][     26.328] [t=0x00000002:91c3481b] Server: Server_exec: not found resource for phys 0x0
    [0][     26.328]
    [0][     26.328] [t=0x00000002:91c4c843] Server:  rxFrames[0].data[0] 0x0
    [0][     26.328]
    [0][     26.328] [t=0x00000002:91c623fb] Server: <-- Server_exec: 0
    [0][     26.328] [t=0x00000002:91c71cf9] Server: --> Server_delete:
    [0][     26.328] [t=0x00000002:91c8ba85] Server: <-- Server_delete: 0
    [0][     26.329] [t=0x00000002:91cae689] Server: Server_create: server is ready
    [0][     26.329] [t=0x00000002:91cc12cd] Server: <-- Server_create: 0
    [0][     26.329] [t=0x00000002:91cd0d01] Server: --> Server_exec:
    [0][     26.329] [t=0x00000002:91cdf78b] Server: --> Server_exec: nothing

    root@actia-gd:~# dmesg | grep dsp
    [    0.000000] Reserved memory: initialized node dsp1_cma@99000000, compatible id shared-dma-pool
    [    3.655914] omap-rproc 40800000.dsp: assigned reserved memory node dsp1_cma@99000000
    [    3.672435]  remoteproc2: 40800000.dsp is available
    [    3.746453]  remoteproc2: Direct firmware load for dra7-dsp1-fw.xe66 failed with error -2
    [    9.113649]  remoteproc2: powering up 40800000.dsp
    [    9.172782]  remoteproc2: Booting fw image dra7-dsp1-fw.xe66, size 4202396
    [    9.186304] omap_hwmod: mmu0_dsp1: _wait_target_disable failed
    [    9.599107]  remoteproc2: remote processor 40800000.dsp is now up

    root@actia-gd:~# dmesg | grep ipu1
    [    0.000000] Reserved memory: initialized node ipu1_cma@9d000000, compatible id shared-dma-pool
    [    3.490949] omap-rproc 58820000.ipu: assigned reserved memory node ipu1_cma@9d000000
    [    3.562492]  remoteproc0: Direct firmware load for dra7-ipu1-fw.xem4 failed with error -2
    [   12.420302]  remoteproc0: Booting fw image dra7-ipu1-fw.xem4, size 3993648
    root@actia-gd:~# dmesg | grep ipu2
    [    0.000000] Reserved memory: initialized node ipu2_cma@95800000, compatible id shared-dma-pool
    [    3.575937] omap-rproc 55020000.ipu: assigned reserved memory node ipu2_cma@95800000
    [    3.642474]  remoteproc1: Direct firmware load for dra7-ipu2-fw.xem4 failed with error -2
    [   11.929741]  remoteproc1: Booting fw image dra7-ipu2-fw.xem4, size 3739020

    Michel Catudal

    ACTIA Corp

  • Hi Michel,

    So there are 2 issues:

    1. Sometimes LAD_connect() is failing
    2. When LAD_connect doesn't fail, you always see failure of application to communicate with DSP1. IPU1 works fine.

    Is my understanding correct?

    For #1, before running your app, can you confirm that the LAD daemon is running, and also that the /tmp/LAD/LADCMDS is existing? And please share the LAD logs?

    To do so, start lad_dra7xx with the logging option:
        % ./lad_dra7xx -l log.txt
    and that should produce a file named log.txt in /data/lad/LAD.

    For #2, what does this trace mean?

    [0][      0.001] [t=0x109f184d] Server: --> Server_exec: nothing

    This example seems to be modified version of ex02_messageq example, right? Does the default version work fine for you?

    Also please share the LAD logs in this case. And what do host-side application traces show in this case?

    Thanks,

    Angela

  • Angela,

    The message nothing is a test message to see if it was going thru that part, I need to remove it.

    I have the same problem with DSP1 on the original version.

    I removed the code for IPU2 which would conflict with IPUMM and removed the code for DSP2, the DRA726 has no DSP2.

    I added support for cmem which is working. I am not using it in the DSP1 version, that code is much the same as the original one except that I enable cmem access. The DSP is something I will use later on. Right now my code changes are on IPU1 which is where I will put the CAN code for 3 devices. I have to use polling due to some hardware design errors with the interrupts so I am using the IPU1 just for that CAN support. I am starting tests with user to m4 but plan on communicating between a kernel module and the M4 later on. Where can I get documentation on that? Basically I will have share buffer between the kernel and the M4 and exchange some information to get pointers to memory. The kernel module would simulate a regular CAN module. I have a polling modules on Linux but it can't keep up with heavy traffic which is why I want to use the M4 to do the CAN handling for those external CAN ports from Microchip.

    As for the failure, I rarely see it. I first saw this when I created the first rootfs and when I would replace the firmware after the first reboot. I am not using the internal flash for my test but a micro SD. I was working on a LCD update for the past couple of weeks since the manufacturer of the LCDs we used went out of business. This morning when I booted the display I had the errors on boot. After a reboot the problem went away.

    I am making some modification to have separated cmem regions for DSP and IPU1, perhaps that is the problem. Anyhow I have no plan for data exchange between the DSP and M4 so there is no need for common buffer there. My interest for the DSP is for some video conversion when I am done with the CAN handling.

    Michel Catudal

    ACTIA Corp

  • Hi Michel,

    Can you please provide the LAD logs also?

    Thanks,

    Angela

  • Angela,

    Before function started

    [0.298067]
    Initializing LAD... [0.298291] NameServer_setup: entered, refCount=0
    [0.298333] NameServer_setup: creating listener thread
    [0.300373] NameServer_setup: exiting, refCount=1
    [0.300487] NameServer_create(): 'GateMP'
    [0.300509]
        opening FIFO: /tmp/LAD/LADCMDS
    [0.302847] listener_cb: Entered Listener thread.
    [0.302865] NameServer: waiting for unblockFd: 0, and socks: maxfd: 0

    root@actia-gd:~# ./app_host_dsp
    --> main:
    main: Starting App
    --> App_create:
    App_create: Host is ready
    <-- App_create:
    --> App_request_cmem:
    CMEM_init success
    user: 0xb0587000 phys: 0xa1000000
    App_request_cmem: Memory ready to be used
    <-- App_request_cmem:
    --> App_exec:
    App_exec: sending message 1
    App_exec: sending message 2
    App_exec: sending message 3
    ^CIpc: Caught SIGINT, calling Ipc_stop...

    [0.298067]
    Initializing LAD... [0.298291] NameServer_setup: entered, refCount=0
    [0.298333] NameServer_setup: creating listener thread
    [0.300373] NameServer_setup: exiting, refCount=1
    [0.300487] NameServer_create(): 'GateMP'
    [0.300509]
        opening FIFO: /tmp/LAD/LADCMDS
    [0.302847] listener_cb: Entered Listener thread.
    [0.302865] NameServer: waiting for unblockFd: 0, and socks: maxfd: 0
    [373.488590] Retrieving command...
    [373.488699]    EOF detected on FIFO, closing FIFO: /tmp/LAD/LADCMDS
    [373.488727]
        opening FIFO: /tmp/LAD/LADCMDS
    [373.488810] Retrieving command...
    [373.488975]
    LAD_CONNECT:
    [373.488987]     client FIFO name = /tmp/LAD/1241
    [373.488996]     client PID = 1241
    [373.489004]     assigned client handle = 0
    [373.489043]     FIFO /tmp/LAD/1241 created
    [373.489137]     FIFO /tmp/LAD/1241 opened for writing
    [373.489177]     sent response
    [373.489201] DONE
    [373.489210] Retrieving command...
    [373.489291] Sending response...
    [373.489309] Retrieving command...
    [373.489358] LAD_MULTIPROC_GETCONFIG: calling MultiProc_getConfig()...
    [373.489382] MultiProc_getConfig() - 5 procs
    [373.489391] # processors in cluster: 5
    [373.489399] cluster baseId: 0
    [373.489406]     ProcId 0 - "HOST"
    [373.489414]     ProcId 1 - "IPU2"
    [373.489421]     ProcId 2 - "IPU1"
    [373.489428]     ProcId 3 - "DSP2"
    [373.489434]     ProcId 4 - "DSP1"
    [373.489441]     status = 0
    [373.489448] DONE
    [373.489455] Sending response...
    [373.489467] Retrieving command...
    [373.489520] LAD_NAMESERVER_SETUP: calling NameServer_setup()...
    [373.489531] NameServer_setup: entered, refCount=1
    [373.489538] NameServer_setup: already setup
    [373.489546] NameServer_setup: exiting, refCount=2
    [373.489553]     status = 1
    [373.489560] DONE
    [373.489567] Sending response...
    [373.489579] Retrieving command...
    [373.489624] LAD_MESSAGEQ_GETCONFIG: calling MessageQ_getConfig()...
    [373.489635]     status = 0
    [373.489642] DONE
    [373.489649] Sending response...
    [373.489661] Retrieving command...
    [373.489706] LAD_MESSAGEQ_SETUP: calling MessageQ_setup()...
    [373.489716] MessageQ_setup: entered, refCount=0
    [373.489725] NameServer_create(): 'MessageQ'
    [373.489741] MessageQ_setup: exiting, refCount=1
    [373.489750]     status = 0
    [373.489756] DONE
    [373.489763] Sending response...
    [373.489774] Retrieving command...
    [373.489980] NameServer_attach: --> procId=1, refCount=0
    [373.490015] NameServer_attach: created send socket: 6, procId 1
    [373.490054] NameServer_attach: connect failed: procId=1, errno=22 (Invalid argument)
    [373.490080]     closing send socket: 6
    [373.490109] NameServer_attach: <-- refCount=0, status=-1
    [373.490120] Sending response...
    [373.490133] Retrieving command...
    [373.490190] NameServer_attach: --> procId=2, refCount=0
    [373.490210] NameServer_attach: created send socket: 6, procId 2
    [373.490238] NameServer_attach: created receive socket: 7, procId 2
    [373.491696] NameServer: back from select()
    [373.491729] NameServer: listener thread, event: REFRESH
    [373.491751] NameServer: waiting for unblockFd: 0, and socks: maxfd: 7
    [373.492032] NameServer_attach: <-- refCount=1, status=0
    [373.492052] Sending response...
    [373.492070] Retrieving command...
    [373.492209] LAD_GATEMP_ISSETUP: calling GateMP_isSetup()...
    [373.492222]     status = 0
    [373.492230] DONE
    [373.492237] Sending response...
    [373.492250] Retrieving command...
    [373.492301] LAD_GATEMP_ATTACH: calling GateMP_attach(2)...
    [373.492328] NameServer_getRemote: Sending request via sock: 6
    [373.492345] NameServer_getRemote: requesting from procId 2, GateMP: _GateMP_TI_dGate
    [373.492396] NameServer_getRemote: pending on waitFd: 1
    [373.492550] NameServer: back from select()
    [373.492566] NameServer: Listener got NameServer message from sock: 7!
    [373.492586] listener_cb: recvfrom socket: fd: 7
    [373.492596]     Received ns msg: nbytes: 484, from addr: 61, from vproc: 0
    [373.492604] NameServer Reply: instanceName: GateMP, name: _GateMP_TI_dGate, value: 0x0
    [373.492622] NameServer: waiting for unblockFd: 0, and socks: maxfd: 7
    [373.492648] NameServer_getRemote: value for GateMP:_GateMP_TI_dGate not found.
    [373.492660] GateMP_attach: failed to open default gate on procId 2
    [373.492693]     status = -5
    [373.492702] DONE
    [373.492710] Sending response...
    [373.492731] Retrieving command...
    [373.492868] NameServer_attach: --> procId=3, refCount=0
    [373.492894] NameServer_attach: created send socket: 8, procId 3
    [373.492910] NameServer_attach: connect failed: procId=3, errno=22 (Invalid argument)
    [373.492927]     closing send socket: 8
    [373.492954] NameServer_attach: <-- refCount=0, status=-1
    [373.492965] Sending response...
    [373.492980] Retrieving command...
    [373.493032] NameServer_attach: --> procId=4, refCount=0
    [373.493052] NameServer_attach: created send socket: 8, procId 4
    [373.493076] NameServer_attach: created receive socket: 9, procId 4
    [373.493312] NameServer: back from select()
    [373.493331] NameServer: listener thread, event: REFRESH
    [373.493347] NameServer: waiting for unblockFd: 0, and socks: maxfd: 9
    [373.494342] NameServer_attach: <-- refCount=1, status=0
    [373.494364] Sending response...
    [373.494381] Retrieving command...
    [373.494480] LAD_GATEMP_ISSETUP: calling GateMP_isSetup()...
    [373.494492]     status = 0
    [373.494501] DONE
    [373.494508] Sending response...
    [373.494522] Retrieving command...
    [373.494570] LAD_GATEMP_ATTACH: calling GateMP_attach(4)...
    [373.494584] NameServer_getRemote: Sending request via sock: 8
    [373.494594] NameServer_getRemote: requesting from procId 4, GateMP: _GateMP_TI_dGate
    [373.494640] NameServer_getRemote: pending on waitFd: 1
    [373.494747] NameServer: back from select()
    [373.494762] NameServer: Listener got NameServer message from sock: 9!
    [373.494778] listener_cb: recvfrom socket: fd: 9
    [373.494788]     Received ns msg: nbytes: 484, from addr: 61, from vproc: 2
    [373.494797] NameServer Reply: instanceName: GateMP, name: _GateMP_TI_dGate, value: 0x0
    [373.494815] NameServer: waiting for unblockFd: 0, and socks: maxfd: 9
    [373.494843] NameServer_getRemote: value for GateMP:_GateMP_TI_dGate not found.
    [373.494855] GateMP_attach: failed to open default gate on procId 4
    [373.494863]     status = -5
    [373.494870] DONE
    [373.494877] Sending response...
    [373.494897] Retrieving command...
    [373.494942] LAD_GATEMP_ISSETUP: calling GateMP_isSetup()...
    [373.494953]     status = 0
    [373.494961] DONE
    [373.494967] Sending response...
    [373.494980] Retrieving command...
    [373.495031] LAD_GATEHWSPINLOCK_GETCONFIG: calling GateHWSpinlock_getConfig()...
    [373.495042] GateHWSpinlock_getConfig()    baseAddr = 0x4a0f6000
    [373.495050]     size = 0x1000
        offset = 0x800
    [373.495059]     status = 0
    [373.495067] DONE
    [373.495074] Sending response...
    [373.495087] Retrieving command...
    [373.495237] LAD_GATEMP_START: calling GateMP_start()...
    [373.495251]     status = 0
    [373.495260] DONE
    [373.495267] Sending response...
    [373.495280] Retrieving command...
    [373.495330] LAD_GATEMP_GETNUMRESOURCES: calling GateMP_getNumResources()...
    [373.495340]     status = 0
    [373.495348] DONE
    [373.495355] Sending response...
    [373.495368] Retrieving command...
    [373.495422] LAD_NAMESERVER_GET: calling NameServer_get(0x32238, '_GateMP_TI_dGate'[373.495434] )...
    [373.495445] NameServer_getLocal: entry key: '_GateMP_TI_dGate' not found!
    [373.495455] NameServer_getRemote: no socket connection to processor 1
    [373.495464] NameServer_getRemote: Sending request via sock: 6
    [373.495473] NameServer_getRemote: requesting from procId 2, GateMP: _GateMP_TI_dGate
    [373.495503] NameServer_getRemote: pending on waitFd: 1
    [373.495639] NameServer: back from select()
    [373.495652] NameServer: Listener got NameServer message from sock: 7!
    [373.495668] listener_cb: recvfrom socket: fd: 7
    [373.495677]     Received ns msg: nbytes: 484, from addr: 61, from vproc: 0
    [373.495686] NameServer Reply: instanceName: GateMP, name: _GateMP_TI_dGate, value: 0x0
    [373.495703] NameServer: waiting for unblockFd: 0, and socks: maxfd: 9
    [373.495730] NameServer_getRemote: value for GateMP:_GateMP_TI_dGate not found.
    [373.495742] NameServer_getRemote: no socket connection to processor 3
    [373.495751] NameServer_getRemote: Sending request via sock: 8
    [373.495759] NameServer_getRemote: requesting from procId 4, GateMP: _GateMP_TI_dGate
    [373.495785] NameServer_getRemote: pending on waitFd: 1
    [373.495880] NameServer: back from select()
    [373.495893] NameServer: Listener got NameServer message from sock: 9!
    [373.495907] listener_cb: recvfrom socket: fd: 9
    [373.495916]     Received ns msg: nbytes: 484, from addr: 61, from vproc: 2
    [373.495925] NameServer Reply: instanceName: GateMP, name: _GateMP_TI_dGate, value: 0x0
    [373.495942] NameServer: waiting for unblockFd: 0, and socks: maxfd: 9
    [373.495968] NameServer_getRemote: value for GateMP:_GateMP_TI_dGate not found.
    [373.495980]     value = 0x10
    [373.495988]     status = -5
    [373.495995] DONE
    [373.496003] Sending response...
    [373.496023] Retrieving command...
    [373.496170] LAD_MESSAGEQ_CREATE: calling MessageQ_create(0x2f8a4, 0x2f8c4)...
    [373.496183] MessageQ_create: creating 'HOST:MsgQ:01'
    [373.496196] MessageQ_create: returning obj=0x34660, qid=0x80
    [373.496206]     status = 0
    [373.496213] DONE
    [373.496221] Sending response...
    [373.496234] Retrieving command...
    [373.502017] LAD_MESSAGEQ_ANNOUNCE: calling MessageQ_announce(0x2f8a4, 0x34660)...
    [373.502043] MessageQ_announce: announcing 0x34660
    [373.502062] NameServer_add: Entered key: 'HOST:MsgQ:01', data: 0x80
    [373.502074]     status = 0
    [373.502082] DONE
    [373.502090] Sending response...
    [373.502106] Retrieving command...
    [373.502185] LAD_NAMESERVER_GETUINT32: calling NameServer_getUInt32(0x34578, 'DSP1:MsgQ:01')...
    [373.502200] NameServer_getLocal: entry key: 'DSP1:MsgQ:01' not found!
    [373.502212] NameServer_getRemote: no socket connection to processor 1
    [373.502222] NameServer_getRemote: Sending request via sock: 6
    [373.502230] NameServer_getRemote: requesting from procId 2, MessageQ: DSP1:MsgQ:01
    [373.502275] NameServer_getRemote: pending on waitFd: 1
    [373.502404] NameServer: back from select()
    [373.502421] NameServer: Listener got NameServer message from sock: 7!
    [373.502439] listener_cb: recvfrom socket: fd: 7
    [373.502449]     Received ns msg: nbytes: 484, from addr: 61, from vproc: 0
    [373.502458] NameServer Reply: instanceName: MessageQ, name: DSP1:MsgQ:01, value: 0x0
    [373.502476] NameServer: waiting for unblockFd: 0, and socks: maxfd: 9
    [373.502505] NameServer_getRemote: value for MessageQ:DSP1:MsgQ:01 not found.
    [373.502517] NameServer_getRemote: no socket connection to processor 3
    [373.502526] NameServer_getRemote: Sending request via sock: 8
    [373.502535] NameServer_getRemote: requesting from procId 4, MessageQ: DSP1:MsgQ:01
    [373.502577] NameServer_getRemote: pending on waitFd: 1
    [373.502681] NameServer: back from select()
    [373.502695] NameServer: Listener got NameServer message from sock: 9!
    [373.502710] listener_cb: recvfrom socket: fd: 9
    [373.502719]     Received ns msg: nbytes: 484, from addr: 61, from vproc: 2
    [373.502728] NameServer Reply: instanceName: MessageQ, name: DSP1:MsgQ:01, value: 0x30080
    [373.502744] NameServer: waiting for unblockFd: 0, and socks: maxfd: 9
    [373.502849] NameServer_getRemote: Reply from: 4, MessageQ: name: DSP1:MsgQ:01, value: 0x30080
    [373.502867]     value = 0x30080
    [373.502876]     status = 0
    [373.502884] DONE
    [373.502891] Sending response...
    [373.502915] Retrieving command...
    [385.712530] LAD_GATEMP_ISSETUP: calling GateMP_isSetup()...
    [385.712557]     status = 0
    [385.712567] DONE
    [385.712576] Sending response...
    [385.712603] Retrieving command...
    [385.712662] LAD_GATEMP_DETACH: calling GateMP_detach(2)...
    [385.712675]     status = -5
    [385.712684] DONE
    [385.712691] Sending response...
    [385.712710] Retrieving command...
    [385.714225] NameServer_detach: --> procId=2, refCount=1
    [385.714284] NameServer: back from select()
    [385.714303] NameServer: listener thread, event: REFRESH
    [385.714320] NameServer: waiting for unblockFd: 0, and socks: maxfd: 9
    [385.714345] NameServer_detach: closing socket: 6
    [385.714380] NameServer_detach: closing socket: 7
    [385.714537] NameServer_detach: <-- refCount=0, status=0
    [385.714551] Sending response...
    [385.714578] Retrieving command...
    [385.714644] LAD_GATEMP_ISSETUP: calling GateMP_isSetup()...
    [385.714656]     status = 0
    [385.714664] DONE
    [385.714672] Sending response...
    [385.714689] Retrieving command...
    [385.714756] LAD_GATEMP_DETACH: calling GateMP_detach(4)...
    [385.714768]     status = -5
    [385.714776] DONE
    [385.714784] Sending response...
    [385.714802] Retrieving command...
    [385.715064] NameServer_detach: --> procId=4, refCount=1
    [385.715095] NameServer: back from select()
    [385.715109] NameServer: listener thread, event: REFRESH
    [385.715124] NameServer: waiting for unblockFd: 0, and socks: maxfd: 0
    [385.715143] NameServer_detach: closing socket: 8
    [385.715170] NameServer_detach: closing socket: 9
    [385.715288] NameServer_detach: <-- refCount=0, status=0
    [385.715301] Sending response...
    [385.715322] Retrieving command...
    [385.715556] LAD_MESSAGEQ_DESTROY: calling MessageQ_destroy()...
    [385.715569] MessageQ_destroy: entered, refCount=1
    [385.715579] MessageQ_delete: deleting 0x34660
    [385.715598] MessageQ_delete: returning 0
    [385.715613] MessageQ_destroy: exiting, refCount=0
    [385.715622]     status = 0
    [385.715630] DONE
    [385.715638] Sending response...
    [385.715658] Retrieving command...
    [385.715712] LAD_NAMESERVER_DESTROY: calling NameServer_destroy()...
    [385.715723] NameServer_destroy: entered, refCount=2
    [385.715731] NameServer_destroy(): refCount(1) > 0, exiting
    [385.715739] NameServer_destroy: exiting, refCount=1
    [385.715747]     status = 0
    [385.715755] DONE
    [385.715762] Sending response...
    [385.715780] Retrieving command...
    [385.718345]
    LAD_DISCONNECT: [385.718386]
        client handle = 0[385.718398]
        closing FIFO /tmp/LAD/1241 (filePtr=0x33408)
    [385.718430]     done, unlinking /tmp/LAD/1241
    [385.718473] DONE
    [385.718484] Retrieving command...
    [385.719950]    EOF detected on FIFO, closing FIFO: /tmp/LAD/LADCMDS
    [385.719984]
        opening FIFO: /tmp/LAD/LADCMDS

    Michel Catudal

    ACTIA Corp

  • Angela,

    The problem was fixed by adding non existant "DSP2" in the list

    from

    var procNameAry = ["HOST", "IPU2", "IPU1","DSP1"];

    to

    var procNameAry = ["HOST", "IPU2", "IPU1","DSP2","DSP1"];

    This is weird considering that that DSP doesn't exist in this processor. Is it likely to create problem for the kernel to believe that there is a DSP2 in there?

    or is it just a bug in the IPC library?

    It seems to work ok except that it has the wrong physical address. I could have sworn that I had it moved to 0xa7000000

    root@actia-gd:~# ./app_host_dsp
    --> main:
    main: Starting App
    --> App_create:
    App_create: Host is ready
    <-- App_create:
    --> App_request_cmem:
    CMEM_init success
    user: 0xb056d000 phys: 0xa1000000
    App_request_cmem: Memory ready to be used
    <-- App_request_cmem:
    --> App_exec:
    App_exec: sending message 1
    App_exec: sending message 2
    App_exec: sending message 3
    App_exec: message received, sending message 4
    App_exec: message received, sending message 5
    App_exec: message received, sending message 6
    App_exec: message received, sending message 7
    App_exec: message received, sending message 8
    App_exec: message received, sending message 9
    App_exec: message received, sending message 10
    App_exec: message received, sending message 11
    App_exec: message received, sending message 12
    App_exec: message received, sending message 13
    App_exec: message received, sending message 14
    App_exec: message received, sending message 15
    App_exec: message received
    App_exec: message received
    App_exec: message received
    <-- App_exec: 0
    --> App_delete:
    <-- App_delete:
    <-- main:

    Michel Catudal

    ACTIA Corp

  • Angela,

    It looks like I need to use CMEM_alloc2 instead of CMEM_alloc

        cmem_buffer = CMEM_allocPool(CMEM_getPool(PAYLOADSIZE), &cmemAttrs);

    changed to for dsp1

    cmem_buffer = CMEM_allocPool2(1,CMEM_getPool(PAYLOADSIZE), &cmemAttrs);  

    for ipu1

    cmem_buffer = CMEM_allocPool2(0,CMEM_getPool(PAYLOADSIZE), &cmemAttrs);  

    Is it correct?

    Here in my devicetree

    / {
            reserved-memory {
                    #address-cells = <2>;
                    #size-cells = <2>;
                    ranges;

                splash_region: splash_region@a0000000 {
                    reg = <0x0 0xa0000000 0x0 0x1000000>;
                   no-map;
                status = "okay";
                   };

                    cmem_block_mem_0: cmem_block_mem@a1000000 {
                            reg = <0x0 0xa1000000 0x0 0x06000000>;
                            no-map;
                            status = "okay";
                    };

                    cmem_block_mem_1: cmem_block_mem@a7000000 {
                            reg = <0x0 0xa7000000 0x0 0x06000000>;
                            no-map;
                            status = "okay";
                    };
            };

            cmem {
                    compatible = "ti,cmem";
                    #address-cells = <1>;
                    #size-cells = <0>;

            #pool-size-cells = <2>;

                    status = "okay";

                    cmem_block_0: cmem_block@0 {
                            reg = <0>;
                            memory-region = <&cmem_block_mem_0>;
                            cmem-buf-pools = <1 0x0 0x06000000>;
                    };

                    cmem_block_1: cmem_block@1 {
                            reg = <1>;
                            memory-region = <&cmem_block_mem_1>;
                            cmem-buf-pools = <1 0x0 0x06000000>;
                    };
            };
    };


    Michel Catudal

    ACTIA Corp

  • Angela,

    I fixed the error message on boot by compiling  remoteproc as module instead of compiled in the kernel

    I am still getting an error but just for DSP1

    root@actia-gd:~# dmesg | grep ipu2
    [    0.000000] Reserved memory: initialized node ipu2_cma@95800000, compatible id shared-dma-pool
    [   10.198472] omap-rproc 55020000.ipu: assigned reserved memory node ipu2_cma@95800000
    [   14.663719]  remoteproc1: Booting fw image dra7-ipu2-fw.xem4, size 3739020
    root@actia-gd:~# dmesg | grep ipu1
    [    0.000000] Reserved memory: initialized node ipu1_cma@9d000000, compatible id shared-dma-pool
    [    9.941117] omap-rproc 58820000.ipu: assigned reserved memory node ipu1_cma@9d000000
    [   14.468978]  remoteproc0: Booting fw image dra7-ipu1-fw.xem4, size 3993488
    root@actia-gd:~# dmesg | grep dsp1
    [    0.000000] Reserved memory: initialized node dsp1_cma@99000000, compatible id shared-dma-pool
    [   10.468699] omap-rproc 40800000.dsp: assigned reserved memory node dsp1_cma@99000000
    [   15.327418]  remoteproc2: Booting fw image dra7-dsp1-fw.xe66, size 4203120
    [   15.355905] omap_hwmod: mmu0_dsp1: _wait_target_disable failed

    How do I fix that?

    Michel Catudal

    ACTIA Corp

  • Angela,

    The funny thing with having the remoteproc as module, now it never works.

    I returned to have the modules compiled into the kernel and they work.

    [0.489119]
    Initializing LAD... [0.489352] NameServer_setup: entered, refCount=0
    [0.489378] NameServer_setup: creating listener thread
    [0.489494] NameServer_setup: exiting, refCount=1
    [0.489593] NameServer_create(): 'GateMP'
    [0.489613]
        opening FIFO: /tmp/LAD/LADCMDS
    [0.489672] listener_cb: Entered Listener thread.
    [0.489682] NameServer: waiting for unblockFd: 0, and socks: maxfd: 0
    [31.825743] Retrieving command...
    [31.825872]    EOF detected on FIFO, closing FIFO: /tmp/LAD/LADCMDS
    [31.825904]
        opening FIFO: /tmp/LAD/LADCMDS
    [31.825991] Retrieving command...
    [31.826164]
    LAD_CONNECT:
    [31.826178]     client FIFO name = /tmp/LAD/1192
    [31.826188]     client PID = 1192
    [31.826197]     assigned client handle = 0
    [31.826240]     FIFO /tmp/LAD/1192 created
    [31.826349]     FIFO /tmp/LAD/1192 opened for writing
    [31.826386]     sent response
    [31.826397] DONE
    [31.826404] Retrieving command...
    [31.826487] Sending response...
    [31.826504] Retrieving command...
    [31.826562] LAD_MULTIPROC_GETCONFIG: calling MultiProc_getConfig()...
    [31.826578] MultiProc_getConfig() - 5 procs
    [31.826588] # processors in cluster: 5
    [31.826597] cluster baseId: 0
    [31.826604]     ProcId 0 - "HOST"
    [31.826613]     ProcId 1 - "IPU2"
    [31.826620]     ProcId 2 - "IPU1"
    [31.826628]     ProcId 3 - "DSP2"
    [31.826635]     ProcId 4 - "DSP1"
    [31.826642]     status = 0
    [31.826650] DONE
    [31.826656] Sending response...
    [31.826668] Retrieving command...
    [31.826720] LAD_NAMESERVER_SETUP: calling NameServer_setup()...
    [31.826732] NameServer_setup: entered, refCount=1
    [31.826740] NameServer_setup: already setup
    [31.826748] NameServer_setup: exiting, refCount=2
    [31.826756]     status = 1
    [31.826764] DONE
    [31.826770] Sending response...
    [31.826782] Retrieving command...
    [31.826826] LAD_MESSAGEQ_GETCONFIG: calling MessageQ_getConfig()...
    [31.826837]     status = 0
    [31.826845] DONE
    [31.826852] Sending response...
    [31.826863] Retrieving command...
    [31.826907] LAD_MESSAGEQ_SETUP: calling MessageQ_setup()...
    [31.826918] MessageQ_setup: entered, refCount=0
    [31.826927] NameServer_create(): 'MessageQ'
    [31.826943] MessageQ_setup: exiting, refCount=1
    [31.826952]     status = 0
    [31.826960] DONE
    [31.826967] Sending response...
    [31.826979] Retrieving command...
    [31.827193] NameServer_attach: --> procId=1, refCount=0
    [31.827230] NameServer_attach: created send socket: 6, procId 1
    [31.827268] NameServer_attach: connect failed: procId=1, errno=22 (Invalid argument)
    [31.827302]     closing send socket: 6
    [31.827334] NameServer_attach: <-- refCount=0, status=-1
    [31.827346] Sending response...
    [31.827359] Retrieving command...
    [31.827412] NameServer_attach: --> procId=2, refCount=0
    [31.827432] NameServer_attach: created send socket: 6, procId 2
    [31.827445] NameServer_attach: connect failed: procId=2, errno=22 (Invalid argument)
    [31.827458]     closing send socket: 6
    [31.827478] NameServer_attach: <-- refCount=0, status=-1
    [31.827488] Sending response...
    [31.827501] Retrieving command...
    [31.827549] NameServer_attach: --> procId=3, refCount=0
    [31.827569] NameServer_attach: created send socket: 6, procId 3
    [31.827582] NameServer_attach: connect failed: procId=3, errno=22 (Invalid argument)
    [31.827594]     closing send socket: 6
    [31.827614] NameServer_attach: <-- refCount=0, status=-1
    [31.827624] Sending response...
    [31.827636] Retrieving command...
    [31.827682] NameServer_attach: --> procId=4, refCount=0
    [31.827702] NameServer_attach: created send socket: 6, procId 4
    [31.827715] NameServer_attach: connect failed: procId=4, errno=22 (Invalid argument)
    [31.827727]     closing send socket: 6
    [31.827746] NameServer_attach: <-- refCount=0, status=-1
    [31.827756] Sending response...
    [31.827768] Retrieving command...
    [31.827816] LAD_GATEMP_ISSETUP: calling GateMP_isSetup()...
    [31.827827]     status = 0
    [31.827835] DONE
    [31.827842] Sending response...
    [31.827854] Retrieving command...
    [31.827899] LAD_GATEHWSPINLOCK_GETCONFIG: calling GateHWSpinlock_getConfig()...
    [31.827910] GateHWSpinlock_getConfig()  baseAddr = 0x4a0f6000
    [31.827919]     size = 0x1000
            offset = 0x800
    [31.827928]     status = 0
    [31.827936] DONE
    [31.827943] Sending response...
    [31.827968] Retrieving command...
    [31.828101] LAD_GATEMP_START: calling GateMP_start()...
    [31.828113]     status = 0
    [31.828122] DONE
    [31.828129] Sending response...
    [31.828142] Retrieving command...

    part of message on boot as seen on uart

    Welcome to ACTIA 2020.02!

    [    4.383320] systemd[1]: Set hostname to <actia-gd>.
    [    4.423639] random: systemd-sysv-ge: uninitialized urandom read (16 bytes read, 15 bits of entropy available)
    [    4.436608] random: systemd-gpt-aut: uninitialized urandom read (16 bytes read, 15 bits of entropy available)
    [    4.447470] random: systemd-gpt-aut: uninitialized urandom read (16 bytes read, 15 bits of entropy available)
    [    4.475467] random: systemd-sysv-ge: uninitialized urandom read (16 bytes read, 16 bits of entropy available)
    [    4.488989] random: systemd-sysv-ge: uninitialized urandom read (16 bytes read, 16 bits of entropy available)
    [    4.505713] random: systemd-sysv-ge: uninitialized urandom read (16 bytes read, 17 bits of entropy available)
    [    4.595213] systemd-sysv-generator[86]: Overwriting existing symlink /run/systemd/generator.late/bootlogd.service with real service.
    [    4.610776] random: systemd: uninitialized urandom read (16 bytes read, 20 bits of entropy available)
    [    4.620425] random: systemd: uninitialized urandom read (16 bytes read, 20 bits of entropy available)
    [    5.162540] systemd[1]: [/etc/systemd/system/start-can.service:1] Assignment outside of section. Ignoring.
    [    5.172270] systemd[1]: [/etc/systemd/system/start-can.service:2] Assignment outside of section. Ignoring.
    [    5.185183] systemd[1]: sockets.target: Found ordering cycle on sockets.target/start
    [    5.193029] systemd[1]: sockets.target: Found dependency on sshd.socket/stop
    [    5.200115] systemd[1]: sockets.target: Found dependency on sysinit.target/start
    [    5.207588] systemd[1]: sockets.target: Found dependency on alignment.service/start
    [    5.215552] systemd[1]: sockets.target: Found dependency on basic.target/start
    [    5.222829] systemd[1]: sockets.target: Found dependency on sockets.target/start
    [    5.230261] systemd[1]: sockets.target: Breaking ordering cycle by deleting job sshd.socket/stop
    [    5.239105] systemd[1]: sshd.socket: Job sshd.socket/stop deleted to break ordering cycle starting with sockets.target/start
    [ SKIP ] Ordering cycle found, skipping sshd.socket
    [    5.273513] systemd[1]: sockets.target: Found ordering cycle on sockets.target/start
    [    5.281298] systemd[1]: sockets.target: Found dependency on avahi-daemon.socket/start
    [    5.289257] systemd[1]: sockets.target: Found dependency on sysinit.target/start
    [    5.296726] systemd[1]: sockets.target: Found dependency on alignment.service/start
    [    5.304469] systemd[1]: sockets.target: Found dependency on basic.target/start
    [    5.311725] systemd[1]: sockets.target: Found dependency on sockets.target/start
    [    5.319194] systemd[1]: sockets.target: Breaking ordering cycle by deleting job avahi-daemon.socket/start
    [    5.328840] systemd[1]: avahi-daemon.socket: Job avahi-daemon.socket/start deleted to break ordering cycle starting with sockets.target/start
    [ SKIP ] Ordering cycle found, skipping Avah...S/DNS-SD Stack Activation Socket
    [    5.362664] systemd[1]: sysinit.target: Found ordering cycle on sysinit.target/start
    [    5.370452] systemd[1]: sysinit.target: Found dependency on bootlogd.service/start
    [    5.378097] systemd[1]: sysinit.target: Found dependency on sysinit.target/start
    [    5.385581] systemd[1]: sysinit.target: Breaking ordering cycle by deleting job bootlogd.service/start
    [    5.394991] systemd[1]: bootlogd.service: Job bootlogd.service/start deleted to break ordering cycle starting with sysinit.target/start
    [ SKIP ] Ordering cycle found, skipping LSB:... to be executed. Starts or stops
    [    5.432651] systemd[1]: sockets.target: Found ordering cycle on sockets.target/start
    [    5.440439] systemd[1]: sockets.target: Found dependency on dbus.socket/start
    [    5.447645] systemd[1]: sockets.target: Found dependency on sysinit.target/start
    [    5.455116] systemd[1]: sockets.target: Found dependency on alignment.service/start
    [    5.462849] systemd[1]: sockets.target: Found dependency on basic.target/start
    [    5.470110] systemd[1]: sockets.target: Found dependency on sockets.target/start
    [    5.477575] systemd[1]: sockets.target: Breaking ordering cycle by deleting job dbus.socket/start
    [    5.486526] systemd[1]: dbus.socket: Job dbus.socket/start deleted to break ordering cycle starting with sockets.target/start
    [ SKIP ] Ordering cycle found, skipping D-Bus System Message Bus Socket
    [    5.522953] systemd[1]: sockets.target: Found ordering cycle on sockets.target/start
    [    5.530790] systemd[1]: sockets.target: Found dependency on org.cups.cupsd.socket/start
    [    5.539010] systemd[1]: sockets.target: Found dependency on sysinit.target/start
    [    5.546468] systemd[1]: sockets.target: Found dependency on alignment.service/start
    [    5.554195] systemd[1]: sockets.target: Found dependency on basic.target/start
    [    5.561448] systemd[1]: sockets.target: Found dependency on sockets.target/start
    [    5.568902] systemd[1]: sockets.target: Breaking ordering cycle by deleting job org.cups.cupsd.socket/start
    [    5.578714] systemd[1]: org.cups.cupsd.socket: Job org.cups.cupsd.socket/start deleted to break ordering cycle starting with sockets.target/start
    [ SKIP ] Ordering cycle found, skipping CUPS Scheduler
    [    5.612597] systemd[1]: sockets.target: Found ordering cycle on sockets.target/start
    [    5.620381] systemd[1]: sockets.target: Found dependency on org.cups.cups-lpd.socket/start
    [    5.628710] systemd[1]: sockets.target: Found dependency on sysinit.target/start
    [    5.636170] systemd[1]: sockets.target: Found dependency on alignment.service/start
    [    5.643892] systemd[1]: sockets.target: Found dependency on basic.target/start
    [    5.651145] systemd[1]: sockets.target: Found dependency on sockets.target/start
    [    5.658602] systemd[1]: sockets.target: Breaking ordering cycle by deleting job org.cups.cups-lpd.socket/start
    [    5.668672] systemd[1]: org.cups.cups-lpd.socket: Job org.cups.cups-lpd.socket/start deleted to break ordering cycle starting with sockets.target/start
    [ SKIP ] Ordering cycle found, skipping CUPS LPD Server Socket
    [    5.702606] systemd[1]: alignment.service: Found ordering cycle on alignment.service/start
    [    5.710908] systemd[1]: alignment.service: Found dependency on sysinit.target/start
    [    5.718834] systemd[1]: alignment.service: Found dependency on alignment.service/start
    [    5.726819] systemd[1]: alignment.service: Breaking ordering cycle by deleting job alignment.service/start
    [    5.736550] systemd[1]: alignment.service: Job alignment.service/start deleted to break ordering cycle starting with alignment.service/start
    [ SKIP ] Ordering cycle found, skipping alignment.service
    [    5.775231] systemd[1]: Listening on udev Control Socket.

    Michel Catudal

    ACTIA Corp

  • Hi Michel,

    Michel Catudal said:

    The problem was fixed by adding non existant "DSP2" in the list

    from

    var procNameAry = ["HOST", "IPU2", "IPU1","DSP1"];

    to

    var procNameAry = ["HOST", "IPU2", "IPU1","DSP2","DSP1"];

    This is weird considering that that DSP doesn't exist in this processor. Is it likely to create problem for the kernel to believe that there is a DSP2 in there?

    or is it just a bug in the IPC library?

    This is expected because there is a dependency on Multiproc config between the LAD daemon running on Linux and the remote core firmware.

    When DSP2 is removed from the Multiproc config on the remote core side, it is still present in the Multiproc config of the LAD daemon:

    linux/src/daemon/cfg/MultiProcCfg_dra7xx.c

    (excerpt below)

    /* This must match BIOS side MultiProc configuration for given platform!: */
    MultiProc_Config _MultiProc_cfg = {
    .numProcessors = 5,
    .nameList[0] = "HOST",
    .nameList[1] = "IPU2",
    .nameList[2] = "IPU1",
    .nameList[3] = "DSP2",
    .nameList[4] = "DSP1",
    .rprocList[0] = -1,
    #if LINUX_VERSION_CODE < KERNEL_VERSION(3,14,0)
    .rprocList[1] = 1,
    .rprocList[2] = 3,
    .rprocList[3] = 2,
    .rprocList[4] = 0,
    #else
    .rprocList[1] = 1,
    .rprocList[2] = 0,
    .rprocList[3] = 3,
    .rprocList[4] = 2,
    #endif /* LINUX_VERSION_CODE */
    .id = 0, /* The host is always zero */
    .numProcsInCluster = 5,
    .baseIdOfCluster = 0
    };

    Leaving DSP2 in the Multiproc config should be OK even if you don't use it. 

    Thanks,

    Angela

  • Hi Michel,

    Michel Catudal said:

    It looks like I need to use CMEM_alloc2 instead of CMEM_alloc

        cmem_buffer = CMEM_allocPool(CMEM_getPool(PAYLOADSIZE), &cmemAttrs);

    changed to for dsp1

    cmem_buffer = CMEM_allocPool2(1,CMEM_getPool(PAYLOADSIZE), &cmemAttrs);  

    for ipu1

    cmem_buffer = CMEM_allocPool2(0,CMEM_getPool(PAYLOADSIZE), &cmemAttrs);  

    Is it correct?

    Yes, if you want to allocate from a specific CMEM block, please use CMEM_allocPool2.

    Thanks,

    Angela

  • Hi Michel,

    Michel Catudal said:

    [   15.355905] omap_hwmod: mmu0_dsp1: _wait_target_disable failed

    This trace is expected at startup and then each time the cores go to auto-suspend. They do not indicate an issue with the remote cores.

    Thanks,

    Angela

  • Hi Michel,

    Can you please help summarize, if you are still facing any issue?

    It sounds like DSP communication is working now, is that correct?

    Also, I have confirmed that the following traces are normal when remoteproc is built-in:

    [    3.582496]  remoteproc0: Direct firmware load for dra7-ipu1-fw.xem4 failed with error -2

    It comes because the filesystem is not yet available and the firmwares are located in the filesystem. In this case it will fall back to user helper to load the firmware later. Later traces in your log indicate that remoteproc loading proceeded as expected once the filesystem was available.

    Thanks,

    Angela

  • Angela,

    DSP1 is working. I am puzzled though why the ipu1 and dsp1 communication don't work if I build the remoteproc as modules but it works when they are compiled in.

    With RPMsg, how do I choose which core to talk to?

    How do I reserve CMEM buffer from the kernel module?

    I saw the TI preference for that comm is from the user because of GPL licencing. This is not an issue in this case. A kernel module would be more efficient and remove the burden from the application to access the external CAN as they would be accessed with socketcan just like the 2 internal CAN devices.

    Michel Catudal

    ACTIA Corp

  • Hi Michel,

    Michel Catudal said:

    DSP1 is working. I am puzzled though why the ipu1 and dsp1 communication don't work if I build the remoteproc as modules but it works when they are compiled in.

    What is the error you see when using remoteproc as module?

    Michel Catudal said:

    With RPMsg, how do I choose which core to talk to?

    For information on the kernel interface, you can check the kernel documentation https://www.kernel.org/doc/Documentation/rpmsg.txt

    Michel Catudal said:

    How do I reserve CMEM buffer from the kernel module?

    It needs to be reserved in kernel dt, please see https://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/linuxutils/latest/docs/html/cmem_8h.html for information.

    Thanks,

    Angela