[PATCH 1/5] dm: gpio: Fix gpio_get_list_count failing with livetree

Simon Glass sjg at chromium.org
Fri Mar 5 05:08:24 CET 2021


On Mon, 1 Mar 2021 at 15:46, Sean Anderson <sean.anderson at seco.com> wrote:
>
> of_parse_phandle_with_args (called by dev_read_phandle_with_args) does not
> support getting the length of a phandle list by using the index -1.
> Instead, use dev_count_phandle_with_args which supports exactly this
> use-case.
>
> Fixes: 3669e0e759 ("dm: gpio: Add better functions to request GPIOs")
>
> Signed-off-by: Sean Anderson <sean.anderson at seco.com>
> ---
>
>  drivers/gpio/gpio-uclass.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

Reviewed-by: Simon Glass <sjg at chromium.org>


More information about the U-Boot mailing list