mirror of
https://github.com/dgibson/dtc.git
synced 2026-04-11 16:37:42 -04:00
fdtdump: Change FDT_PROP prob handling to ease future addition
In order to ease future tags addition, perform operation related to FDT_PROP when the tag is explicitly FDT_PROP instead of relying to a kind of default value case. Handle the FDT_PROP tag exactly in the same way as it is done for other tags. No functional modification. Signed-off-by: Herve Codina <herve.codina@bootlin.com> Message-ID: <20260112142009.1006236-6-herve.codina@bootlin.com> Reviewed-by: Ayush Singh <ayush@beagleboard.org> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
9a1c801a1a
commit
14dd76b967
1 changed files with 17 additions and 15 deletions
10
fdtdump.c
10
fdtdump.c
|
|
@ -129,10 +129,7 @@ static void dump_blob(void *blob, bool debug)
|
|||
continue;
|
||||
}
|
||||
|
||||
if (tag != FDT_PROP) {
|
||||
fprintf(stderr, "%*s ** Unknown tag 0x%08"PRIx32"\n", depth * shift, "", tag);
|
||||
break;
|
||||
}
|
||||
if (tag == FDT_PROP) {
|
||||
sz = fdt32_to_cpu(GET_CELL(p));
|
||||
s = p_strings + fdt32_to_cpu(GET_CELL(p));
|
||||
if (version < 16 && sz >= 8)
|
||||
|
|
@ -146,6 +143,11 @@ static void dump_blob(void *blob, bool debug)
|
|||
printf("%*s%s", depth * shift, "", s);
|
||||
utilfdt_print_data(t, sz);
|
||||
printf(";\n");
|
||||
continue;
|
||||
}
|
||||
|
||||
fprintf(stderr, "%*s ** Unknown tag 0x%08"PRIx32"\n", depth * shift, "", tag);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue