All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jose Marinho <Jose.Marinho@arm.com>
To: u-boot@lists.denx.de
Subject: [PATCH 2/2 v4] efi: ESRT creation tests
Date: Tue, 2 Mar 2021 11:51:26 +0000	[thread overview]
Message-ID: <DBBPR08MB60124935A053A776666DA3A188999@DBBPR08MB6012.eurprd08.prod.outlook.com> (raw)
In-Reply-To: <53eee005-c38f-1be1-5ceb-b51d9b1ab7c7@gmx.de>

Hi Heinrich,

Thank you for your reviews.

> 
> With which configuration do we see any entry in the list?
> 
> I only got:
> 
> => efidebug capsule esrt
> ========================================
> ESRT: fw_resource_count=0
> ESRT: fw_resource_count_max=0
> ESRT: fw_resource_version=1
> ========================================
> =>
> 

To get the FIT and RAW capsules showing, the best is to execute the test script in: 
test/py/tests/test_efi_capsule/test_capsule_firmware.py


> > diff --git a/test/lib/Makefile b/test/lib/Makefile index
> > 97c11e35a8..aeb8c13eb0 100644
> > --- a/test/lib/Makefile
> > +++ b/test/lib/Makefile
> > @@ -15,3 +15,4 @@ obj-$(CONFIG_UT_LIB_ASN1) += asn1.o
> >  obj-$(CONFIG_UT_LIB_RSA) += rsa.o
> >  obj-$(CONFIG_AES) += test_aes.o
> >  obj-$(CONFIG_GETOPT) += getopt.o
> > +obj-$(CONFIG_EFI_ESRT) += efi_esrt.o
> > diff --git a/test/lib/efi_esrt.c b/test/lib/efi_esrt.c new file mode
> > 100644 index 0000000000..e8cfe671e2
> > --- /dev/null
> > +++ b/test/lib/efi_esrt.c
> > @@ -0,0 +1,191 @@
> > +// SPDX-License-Identifier: GPL-2.0-only
> > +/*
> > + *  Test ESRT tables support
> > + *
> > + *  Copyright (C) 2021 Arm Ltd.
> > + */
> > +#include <common.h>
> > +#include <efi_loader.h>
> > +#include <net.h>
> > +#include <test/lib.h>
> > +#include <test/test.h>
> > +#include <test/ut.h>
> > +
> > +#define TEST_ESRT_NUM_ENTRIES 255
> > +
> > +#if 0x100 < TEST_ESRT_NUM_ENTRIES
> > +#error TEST_ESRT_NUM_ENTRIES must be lower or equal to 255.
> > +#endif
> 
> A comment above the #define should be enough.
> 
> What leads to the limit of 255 entries?

The 255 entry limit stems from the get_image_info u8 descriptor_count output variable.
> 
> Have the existing FMP protocols to be in the count?
> 

Regards,

Jose

      parent reply	other threads:[~2021-03-02 11:51 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-23 16:49 [PATCH 0/2 v4] Add ESRT and test ESRT creation Jose Marinho
2021-02-23 16:50 ` [PATCH 1/2 v4] efi: Add ESRT to the EFI system table Jose Marinho
2021-02-26 14:56   ` Heinrich Schuchardt
2021-02-23 16:50 ` [PATCH 2/2 v4] efi: ESRT creation tests Jose Marinho
2021-02-26 13:55   ` Heinrich Schuchardt
2021-02-26 14:17     ` Heinrich Schuchardt
2021-03-01  1:18       ` AKASHI Takahiro
2021-03-02 11:51     ` Jose Marinho [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=DBBPR08MB60124935A053A776666DA3A188999@DBBPR08MB6012.eurprd08.prod.outlook.com \
    --to=jose.marinho@arm.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.