aboutsummaryrefslogtreecommitdiff
path: root/tools/rkcommon.c
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2020-05-22 10:28:38 -0400
committerTom Rini <trini@konsulko.com>2020-05-22 10:28:38 -0400
commitf53c2dc162d0c62debd0ebb88383e3b6fee95c10 (patch)
treea2705fe5047277b8df937fbad7895b7cc7a2bd6e /tools/rkcommon.c
parenta9f793a30dc091290dddae1d8d3798d25e39c710 (diff)
parent33863f744d513f5c16a254870e7b3cef8580bbc9 (diff)
Merge tag 'u-boot-rockchip-20200522' of https://gitlab.denx.de/u-boot/custodians/u-boot-rockchip
- Fix rk3288 chromebook veyron support; - Add pcie driver support for rk3399; - other fixes for rk3399 boards
Diffstat (limited to 'tools/rkcommon.c')
-rw-r--r--tools/rkcommon.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/tools/rkcommon.c b/tools/rkcommon.c
index 8f281f5901..61c392e27d 100644
--- a/tools/rkcommon.c
+++ b/tools/rkcommon.c
@@ -133,7 +133,7 @@ static int rkcommon_get_aligned_size(struct image_tool_params *params,
int rkcommon_check_params(struct image_tool_params *params)
{
- int i;
+ int i, size;
/*
* If this is a operation (list or extract), the don't require
@@ -153,17 +153,17 @@ int rkcommon_check_params(struct image_tool_params *params)
spl_params.boot_file += 1;
}
- spl_params.init_size =
- rkcommon_get_aligned_size(params, spl_params.init_file);
- if (spl_params.init_size < 0)
+ size = rkcommon_get_aligned_size(params, spl_params.init_file);
+ if (size < 0)
return EXIT_FAILURE;
+ spl_params.init_size = size;
/* Boot file is optional, and only for back-to-bootrom functionality. */
if (spl_params.boot_file) {
- spl_params.boot_size =
- rkcommon_get_aligned_size(params, spl_params.boot_file);
- if (spl_params.boot_size < 0)
+ size = rkcommon_get_aligned_size(params, spl_params.boot_file);
+ if (size < 0)
return EXIT_FAILURE;
+ spl_params.boot_size = size;
}
if (spl_params.init_size > rkcommon_get_spl_size(params)) {