[PATCH 4/6] cmd: efidebug: Add support for querying UEFI variable storage

Ilias Apalodimas ilias.apalodimas at linaro.org
Mon May 11 10:49:31 CEST 2020


On Sat, May 09, 2020 at 11:58:17AM +0200, Heinrich Schuchardt wrote:
> On 5/6/20 9:12 PM, Ilias Apalodimas wrote:
> > +

[...]

> > +	printf("%.*s ====================\n", EFI_HANDLE_WIDTH, sep);
> 
> We are not printing handles. Please remove the line.
> 

Ok

> > +	printf("Max storage size %llu\n", max_variable_storage_size);
> > +	printf("Remaining storage size %llu\n", remain_variable_storage_size);
> > +	printf("Max variable size %llu\n", max_variable_size);
> > +
> > +	return CMD_RET_SUCCESS;
> > +}
> > +
> >  static cmd_tbl_t cmd_efidebug_sub[] = {
> >  	U_BOOT_CMD_MKENT(boot, CONFIG_SYS_MAXARGS, 1, do_efi_boot_opt, "", ""),
> >  	U_BOOT_CMD_MKENT(devices, CONFIG_SYS_MAXARGS, 1, do_efi_show_devices,
> > @@ -1176,6 +1215,8 @@ static cmd_tbl_t cmd_efidebug_sub[] = {
> >  			 "", ""),
> >  	U_BOOT_CMD_MKENT(test, CONFIG_SYS_MAXARGS, 1, do_efi_test,
> >  			 "", ""),
> > +	U_BOOT_CMD_MKENT(query, CONFIG_SYS_MAXARGS, 1, do_efi_query_info,
> > +			 "", ""),
> >  };
> >
> >  /**
> > @@ -1247,7 +1288,9 @@ static char efidebug_help_text[] =
> >  	"efidebug tables\n"
> >  	"  - show UEFI configuration tables\n"
> >  	"efidebug test bootmgr\n"
> > -	"  - run simple bootmgr for test\n";
> > +	"  - run simple bootmgr for test\n"
> > +	"efidebug query\n"
> > +	"  - show information of the container used to store UEFI variables\n";
> 
> This text does not make it clear that we will get size information. How
> about:
> 
> "show size of UEFI variables store\n"

Well the text was a c/p from here [1], but I agree I'll change it to what you
propose.


[1] https://edk2-docs.gitbook.io/edk-ii-uefi-driver-writer-s-guide/5_uefi_services/readme.2/526_queryvariableinfo


Regards
/Ilias
> 
> Best regards
> 
> Heinrich
> 
> >  #endif
> >
> >  U_BOOT_CMD(
> >
> 


More information about the U-Boot mailing list