From: Daan De Meyer <[email protected]>

For consistency with LOAD_IMAGE_MAX_DECOMPRESSED_BYTES.

Signed-off-by: Daan De Meyer <[email protected]>
Reviewed-by: Philippe Mathieu-Daudé <[email protected]>
Tested-by: Philippe Mathieu-Daudé <[email protected]>
Message-ID: <[email protected]>
Signed-off-by: Philippe Mathieu-Daudé <[email protected]>
---
 include/hw/core/loader.h | 2 +-
 hw/core/loader-fit.c     | 2 +-
 hw/core/loader.c         | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/include/hw/core/loader.h b/include/hw/core/loader.h
index 1f14dccbca9..dd22cbb5e85 100644
--- a/include/hw/core/loader.h
+++ b/include/hw/core/loader.h
@@ -345,7 +345,7 @@ ssize_t rom_add_option(const char *file, int32_t bootindex);
 
 /* This is the usual maximum in uboot, so if a uImage overflows this, it would
  * overflow on real hardware too. */
-#define UBOOT_MAX_GUNZIP_BYTES (64 << 20)
+#define UBOOT_MAX_DECOMPRESSED_BYTES (64 << 20)
 
 typedef struct RomGap {
     hwaddr base;
diff --git a/hw/core/loader-fit.c b/hw/core/loader-fit.c
index 233a7f78c24..d29b2ff2231 100644
--- a/hw/core/loader-fit.c
+++ b/hw/core/loader-fit.c
@@ -70,7 +70,7 @@ static void *fit_load_image_alloc(const void *itb, const char 
*name,
     }
 
     if (!strcmp(comp, "gzip")) {
-        uncomp_len = UBOOT_MAX_GUNZIP_BYTES;
+        uncomp_len = UBOOT_MAX_DECOMPRESSED_BYTES;
         uncomp_data = g_malloc(uncomp_len);
 
         uncomp_len = gunzip(uncomp_data, uncomp_len, (void *) data, sz);
diff --git a/hw/core/loader.c b/hw/core/loader.c
index 79cb96b4664..21204a0cb91 100644
--- a/hw/core/loader.c
+++ b/hw/core/loader.c
@@ -754,7 +754,7 @@ static ssize_t load_uboot_image(const char *filename, 
hwaddr *ep,
         ssize_t bytes;
 
         compressed_data = data;
-        max_bytes = UBOOT_MAX_GUNZIP_BYTES;
+        max_bytes = UBOOT_MAX_DECOMPRESSED_BYTES;
         data = g_malloc(max_bytes);
 
         bytes = gunzip(data, max_bytes, compressed_data, hdr->ih_size);
-- 
2.52.0


Reply via email to