dm: core: Do not stop uclass iteration on error
authorMichal Suchanek <msuchanek@suse.de>
Wed, 12 Oct 2022 19:58:09 +0000 (21:58 +0200)
committerSimon Glass <sjg@chromium.org>
Sat, 29 Oct 2022 13:36:33 +0000 (07:36 -0600)
commitf21954750aa8ed445ab83998bb099e366136c428
treeada26fe279934fbb18d69324010b3ce1f55ffb63
parent4954937d922840c212b7eba297cc2d4779f087ad
dm: core: Do not stop uclass iteration on error

When probing a device fails NULL pointer is returned, and following
devices in uclass list cannot be iterated. Skip to next device on error
instead.

With that the only condition under which these simple iteration
functions return error is when the dm is not initialized at uclass_get
time. This is not all that interesting, change return type to void.

Fixes: 6494d708bf ("dm: Add base driver model support")
Signed-off-by: Michal Suchanek <msuchanek@suse.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
drivers/core/uclass.c
include/dm/uclass.h
test/dm/core.c
test/dm/test-fdt.c