[PATCH v2 2/2] efi_selftest: unit test for EFI Conformance Profile Table
Heinrich Schuchardt
heinrich.schuchardt at canonical.com
Sun Sep 4 09:53:03 CEST 2022
On 9/4/22 07:08, Ilias Apalodimas wrote:
> Hi Heinrich,
>
> [...]
>
>> + */
>> +static int ecpt_find_guid(struct efi_conformance_profiles_table *ecpt,
>> + const efi_guid_t *guid) {
>> + int i;
>> +
>> + for (i = 0; i < ecpt->number_of_profiles; ++i) {
>> + if (!memcmp(&ecpt->conformance_profiles[i], guid, 16))
>> + return EFI_ST_SUCCESS;
>
> Can't we use guidcmp here?
I would prefer to keep the unit tests independent of U-Boot's library
functions so that we can opt to compile them as freestanding UEFI
application.
Best regards
Heinrich
>
>> + }
>> + efi_st_error("GUID %pU not found\n", guid);
>> + return EFI_ST_FAILURE;
>> +}
>> +
>> +/*
> [...]
>
> Thanks
> /Ilias
More information about the U-Boot
mailing list