[PATCH] uclass: add uclass_find_device_by_phandle_id() helper

Simon Glass sjg at chromium.org
Fri Apr 28 21:20:12 CEST 2023


On Thu, 13 Apr 2023 at 09:16, Rasmus Villemoes
<rasmus.villemoes at prevas.dk> wrote:
>
> The functions uclass_find_device_by_phandle() and
> uclass_get_device_by_phandle_id() both loop over a given uclass
> looking for a device with a given phandle. Factor that out to a common
> helper.
>
> For now, there are no (known potential) users of the new helper
> outside uclass.c, so make it static.
>
> Signed-off-by: Rasmus Villemoes <rasmus.villemoes at prevas.dk>
> ---
>  drivers/core/uclass.c | 42 ++++++++++++++++++------------------------
>  1 file changed, 18 insertions(+), 24 deletions(-)
>

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

Applied to u-boot-dm, thanks!


More information about the U-Boot mailing list