u-boot.lists.denx.de archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/1] bloblist: use correct types for physical addresses
@ 2025-09-01 15:16 Heinrich Schuchardt
  2025-09-02  4:57 ` Ilias Apalodimas
  0 siblings, 1 reply; 2+ messages in thread
From: Heinrich Schuchardt @ 2025-09-01 15:16 UTC (permalink / raw)
  To: Tom Rini
  Cc: Emil Renner Berthing, Simon Glass, Raymond Mao, Ilias Apalodimas,
	Harrison Mutai, Dan Carpenter, Andrew Goodbody, Patrick Rudolph,
	u-boot, Heinrich Schuchardt

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>
---
 common/bloblist.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/common/bloblist.c b/common/bloblist.c
index 6e4f020d7c4..d5fa62249a9 100644
--- a/common/bloblist.c
+++ b/common/bloblist.c
@@ -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;
-- 
2.50.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH 1/1] bloblist: use correct types for physical addresses
  2025-09-01 15:16 [PATCH 1/1] bloblist: use correct types for physical addresses Heinrich Schuchardt
@ 2025-09-02  4:57 ` Ilias Apalodimas
  0 siblings, 0 replies; 2+ messages in thread
From: Ilias Apalodimas @ 2025-09-02  4:57 UTC (permalink / raw)
  To: Heinrich Schuchardt
  Cc: Tom Rini, Emil Renner Berthing, Simon Glass, Raymond Mao,
	Harrison Mutai, Dan Carpenter, Andrew Goodbody, Patrick Rudolph,
	u-boot

On Mon, 1 Sept 2025 at 18:17, Heinrich Schuchardt
<heinrich.schuchardt@canonical.com> wrote:
>
> 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>
> ---
>  common/bloblist.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/common/bloblist.c b/common/bloblist.c
> index 6e4f020d7c4..d5fa62249a9 100644
> --- a/common/bloblist.c
> +++ b/common/bloblist.c
> @@ -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;
> --
> 2.50.1
>

Reviewed-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-09-02  4:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-01 15:16 [PATCH 1/1] bloblist: use correct types for physical addresses Heinrich Schuchardt
2025-09-02  4:57 ` Ilias Apalodimas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).