summaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorSafae Ouajih <souajih@baylibre.com>2023-02-06 00:50:05 +0100
committerPraneeth Bajjuri <praneeth@ti.com>2023-04-05 11:32:28 -0500
commit94dfef61a70808656bed741c133cdd7d5d3fb810 (patch)
treeef2b8897da04c20c7be4563c01b3b9f5931156be /cmd
parent2df42cde901dd55641260e88f2397cf8f4a99f58 (diff)
android: boot: replace android_image_check_header
commit 734cb47d6de16d2e3b52a03bce5daab40e5bb29d upstream. With the new vendor boot image introduced in versions 3 and 4 of boot image header, the header check must be done for both boot image and vendor boot image. Thus, replace android_image_check_header() by is_android_boot_image_header() to only refer to boot image header check. Signed-off-by: Safae Ouajih <souajih@baylibre.com> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Tested-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Signed-off-by: Praneeth Bajjuri <praneeth@ti.com>
Diffstat (limited to 'cmd')
-rw-r--r--cmd/abootimg.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmd/abootimg.c b/cmd/abootimg.c
index 026c03f91c..b5cfb141ef 100644
--- a/cmd/abootimg.c
+++ b/cmd/abootimg.c
@@ -26,7 +26,7 @@ static int abootimg_get_ver(int argc, char *const argv[])
return CMD_RET_USAGE;
hdr = map_sysmem(abootimg_addr(), sizeof(*hdr));
- if (android_image_check_header(hdr)) {
+ if (!is_android_boot_image_header(hdr)) {
printf("Error: Boot Image header is incorrect\n");
res = CMD_RET_FAILURE;
goto exit;
@@ -73,7 +73,7 @@ static int abootimg_get_dtb_load_addr(int argc, char *const argv[])
return CMD_RET_USAGE;
hdr = map_sysmem(abootimg_addr(), sizeof(*hdr));
- if (android_image_check_header(hdr)) {
+ if (!is_android_boot_image_header(hdr)) {
printf("Error: Boot Image header is incorrect\n");
res = CMD_RET_FAILURE;
goto exit;