U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: <rs@ti.com>
To: <robertcnelson@gmail.com>, <ayush@beagleboard.org>,
	<Erik.Welsh@octavosystems.com>, <anshuld@ti.com>, <bb@ti.com>,
	<trini@konsulko.com>, <afd@ti.com>, <xypron.glpk@gmx.de>,
	<ilias.apalodimas@linaro.org>, <sjg@chromium.org>
Cc: <u-boot@lists.denx.de>
Subject: [PATCHv6 1/3] sandbox: add board_get_usable_ram_top
Date: Fri, 8 May 2026 17:29:09 -0500	[thread overview]
Message-ID: <20260508222911.450165-2-rs@ti.com> (raw)
In-Reply-To: <20260508222911.450165-1-rs@ti.com>

From: Randolph Sapp <rs@ti.com>

Add a board_get_usable_ram_top definition, since currently ram_top is
equal to ram_size. Attempting to actually map ram_size with map_sysmem
results in a fault.

Signed-off-by: Randolph Sapp <rs@ti.com>
---
 board/sandbox/sandbox.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/board/sandbox/sandbox.c b/board/sandbox/sandbox.c
index 13006a0ffc2..88c7636d3ca 100644
--- a/board/sandbox/sandbox.c
+++ b/board/sandbox/sandbox.c
@@ -105,6 +105,11 @@ int dram_init(void)
 	return 0;
 }
 
+phys_addr_t board_get_usable_ram_top(phys_size_t total_size)
+{
+	return gd->ram_size - 1;
+}
+
 int ft_board_setup(void *fdt, struct bd_info *bd)
 {
 	/* Create an arbitrary reservation to allow testing OF_BOARD_SETUP.*/
-- 
2.54.0


  reply	other threads:[~2026-05-08 22:29 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-08 22:29 [PATCHv6 0/3] various memory related fixups rs
2026-05-08 22:29 ` rs [this message]
2026-05-11 18:26   ` [PATCHv6 1/3] sandbox: add board_get_usable_ram_top Simon Glass
2026-05-11 18:44     ` Randolph Sapp
2026-05-11 19:22       ` Simon Glass
2026-05-08 22:29 ` [PATCHv6 2/3] boot_fdt_add_mem_rsv_regions: free old dtb reservations rs
2026-05-11 18:27   ` Simon Glass
2026-05-11 23:17     ` Randolph Sapp
2026-05-08 22:29 ` [PATCHv6 3/3] memory: reserve from start_addr_sp to initial_relocaddr rs
2026-05-11 18:28   ` Simon Glass
2026-05-11 19:41     ` Randolph Sapp
2026-05-13 16:39       ` Simon Glass
2026-05-11 18:28 ` [PATCHv6,0/3] various memory related fixups Simon Glass

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=20260508222911.450165-2-rs@ti.com \
    --to=rs@ti.com \
    --cc=Erik.Welsh@octavosystems.com \
    --cc=afd@ti.com \
    --cc=anshuld@ti.com \
    --cc=ayush@beagleboard.org \
    --cc=bb@ti.com \
    --cc=ilias.apalodimas@linaro.org \
    --cc=robertcnelson@gmail.com \
    --cc=sjg@chromium.org \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    --cc=xypron.glpk@gmx.de \
    /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