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>
This commit is contained in:
Fabien Dessenne 2019-05-31 15:11:32 +02:00 committed by Patrick Delaunay
parent 31a839f819
commit 163b7d7706

View File

@ -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 */