[Concept,v2,12/22] efi: app: Tidy up some stale comments in setup_memory()

Message ID 20250819185900.835939-13-sjg@u-boot.org
State New
Headers
Series efi: Improvements for the EFI app on ARM |

Commit Message

Simon Glass Aug. 19, 2025, 6:58 p.m. UTC
  From: Simon Glass <sjg@chromium.org>

A few comments are out of date. Drop the one about global_data_ptr and
reword the one about memory above 4GB.

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

(no changes since v1)

 lib/efi_client/efi_app.c | 9 ++-------
 1 file changed, 2 insertions(+), 7 deletions(-)
  

Patch

diff --git a/lib/efi_client/efi_app.c b/lib/efi_client/efi_app.c
index 75ebe3a9719..764e562692e 100644
--- a/lib/efi_client/efi_app.c
+++ b/lib/efi_client/efi_app.c
@@ -92,11 +92,6 @@  static efi_status_t setup_memory(struct efi_priv *priv)
 	efi_status_t ret;
 	int pages;
 
-	/*
-	 * Use global_data_ptr instead of gd since it is an assignment. There
-	 * are very few assignments to global_data in U-Boot and this makes
-	 * it easier to find them.
-	 */
 	ptr = efi_malloc(priv, sizeof(*ptr), &ret);
 	if (!ptr)
 		return ret;
@@ -111,8 +106,8 @@  static efi_status_t setup_memory(struct efi_priv *priv)
 	pages = CONFIG_EFI_RAM_SIZE >> 12;
 
 	/*
-	 * Don't allocate any memory above 4GB. U-Boot is a 32-bit application
-	 * so we want it to load below 4GB.
+	 * Try not to allocate any memory above 4GB, just for ease of looking at
+	 * addresses.
 	 */
 	addr = 1ULL << 32;
 	ret = boot->allocate_pages(EFI_ALLOCATE_MAX_ADDRESS,