summaryrefslogtreecommitdiff
path: root/arch/arm/include
diff options
context:
space:
mode:
authorYe Li <ye.li@nxp.com>2019-01-30 21:31:27 -0800
committerYe Li <ye.li@nxp.com>2022-04-06 18:03:04 +0800
commit37a0bad89d33c5b2a4493e818de05f07ef425d02 (patch)
tree3710c3a5c3a44a5cd1a038cdb33cb8ab2a6ea118 /arch/arm/include
parentd92995ec7548c861b750fc80f290b9f3e143fc19 (diff)
MLK-20886-2 imx: Add Virtual service glue layer
We use a glue layer to link the low level MU driver and virtual drivers. This glue layer is named to virtual service (iMX VService). Virtual service provides unified interfaces for setup connection with M4, get message buffer and send/receive message, etc. Multiple virtual drivers (i2c, gpio, etc) | iMX Vservice | imx_mu_m4 driver For each virtual device, by default, the Vservice uses the device node property "fsl,vservice-mu" to specify the MU node handler. A override function is also provided, so te ARCH level can define its rule. We will use the override function for dynamically select MU on 8QM/QXP. Signed-off-by: Ye Li <ye.li@nxp.com> (cherry picked from commit 7537b3c0fbe4e2c355bc4ff20613958bdd178bcd) (cherry picked from commit 3caa81795c16a7644f60ed3b9c77030446b49484) (cherry picked from commit 07ebb7da77f39aba02da46979f0516d44c9a6973) (cherry picked from commit ff47f79b9c5950e73af615169136b453529ec82b)
Diffstat (limited to 'arch/arm/include')
-rw-r--r--arch/arm/include/asm/mach-imx/imx_vservice.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/arch/arm/include/asm/mach-imx/imx_vservice.h b/arch/arm/include/asm/mach-imx/imx_vservice.h
new file mode 100644
index 00000000000..9e083e98443
--- /dev/null
+++ b/arch/arm/include/asm/mach-imx/imx_vservice.h
@@ -0,0 +1,24 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright 2019 NXP
+ *
+ */
+
+#ifndef __IMX_VSERVICE_H__
+#define __IMX_VSERVICE_H__
+
+#include <common.h>
+#include <linux/list.h>
+
+struct imx_vservice_channel
+{
+ u32 msg_seq;
+ struct udevice *mu_dev;
+ struct list_head channel_head;
+};
+
+void * imx_vservice_get_buffer(struct imx_vservice_channel *node, u32 size);
+int imx_vservice_blocking_request(struct imx_vservice_channel *node, u8 *buf, u32* size);
+struct imx_vservice_channel * imx_vservice_setup(struct udevice *virt_dev);
+
+#endif