diff options
author | Fabien Dessenne <fabien.dessenne@st.com> | 2019-05-31 16:11:32 +0300 |
---|---|---|
committer | Patrick Delaunay <patrick.delaunay@st.com> | 2019-07-22 10:21:28 +0300 |
commit | 163b7d7706d842517c5c77e649290be557ad578b (patch) | |
tree | 05b055feaaaa9bfc13082f11a6cdf11380ca2d38 | |
parent | 31a839f81972034cae66fdc914a52f36ec489c00 (diff) | |
download | u-boot-163b7d7706d842517c5c77e649290be557ad578b.tar.xz |
remoteproc: add device_to_virt ops
Introduce the device_to_virt function to allow translation between
device address (remote processor view) and virtual address (main
processor view).
Signed-off-by: Loic Pallardy <loic.pallardy@st.com>
Signed-off-by: Fabien Dessenne <fabien.dessenne@st.com>
Reviewed-by: Lokesh Vutla <lokeshvutla@ti.com>
-rw-r--r-- | include/remoteproc.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/include/remoteproc.h b/include/remoteproc.h index aa90a67fba..aef6ff2e49 100644 --- a/include/remoteproc.h +++ b/include/remoteproc.h @@ -113,6 +113,18 @@ struct dm_rproc_ops { * @return 0 on success, 1 if not responding, -ve on other errors. */ int (*ping)(struct udevice *dev); + + /** + * device_to_virt() - Return translated virtual address (optional) + * + * Translate a device address (remote processor view) to virtual + * address (main processor view). + * + * @dev: Remote proc device + * @da: Device address + * @return virtual address. + */ + void * (*device_to_virt)(struct udevice *dev, ulong da); }; /* Accessor */ |