diff mbox series

[06/12] bloblist: Place on a 4KB boundary

Message ID 20200928004624.1652803-7-sjg@chromium.org
State Accepted
Commit 4a08fae1963e18d4c7d030ceade3c6c966f873ad
Delegated to: Tom Rini
Headers show
Series Various minor patches | expand

Commit Message

Simon Glass Sept. 28, 2020, 12:46 a.m. UTC
It is much easier to read the bloblist addresses if it starts on a 4KB
boundary. Update it to align it accordingly.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

 common/board_f.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Comments

Tom Rini Oct. 23, 2020, 12:26 a.m. UTC | #1
On Sun, Sep 27, 2020 at 06:46:18PM -0600, Simon Glass wrote:

> It is much easier to read the bloblist addresses if it starts on a 4KB
> boundary. Update it to align it accordingly.
> 
> Signed-off-by: Simon Glass <sjg@chromium.org>

Applied to u-boot/master, thanks!
diff mbox series

Patch

diff --git a/common/board_f.c b/common/board_f.c
index 62473abf793..e99277d7e88 100644
--- a/common/board_f.c
+++ b/common/board_f.c
@@ -573,7 +573,9 @@  static int reserve_stacks(void)
 static int reserve_bloblist(void)
 {
 #ifdef CONFIG_BLOBLIST
-	gd->start_addr_sp = reserve_stack_aligned(CONFIG_BLOBLIST_SIZE);
+	/* Align to a 4KB boundary for easier reading of addresses */
+	gd->start_addr_sp = ALIGN_DOWN(gd->start_addr_sp - CONFIG_BLOBLIST_SIZE,
+				       0x1000);
 	gd->new_bloblist = map_sysmem(gd->start_addr_sp, CONFIG_BLOBLIST_SIZE);
 #endif