fdtdec: Reorder fdtdec_set_carveout() parameters for consistency

The fdtdec_set_carveout() function's parameters are inconsistent with
the parameters passed to fdtdec_add_reserved_memory(). Fix up the order
to make it more consistent.

Signed-off-by: Thierry Reding <treding@nvidia.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Tom Warren <twarren@nvidia.com>
This commit is contained in:
Thierry Reding
2021-10-13 14:18:30 -07:00
committed by Tom Warren
parent 46cb067803
commit 9019487608
7 changed files with 21 additions and 24 deletions
+3 -3
View File
@@ -1523,9 +1523,9 @@ skip_compat:
}
int fdtdec_set_carveout(void *blob, const char *node, const char *prop_name,
unsigned int index, const char *name,
const char **compatibles, unsigned int count,
const struct fdt_memory *carveout)
unsigned int index, const struct fdt_memory *carveout,
const char *name, const char **compatibles,
unsigned int count)
{
uint32_t phandle;
int err, offset, len;
+2 -2
View File
@@ -189,8 +189,8 @@ static int make_fdt_carveout_device(void *fdt, uint32_t na, uint32_t ns)
offset = CHECK(fdt_add_subnode(fdt, 0, name + 1));
CHECK(fdt_setprop(fdt, offset, "reg", cells, (na + ns) * sizeof(*cells)));
return fdtdec_set_carveout(fdt, name, "memory-region", 0,
"framebuffer", NULL, 0, &carveout);
return fdtdec_set_carveout(fdt, name, "memory-region", 0, &carveout,
"framebuffer", NULL, 0);
}
static int check_fdt_carveout(void *fdt, uint32_t address_cells,