]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
bloblist: use correct types for physical addresses
authorHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Mon, 1 Sep 2025 15:16:35 +0000 (17:16 +0200)
committerTom Rini <trini@konsulko.com>
Fri, 12 Sep 2025 19:49:34 +0000 (13:49 -0600)
It is expected that bloblists are stored in high memory beyond 2 GiB.
We must not use int as data type for these addresses but phys_addr_t.

Fixes: f9ef9fb033d5 ("bloblist: Handle alignment with a void entry")
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
common/bloblist.c

index 6e4f020d7c46642b3a05f8469b3005dd26ea93be..d5fa62249a9301f9219718d30c4898a63c0961c0 100644 (file)
@@ -149,7 +149,8 @@ static int bloblist_addrec(uint tag, int size, int align_log2,
 {
        struct bloblist_hdr *hdr = gd->bloblist;
        struct bloblist_rec *rec;
-       int data_start, aligned_start, new_alloced;
+       phys_addr_t data_start, aligned_start;
+       phys_size_t new_alloced;
 
        if (!align_log2)
                align_log2 = BLOBLIST_BLOB_ALIGN_LOG2;