diff options
author | AKASHI Takahiro <takahiro.akashi@linaro.org> | 2019-02-25 15:54:42 +0900 |
---|---|---|
committer | Heinrich Schuchardt <xypron.glpk@gmx.de> | 2019-02-25 12:47:13 +0100 |
commit | fa5367342a5b122ca960abe3b27e1914d0e2796c (patch) | |
tree | 83a2595125fb0ecd9fdef1a5de2f0e524eb3e89d /cmd | |
parent | a80146205d0a3002591dfa6cb14693a56bdbda6f (diff) | |
download | u-boot-fa5367342a5b122ca960abe3b27e1914d0e2796c.tar.gz |
cmd: efidebug: add images command
"images" command prints loaded images-related information.
Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org>
Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/efidebug.c | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/cmd/efidebug.c b/cmd/efidebug.c index 66e93193e7..e3a2d093fb 100644 --- a/cmd/efidebug.c +++ b/cmd/efidebug.c @@ -316,6 +316,26 @@ static int do_efi_show_handles(cmd_tbl_t *cmdtp, int flag, } /** + * do_efi_show_images() - show UEFI images + * + * @cmdtp: Command table + * @flag: Command flag + * @argc: Number of arguments + * @argv: Argument array + * Return: CMD_RET_SUCCESS on success, CMD_RET_RET_FAILURE on failure + * + * Implement efidebug "images" sub-command. + * Show all UEFI loaded images and their information. + */ +static int do_efi_show_images(cmd_tbl_t *cmdtp, int flag, + int argc, char * const argv[]) +{ + efi_print_image_infos(NULL); + + return CMD_RET_SUCCESS; +} + +/** * do_efi_boot_add() - set UEFI load option * * @cmdtp: Command table @@ -823,6 +843,8 @@ static cmd_tbl_t cmd_efidebug_sub[] = { "", ""), U_BOOT_CMD_MKENT(dh, CONFIG_SYS_MAXARGS, 1, do_efi_show_handles, "", ""), + U_BOOT_CMD_MKENT(images, CONFIG_SYS_MAXARGS, 1, do_efi_show_images, + "", ""), }; /** @@ -887,7 +909,9 @@ static char efidebug_help_text[] = "efidebug drivers\n" " - show uefi drivers\n" "efidebug dh\n" - " - show uefi handles\n"; + " - show uefi handles\n" + "efidebug images\n" + " - show loaded images\n"; #endif U_BOOT_CMD( |