Re: [U-Boot] [PATCH 3/7] remoteproc: add da_to_pa ops

2019-05-22 Thread Simon Glass
Hi Fabien,

On Wed, 22 May 2019 at 02:07, Fabien Dessenne  wrote:
>
> This patch introduces da_to_pa function to allow translation
> between device address (remote processor view) and physical
> address (main processor view).
>
> Signed-off-by: Loic Pallardy 
> Signed-off-by: Fabien Dessenne 
> ---
>  include/remoteproc.h | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/include/remoteproc.h b/include/remoteproc.h
> index a59dba8..58df11a 100644
> --- a/include/remoteproc.h
> +++ b/include/remoteproc.h
> @@ -63,6 +63,8 @@ struct dm_rproc_uclass_pdata {
>   * Return 0 on success, 1 if not running, -ve on others errors
>   * @ping:  Ping the remote device for basic communication check(optional)
>   * Return 0 on success, 1 if not responding, -ve on other errors
> + * @da_to_pa:   Return translated physical address (device address different
> + *  from physical address)

How about device_addr_to_phys()?

Also please add a full function comment here and below. This uclass
header seems to be delinquent.

>   */
>  struct dm_rproc_ops {
> int (*init)(struct udevice *dev);
> @@ -72,6 +74,7 @@ struct dm_rproc_ops {
> int (*reset)(struct udevice *dev);
> int (*is_running)(struct udevice *dev);
> int (*ping)(struct udevice *dev);
> +   ulong (*da_to_pa)(struct udevice *dev, ulong da);
>  };
>
>  /* Accessor */
> --
> 2.7.4
>

Regards,
Simon
___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot


[U-Boot] [PATCH 3/7] remoteproc: add da_to_pa ops

2019-05-22 Thread Fabien Dessenne
This patch introduces da_to_pa function to allow translation
between device address (remote processor view) and physical
address (main processor view).

Signed-off-by: Loic Pallardy 
Signed-off-by: Fabien Dessenne 
---
 include/remoteproc.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/include/remoteproc.h b/include/remoteproc.h
index a59dba8..58df11a 100644
--- a/include/remoteproc.h
+++ b/include/remoteproc.h
@@ -63,6 +63,8 @@ struct dm_rproc_uclass_pdata {
  * Return 0 on success, 1 if not running, -ve on others errors
  * @ping:  Ping the remote device for basic communication check(optional)
  * Return 0 on success, 1 if not responding, -ve on other errors
+ * @da_to_pa:   Return translated physical address (device address different
+ *  from physical address)
  */
 struct dm_rproc_ops {
int (*init)(struct udevice *dev);
@@ -72,6 +74,7 @@ struct dm_rproc_ops {
int (*reset)(struct udevice *dev);
int (*is_running)(struct udevice *dev);
int (*ping)(struct udevice *dev);
+   ulong (*da_to_pa)(struct udevice *dev, ulong da);
 };
 
 /* Accessor */
-- 
2.7.4

___
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot