diff options
Diffstat (limited to 'package/boot/uboot-mediatek/patches/100-16-cmd-bootmenu-add-ability-to-select-item-by-shortkey.patch')
-rw-r--r-- | package/boot/uboot-mediatek/patches/100-16-cmd-bootmenu-add-ability-to-select-item-by-shortkey.patch | 22 |
1 files changed, 9 insertions, 13 deletions
diff --git a/package/boot/uboot-mediatek/patches/100-16-cmd-bootmenu-add-ability-to-select-item-by-shortkey.patch b/package/boot/uboot-mediatek/patches/100-16-cmd-bootmenu-add-ability-to-select-item-by-shortkey.patch index ee45ff0de6..e0571671bc 100644 --- a/package/boot/uboot-mediatek/patches/100-16-cmd-bootmenu-add-ability-to-select-item-by-shortkey.patch +++ b/package/boot/uboot-mediatek/patches/100-16-cmd-bootmenu-add-ability-to-select-item-by-shortkey.patch @@ -91,7 +91,7 @@ Signed-off-by: Weijie Gao <weijie.gao@mediatek.com> default_str = env_get("bootmenu_default"); if (default_str) -@@ -356,9 +380,9 @@ static struct bootmenu_data *bootmenu_cr +@@ -366,9 +390,9 @@ static struct bootmenu_data *bootmenu_cr /* Add Quit entry if entering U-Boot console is disabled */ if (!IS_ENABLED(CONFIG_BOOTMENU_DISABLE_UBOOT_CONSOLE)) @@ -203,11 +203,7 @@ Signed-off-by: Weijie Gao <weijie.gao@mediatek.com> case 1: --- a/include/menu.h +++ b/include/menu.h -@@ -2,10 +2,11 @@ - /* - * Copyright 2010-2011 Calxeda, Inc. - */ -- +@@ -6,6 +6,8 @@ #ifndef __MENU_H__ #define __MENU_H__ @@ -216,7 +212,7 @@ Signed-off-by: Weijie Gao <weijie.gao@mediatek.com> struct menu; struct menu *menu_create(char *title, int timeout, int prompt, -@@ -18,6 +19,8 @@ int menu_get_choice(struct menu *m, void +@@ -18,6 +20,8 @@ int menu_get_choice(struct menu *m, void int menu_item_add(struct menu *m, char *item_key, void *item_data); int menu_destroy(struct menu *m); int menu_default_choice(struct menu *m, void **choice); @@ -225,7 +221,7 @@ Signed-off-by: Weijie Gao <weijie.gao@mediatek.com> /** * menu_show() Show a boot menu -@@ -40,6 +43,7 @@ struct bootmenu_data { +@@ -40,6 +44,7 @@ struct bootmenu_data { int active; /* active menu entry */ int count; /* total count of menu entries */ struct bootmenu_entry *first; /* first menu entry */ @@ -233,10 +229,10 @@ Signed-off-by: Weijie Gao <weijie.gao@mediatek.com> }; enum bootmenu_key { -@@ -48,11 +52,11 @@ enum bootmenu_key { - KEY_DOWN, - KEY_SELECT, - KEY_QUIT, +@@ -51,11 +56,12 @@ enum bootmenu_key { + KEY_PLUS, + KEY_MINUS, + KEY_SPACE, + KEY_CHOICE, }; @@ -245,6 +241,6 @@ Signed-off-by: Weijie Gao <weijie.gao@mediatek.com> + enum bootmenu_key *key, int *esc, int *choice); void bootmenu_loop(struct bootmenu_data *menu, - enum bootmenu_key *key, int *esc); -- + enum bootmenu_key *key, int *esc, int *choice); + #endif /* __MENU_H__ */ |