From e63077f60ec743cd5535db2f5d49bbf0e9b95335 Mon Sep 17 00:00:00 2001 From: Ahmad Fatoum Date: Mon, 31 May 2021 09:12:36 +0200 Subject: of: propagate errors inside barebox_register_{of, fdt} into initcalls Errors during device tree registration, while uncommon, are really annoying, because the system may limp along and it's not clear where the misbehavior originates from. Failing the initcall of the device tree would improve user experience in that error case. There is intentionally no early exit on error cases to give barebox a chance to probe the serial driver to actually report errors when DEBUG_LL is disabled. Signed-off-by: Ahmad Fatoum Link: https://lore.barebox.org/20210531071239.30653-4-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer --- arch/sandbox/board/dtb.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'arch/sandbox') diff --git a/arch/sandbox/board/dtb.c b/arch/sandbox/board/dtb.c index 4a8cbfb26f..98d2e774b8 100644 --- a/arch/sandbox/board/dtb.c +++ b/arch/sandbox/board/dtb.c @@ -39,8 +39,6 @@ static int of_sandbox_init(void) if (!dtb) dtb = __dtb_sandbox_start; - barebox_register_fdt(dtb); - - return 0; + return barebox_register_fdt(dtb); } core_initcall(of_sandbox_init); -- cgit v1.2.3