Apps: platform info: ZynqMP r5: update IPI info
authorWendy Liang <jliang@xilinx.com>
Thu, 4 Aug 2016 17:02:38 +0000 (10:02 -0700)
committerWendy Liang <jliang@xilinx.com>
Thu, 13 Oct 2016 05:01:47 +0000 (22:01 -0700)
Add sync lock to IPI info, it is used by the remoteproc driver
to know if the vring is signaled by the other end.

This is dependent to the remoteproc driver implementation.

Signed-off-by: Wendy Liang <jliang@xilinx.com>
apps/machine/zynqmp_r5/platform_info.c

index bbca0ee7ba53d98f5c92c3df7f6afa893cd957be..37a49610d0cc7c97ebaf7125ec4b1c369dbe6108 100755 (executable)
@@ -42,6 +42,7 @@
 
 #include "openamp/hil.h"
 #include "openamp/remoteproc_plat.h"
+#include "metal/atomic.h"
 #include "platform_info.h"
 
 #define IPI_CHN_BITMASK                   0x01000000 /* IPI channel bit mask APU<->RPU0 */
@@ -51,6 +52,7 @@
 struct ipi_info {
        uint32_t ipi_chn_mask;
        int need_reg;
+       atomic_int sync;
 };
 /* Reference implementation that show cases platform_get_cpu_info and 
  platform_get_for_firmware API implementation for Bare metal environment */
@@ -58,8 +60,8 @@ struct ipi_info {
 extern struct hil_platform_ops zynqmp_r5_a53_proc_ops;
 
 static struct ipi_info chn_ipi_info[] = {
-       { IPI_CHN_BITMASK, 0},
-       { IPI_CHN_BITMASK, 1},
+       { IPI_CHN_BITMASK, 0, 0},
+       { IPI_CHN_BITMASK, 1, 0},
 };
 
 struct rproc_info_plat_local proc_table = {