aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/rpmsg
diff options
context:
space:
mode:
authorBjorn Andersson <bjorn.andersson@linaro.org>2016-10-19 22:40:03 -0400
committerBjorn Andersson <bjorn.andersson@linaro.org>2016-11-15 00:52:14 -0500
commit8fc947230fbc5da1d6d198c758b894f847bf2a28 (patch)
tree142843e9c695004c8abdf306dd082bfb1dae9e8c /include/linux/rpmsg
parent7bdc9650f03604b06ba7434fab694e8ae8ca782d (diff)
rpmsg: smd: Expose edge registration functions
The edge registration functions is to be used from a remoteproc driver to register and unregister an edge as the remote processor comes and goes. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Diffstat (limited to 'include/linux/rpmsg')
-rw-r--r--include/linux/rpmsg/qcom_smd.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/include/linux/rpmsg/qcom_smd.h b/include/linux/rpmsg/qcom_smd.h
new file mode 100644
index 000000000000..e674b2e3074b
--- /dev/null
+++ b/include/linux/rpmsg/qcom_smd.h
@@ -0,0 +1,33 @@
1
2#ifndef _LINUX_RPMSG_QCOM_SMD_H
3#define _LINUX_RPMSG_QCOM_SMD_H
4
5#include <linux/device.h>
6
7struct qcom_smd_edge;
8
9#if IS_ENABLED(CONFIG_RPMSG_QCOM_SMD) || IS_ENABLED(CONFIG_QCOM_SMD)
10
11struct qcom_smd_edge *qcom_smd_register_edge(struct device *parent,
12 struct device_node *node);
13int qcom_smd_unregister_edge(struct qcom_smd_edge *edge);
14
15#else
16
17static inline struct qcom_smd_edge *
18qcom_smd_register_edge(struct device *parent,
19 struct device_node *node)
20{
21 return ERR_PTR(-ENXIO);
22}
23
24static inline int qcom_smd_unregister_edge(struct qcom_smd_edge *edge)
25{
26 /* This shouldn't be possible */
27 WARN_ON(1);
28 return -ENXIO;
29}
30
31#endif
32
33#endif