diff mbox series

of/fdt: don't ignore errors from of_setup_earlycon

Message ID 20190910055833.28324-1-hch@lst.de
State Accepted, archived
Headers show
Series of/fdt: don't ignore errors from of_setup_earlycon | expand

Checks

Context Check Description
robh/checkpatch success

Commit Message

Christoph Hellwig Sept. 10, 2019, 5:58 a.m. UTC
If of_setup_earlycon we should keep on iterating earlycon options
instead of breaking out of the loop.

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 drivers/of/fdt.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Rob Herring Sept. 30, 2019, 2:19 p.m. UTC | #1
On Tue, 10 Sep 2019 07:58:33 +0200, Christoph Hellwig wrote:
> If of_setup_earlycon we should keep on iterating earlycon options
> instead of breaking out of the loop.
> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> ---
>  drivers/of/fdt.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 

Applied, thanks.

Rob
diff mbox series

Patch

diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c
index 9cdf14b9aaab..2f6bd03d8e27 100644
--- a/drivers/of/fdt.c
+++ b/drivers/of/fdt.c
@@ -946,8 +946,8 @@  int __init early_init_dt_scan_chosen_stdout(void)
 		if (fdt_node_check_compatible(fdt, offset, match->compatible))
 			continue;
 
-		of_setup_earlycon(match, offset, options);
-		return 0;
+		if (of_setup_earlycon(match, offset, options) == 0)
+			return 0;
 	}
 	return -ENODEV;
 }