diff options
author | Simon Glass <sjg@chromium.org> | 2023-09-26 08:14:35 -0600 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2023-10-06 14:38:12 -0400 |
commit | 2354daaf3946b5d0eefc8c8c87b007b480680df5 (patch) | |
tree | f6b0c31e3a8dc7bc4eb219c928c9b27a39fc9a90 /common | |
parent | 035ab46e3930c8142cae881e08923043632faa51 (diff) | |
download | u-boot-2354daaf3946b5d0eefc8c8c87b007b480680df5.zip u-boot-2354daaf3946b5d0eefc8c8c87b007b480680df5.tar.gz u-boot-2354daaf3946b5d0eefc8c8c87b007b480680df5.tar.bz2 |
spl: Use the correct FIT_..._PROP constants
Rather than open-coding the property names, use the existing constants
provided for this purpose. This better aligns the simple-FIT code with
the full FIT implementation.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'common')
-rw-r--r-- | common/spl/spl_fit.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/common/spl/spl_fit.c b/common/spl/spl_fit.c index 9373a56..93480a5 100644 --- a/common/spl/spl_fit.c +++ b/common/spl/spl_fit.c @@ -44,7 +44,7 @@ static int find_node_from_desc(const void *fit, int node, const char *str) for (child = fdt_first_subnode(fit, node); child >= 0; child = fdt_next_subnode(fit, child)) { int len; - const char *desc = fdt_getprop(fit, child, "description", &len); + const char *desc = fdt_getprop(fit, child, FIT_DESC_PROP, &len); if (!desc) continue; @@ -476,10 +476,11 @@ static int spl_fit_record_loadable(const struct spl_fit_info *ctx, int index, node = spl_fit_get_image_node(ctx, "loadables", index); ret = fdt_record_loadable(blob, index, name, image->load_addr, - image->size, image->entry_point, - fdt_getprop(ctx->fit, node, "type", NULL), - fdt_getprop(ctx->fit, node, "os", NULL), - fdt_getprop(ctx->fit, node, "arch", NULL)); + image->size, image->entry_point, + fdt_getprop(ctx->fit, node, FIT_TYPE_PROP, NULL), + fdt_getprop(ctx->fit, node, FIT_OS_PROP, NULL), + fdt_getprop(ctx->fit, node, FIT_ARCH_PROP, NULL)); + return ret; } |