aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/soc/qcom/smd.h
diff options
context:
space:
mode:
authorBjorn Andersson <bjorn.andersson@linaro.org>2016-08-15 14:15:57 -0400
committerAndy Gross <andy.gross@linaro.org>2016-08-23 16:46:33 -0400
commitda0573026c2d3d445c39385024bfc3ce6beebe09 (patch)
treee65621f29dd3c430f5005411730ce4fa2b9232c4 /include/linux/soc/qcom/smd.h
parent381a0b4ce45b2ad809b79049e6316a83d5eaa2ea (diff)
soc: qcom: smd: Represent smd edges as devices
By representing each edge as its own device the channels are no longer tied to being parented by the same smd device and as such an edge can live as children of e.g. remoteproc instances. Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Andy Gross <andy.gross@linaro.org>
Diffstat (limited to 'include/linux/soc/qcom/smd.h')
-rw-r--r--include/linux/soc/qcom/smd.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/include/linux/soc/qcom/smd.h b/include/linux/soc/qcom/smd.h
index 324b1decfffb..f148e0ffbec7 100644
--- a/include/linux/soc/qcom/smd.h
+++ b/include/linux/soc/qcom/smd.h
@@ -61,6 +61,10 @@ void qcom_smd_set_drvdata(struct qcom_smd_channel *channel, void *data);
61int qcom_smd_send(struct qcom_smd_channel *channel, const void *data, int len); 61int qcom_smd_send(struct qcom_smd_channel *channel, const void *data, int len);
62 62
63 63
64struct qcom_smd_edge *qcom_smd_register_edge(struct device *parent,
65 struct device_node *node);
66int qcom_smd_unregister_edge(struct qcom_smd_edge *edge);
67
64#else 68#else
65 69
66static inline int qcom_smd_driver_register(struct qcom_smd_driver *drv) 70static inline int qcom_smd_driver_register(struct qcom_smd_driver *drv)
@@ -111,6 +115,20 @@ static inline int qcom_smd_send(struct qcom_smd_channel *channel,
111 return -ENXIO; 115 return -ENXIO;
112} 116}
113 117
118static inline struct qcom_smd_edge *
119qcom_smd_register_edge(struct device *parent,
120 struct device_node *node)
121{
122 return ERR_PTR(-ENXIO);
123}
124
125static inline int qcom_smd_unregister_edge(struct qcom_smd_edge *edge)
126{
127 /* This shouldn't be possible */
128 WARN_ON(1);
129 return -ENXIO;
130}
131
114#endif 132#endif
115 133
116#define module_qcom_smd_driver(__smd_driver) \ 134#define module_qcom_smd_driver(__smd_driver) \