Apps: remoteproc slave: user libmetal dev
authorWendy Liang <jliang@xilinx.com>
Thu, 4 Aug 2016 18:34:49 +0000 (11:34 -0700)
committerWendy Liang <jliang@xilinx.com>
Thu, 13 Oct 2016 05:01:46 +0000 (22:01 -0700)
Update the remoteproc slave applications to use libmetal device
for platform initialization.

Signed-off-by: Wendy Liang <jliang@xilinx.com>
apps/echo_test/echo_testd.c
apps/func_test_suite/func_test_suite.c
apps/matrix_multiply/matrix_multiplyd.c
apps/rpc_demo/rpc_demo.c

index d7f8b11e0a1187cde7f88beb5373c04b9454e579..29371a3152b40fa9d6e3e670bdef8610e01ca2f3 100644 (file)
@@ -7,6 +7,7 @@ This application echoes back data that was sent to it by the master core. */
 #include <string.h>
 #include "openamp/open_amp.h"
 #include "rsc_table.h"
+#include "platform_info.h"
 
 #ifdef ZYNQ7_BAREMETAL
 #include "baremetal.h"
@@ -25,7 +26,7 @@ static struct rpmsg_endpoint *rp_ept;
 static struct remote_proc *proc = NULL;
 static struct rsc_table_info rsc_info;
 extern const struct remote_resource_table resources;
-extern struct hil_proc proc_table[];
+extern struct rproc_info_plat_local proc_table;
 
 /* External functions */
 extern void init_system();
@@ -48,7 +49,7 @@ int main()
 
        /* Initialize RPMSG framework */
        status =
-           remoteproc_resource_init(&rsc_info, &proc_table[0],
+           remoteproc_resource_init(&rsc_info, &proc_table,
                                     rpmsg_channel_created,
                                     rpmsg_channel_deleted, rpmsg_read_cb,
                                     &proc, 0);
index f0b2dbe2b21569455ef57cf5a37644c5429757dd..73f22ba947c9baf017ca1a347c53649c38866513 100644 (file)
@@ -8,6 +8,7 @@
 #include "openamp/open_amp.h"
 #include "rsc_table.h"
 #include "test_suite.h"
+#include "platform_info.h"
 
 #ifdef ZYNQ7_BAREMETAL
 #include "baremetal.h"
@@ -35,7 +36,7 @@ static char firmware_name[] = "baremetal-fn-test-suite-remote-firmware";
 static char r_buffer[512];
 static struct rsc_table_info rsc_info;
 extern const struct remote_resource_table resources;
-extern struct hil_proc proc_table[];
+extern struct rproc_info_plat_local proc_table;
 
 /* External functions */
 extern void init_system();
@@ -60,7 +61,7 @@ int main()
 
        /* This API creates the virtio devices for this remote node and initializes
           other relevant resources defined in the resource table */
-       remoteproc_resource_init(&rsc_info, &proc_table[0],
+       remoteproc_resource_init(&rsc_info, &proc_table,
                                 rpmsg_channel_created,
                                 rpmsg_channel_deleted, rpmsg_read_default_cb,
                                 &proc, 0);
index 46a0049398cd8d8fc79725d6f4b9c442b691f352..e253d66d283ba45162c6a690886dfc3cf41339fd 100644 (file)
@@ -8,6 +8,7 @@ multiplies them and returns the result to the master core. */
 #include <string.h>
 #include "openamp/open_amp.h"
 #include "rsc_table.h"
+#include "platform_info.h"
 
 #ifdef ZYNQ7_BAREMETAL
 #include "baremetal.h"
@@ -39,7 +40,7 @@ static matrix matrix_result;
 static struct remote_proc *proc = NULL;
 static struct rsc_table_info rsc_info;
 extern const struct remote_resource_table resources;
-extern struct hil_proc proc_table[];
+extern struct rproc_info_plat_local proc_table;
 
 /* External functions */
 extern void init_system();
@@ -63,7 +64,7 @@ int main()
 
        /* Initialize RPMSG framework */
        status =
-           remoteproc_resource_init(&rsc_info, &proc_table[0],
+           remoteproc_resource_init(&rsc_info, &proc_table,
                                     rpmsg_channel_created,
                                     rpmsg_channel_deleted, rpmsg_read_cb,
                                     &proc, 0);
index 0590ba4be9d9f3445da6f564297d60b3f74e55e1..611067d2fc1d809a4d026a49fca38c795202fc0a 100755 (executable)
@@ -9,6 +9,7 @@
 #include <unistd.h>
 #include "openamp/open_amp.h"
 #include "rsc_table.h"
+#include "platform_info.h"
 #include "openamp/rpmsg_retarget.h"
 
 #ifdef ZYNQ7_BAREMETAL
@@ -28,7 +29,7 @@ volatile int chnl_cb_flag = 0;
 static struct remote_proc *proc = NULL;
 static struct rsc_table_info rsc_info;
 extern const struct remote_resource_table resources;
-extern struct hil_proc proc_table[];
+extern struct rproc_info_plat_local proc_table;
 
 /* External functions */
 extern void init_system();
@@ -68,7 +69,7 @@ int main()
        rsc_info.size = sizeof(resources);
 
        /* Initialize RPMSG framework */
-       status = remoteproc_resource_init(&rsc_info, &proc_table[0],
+       status = remoteproc_resource_init(&rsc_info, &proc_table,
                                          rpmsg_channel_created,
                                          rpmsg_channel_deleted, rpmsg_read_cb,
                                          &proc, 0);