All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] cmd: pxe: Use internal FDT if external one cannot be retrieved
@ 2019-08-23 14:40 Anton Leontiev
  2019-08-26 15:59 ` Stephen Warren
  2019-09-03  7:52 ` [U-Boot] [PATCH v2] cmd: pxe: Use internal FDT if retrieving from FDTDIR fails Anton Leontiev
  0 siblings, 2 replies; 11+ messages in thread
From: Anton Leontiev @ 2019-08-23 14:40 UTC (permalink / raw)
  To: u-boot

From: Anton Leontiev <aleontiev@elvees.com>

Original commit c61d94d86035 ("pxe: implement fdtdir extlinux.conf tag")
states, that if FDT file cannot be retrieved then FDT packaged in
firmware should be used.

If FDT file cannot be retrieved and it is specified explicitly using
FDT keyword then the label is skipped. If it cannot be found in
FDTDIR then internal FDT is tried first.

Signed-off-by: Anton Leontiev <aleontiev@elvees.com>
---
 cmd/pxe.c | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/cmd/pxe.c b/cmd/pxe.c
index 2059975446..28390c114c 100644
--- a/cmd/pxe.c
+++ b/cmd/pxe.c
@@ -795,9 +795,13 @@ static int label_boot(cmd_tbl_t *cmdtp, struct pxe_label *label)
 			int err = get_relfile_envaddr(cmdtp, fdtfile, "fdt_addr_r");
 			free(fdtfilefree);
 			if (err < 0) {
-				printf("Skipping %s for failure retrieving fdt\n",
-						label->name);
-				goto cleanup;
+				bootm_argv[3] = NULL;
+
+				if (label->fdt) {
+					printf("Skipping %s for failure retrieving FDT\n",
+					       label->name);
+					goto cleanup;
+				}
 			}
 		} else {
 			bootm_argv[3] = NULL;
-- 
2.22.1

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2020-12-02 21:21 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-23 14:40 [U-Boot] [PATCH] cmd: pxe: Use internal FDT if external one cannot be retrieved Anton Leontiev
2019-08-26 15:59 ` Stephen Warren
2019-08-29 11:20   ` Anton Leontiev
2019-08-29 20:35     ` Stephen Warren
2019-08-31 19:52       ` Anton Leontiev
2019-09-03 16:16         ` Stephen Warren
2019-09-03  7:52 ` [U-Boot] [PATCH v2] cmd: pxe: Use internal FDT if retrieving from FDTDIR fails Anton Leontiev
2019-09-03 16:18   ` Stephen Warren
2019-09-17  6:07     ` Anton Leontiev
2019-10-15  5:59   ` Anton Leontiev
2020-12-02 21:21   ` Tom Rini

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.