From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH] fixup! fastboot: scale default sparse max_download_size with available memory
Date: Fri, 25 Aug 2023 19:29:39 +0200 [thread overview]
Message-ID: <20230825172939.2857999-1-a.fatoum@pengutronix.de> (raw)
In-Reply-To: <20230825172250.2857448-1-a.fatoum@pengutronix.de>
mem_malloc_end is the end address, so we need to add one to get the size
out.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
Forgot to squash
---
include/memory.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/memory.h b/include/memory.h
index 73642dd5aaa5..9c2a037610b6 100644
--- a/include/memory.h
+++ b/include/memory.h
@@ -12,7 +12,7 @@ ulong mem_malloc_end(void);
static inline ulong mem_malloc_size(void)
{
- return mem_malloc_end() - mem_malloc_start();
+ return mem_malloc_end() - mem_malloc_start() + 1;
}
struct memory_bank {
--
2.39.2
next prev parent reply other threads:[~2023-08-25 17:30 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-25 17:22 [PATCH] " Ahmad Fatoum
2023-08-25 17:29 ` Ahmad Fatoum [this message]
2023-08-28 7:57 ` [PATCH] fixup! " Sascha Hauer
2023-08-28 6:19 ` [PATCH] " Johannes Zink
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230825172939.2857999-1-a.fatoum@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox