Skip to contentSkip to conversation

bootmenu: rename U-Boot console to Exit

PATCH In review Svyatoslav Ryhel 2 participants 3 messages Jan 17, 2024 – Jan 25, 2024

lore
Share & tools
lore
#0 lore raw

v2 cover bootmenu: rename U-Boot console to Exit

It seems that the U-Boot console entry of the bootmenu has lost its original meaning. Now, even if it is chosen, the probability that you will enter the actual U-Boot console is quite low. Boot env, bootflow, bootcommand script may appear, but not the actual console. Hense, let's remove ambiguity and name this entry by what it actually does: 'Exit' the bootmenu.

---
Changes in v2
- fixed typo in commit message
- slightly modified comments in the code
---

Svyatoslav Ryhel (1):
cmd: bootmenu: rename U-Boot console to Exit

 cmd/bootmenu.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
Signature · 1 line
2.40.1
#1 lore raw

PATCH v2 1/1 cmd: bootmenu: rename U-Boot console to Exit

It seems that the U-Boot console entry of the bootmenu has lost its original meaning. Now, even if it is chosen, the probability that you will enter the actual U-Boot console is quite low. Boot env, bootflow, bootcommand script may appear, but not the actual console. Hence, let's remove ambiguity and name this entry by what it actually does: 'Exit' the bootmenu.

---
 cmd/bootmenu.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
cmd/bootmenu.c +5 -5
index 987b16889f..78184fccab 100644
@@ -119,7 +119,7 @@ static char *bootmenu_choice_entry(void *data)
 				iter = iter->next;
 			return iter->key;
 		case BKEY_QUIT:
-			/* Quit by choosing the last entry - U-Boot console */
+			/* Quit by choosing the last entry */
 			iter = menu->first;
 			while (iter->next)
 				iter = iter->next;
@@ -361,15 +361,15 @@ static struct bootmenu_data *bootmenu_create(int delay)
 	}
 #endif
 
-	/* Add U-Boot console entry at the end */
+	/* Add Exit entry at the end */
 	if (i <= MAX_COUNT - 1) {
 		entry = malloc(sizeof(struct bootmenu_entry));
 		if (!entry)
 			goto cleanup;
 
-		/* Add Quit entry if entering U-Boot console is disabled */
+		/* Add Quit entry if exiting bootmenu is disabled */
 		if (!IS_ENABLED(CONFIG_BOOTMENU_DISABLE_UBOOT_CONSOLE))
-			entry->title = strdup("U-Boot console");
+			entry->title = strdup("Exit");
 		else
 			entry->title = strdup("Quit");
 
@@ -532,7 +532,7 @@ static enum bootmenu_ret bootmenu_show(int delay)
 		title = strdup(iter->title);
 		command = strdup(iter->command);
 
-		/* last entry is U-Boot console or Quit */
+		/* last entry exits bootmenu */
 		if (iter->num == iter->menu->count - 1) {
 			ret = BOOTMENU_RET_QUIT;
 			goto cleanup;
Signature · 1 line
2.40.1
#2 lore raw

Re: [PATCH v2 1/1] cmd: bootmenu: rename U-Boot console to Exit

Quoted 8 lines · Svyatoslav Ryhel

It seems that the U-Boot console entry of the bootmenu has lost its original meaning. Now, even if it is chosen, the probability that you will enter the actual U-Boot console is quite low. Boot env, bootflow, bootcommand script may appear, but not the actual console. Hence, let's remove ambiguity and name this entry by what it actually does: 'Exit' the bootmenu.

Applied to u-boot/master, thanks!

Signature · 1 line
Tom