[U-Boot] [PATCH v4 02/17] reset: Return 0 if no request ops

Simon Glass sjg at chromium.org
Thu Aug 30 00:28:02 UTC 2018


Hi Jagan,

On 26 August 2018 at 06:38, Jagan Teki <jagan at amarulasolutions.com> wrote:
> Missing request ops from respective uclass driver
> generating "synchronous abort" in Allwinner platform,
> may be in arm. So return 0 if request ops is not used
> for those uclass drivers.
>
> Cc: Simon Glass <sjg at chromium.org>
> Signed-off-by: Jagan Teki <jagan at amarulasolutions.com>
> ---
>  drivers/reset/reset-uclass.c | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/drivers/reset/reset-uclass.c b/drivers/reset/reset-uclass.c
> index 3899537635..867dc8d596 100644
> --- a/drivers/reset/reset-uclass.c
> +++ b/drivers/reset/reset-uclass.c
> @@ -69,6 +69,9 @@ int reset_get_by_index(struct udevice *dev, int index,
>                 return ret;
>         }
>
> +       if (!ops->request)
> +               return 0;
> +

Shouldn't this return -ENOSYS? The system call is missing.

>         ret = ops->request(reset_ctl);
>         if (ret) {
>                 debug("ops->request() failed: %d\n", ret);
> --
> 2.18.0.321.gffc6fa0e3
>

Regards,
Simon


More information about the U-Boot mailing list