[U-Boot] [RESEND PATCH v2 2/6] efi_loader: Initial HII database protocols

Heinrich Schuchardt xypron.glpk at gmx.de
Sun Jan 6 15:57:49 UTC 2019


On 12/14/18 11:10 AM, AKASHI Takahiro wrote:
> From: Leif Lindholm <leif.lindholm at linaro.org>
> 
> This patch provides enough implementation of the following protocols to
> run EDKII's Shell.efi and UEFI SCT:
> 
>   * EfiHiiDatabaseProtocol
>   * EfiHiiStringProtocol
> 

<snip>

> +
> +static efi_status_t EFIAPI
> +export_package_lists(const struct efi_hii_database_protocol *this,
> +		     efi_hii_handle_t handle,
> +		     efi_uintn_t *buffer_size,
> +		     struct efi_hii_package_list_header *buffer)
> +{
> +	EFI_ENTRY("%p, %p, %p, %p", this, handle, buffer_size, buffer);
> +
> +	if (!buffer_size || (buffer_size && !buffer))

This can be simplified:

	if (!buffer_size || !buffer))

Regards

Heinrich

> +		return EFI_EXIT(EFI_INVALID_PARAMETER);
> +
> +	return EFI_EXIT(EFI_NOT_FOUND);
> +}



More information about the U-Boot mailing list