[PATCH 3/8] binman: capsule: Generate capsules through config file

2023-09-08 Thread Sughosh Ganu
Add support in binman for generating capsules by reading the capsule parameters through a config file. Also add a test case in binman for this mode of capsule generation. Signed-off-by: Sughosh Ganu --- tools/binman/entries.rst | 35 tools/binman/etype

[PATCH 4/8] doc: Document capsule generation through a config file

2023-09-08 Thread Sughosh Ganu
The UEFI capsule can now be generate by specifying the capsule parameters through a config file. Additionally, the capsules can be generated as part of u-boot build, through binman. Highlight these changes in the documentation. Signed-off-by: Sughosh Ganu --- doc/develop/uefi/uefi.rst | 70

[PATCH 5/8] sandbox: capsule: Add a config file for generating capsules

2023-09-08 Thread Sughosh Ganu
the config file on the sandbox variant. Signed-off-by: Sughosh Ganu --- configs/sandbox_defconfig | 2 + .../test_efi_capsule/sandbox_capsule_cfg.txt | 162 ++ 2 files changed, 164 insertions(+) create mode 100644 test/py/tests/test_efi_capsule

[PATCH 6/8] test: capsule: Generate capsules through config file

2023-09-08 Thread Sughosh Ganu
Add logic to generate capsules through a config file while testing the EFI capsule update functionality. Capsule generation through config file is enabled on the sandbox variant. Signed-off-by: Sughosh Ganu --- .../test_efi_capsule/capsule_gen_binman.dts| 8 test/py/tests

[PATCH 7/8] btool: mkeficapsule: Add support for EFI empty capsule generation

2023-09-08 Thread Sughosh Ganu
Add a method to the mkeficapsule bintool to generate empty capsules. These are capsules needed for the FWU A/B update feature. Signed-off-by: Sughosh Ganu --- tools/binman/btool/mkeficapsule.py | 29 + 1 file changed, 29 insertions(+) diff --git a/tools/binman/btool

[PATCH 8/8] binman: capsule: Add support for generating EFI empty capsules

2023-09-08 Thread Sughosh Ganu
Add support in binman for generating EFI empty capsules. These capsules are used in the FWU A/B update feature. Also add test cases in binman for the corresponding code coverage. Signed-off-by: Sughosh Ganu --- Note: Simon, I have not forgotten your comment on the earlier series to add support

Re: UEFI update files missing on sandbox?

2023-09-10 Thread Sughosh Ganu
hi Simon, On Sun, 10 Sept 2023 at 04:10, Simon Glass wrote: > > Hi Sughosh, > > I thought that all your patches were merged but now when I build > sandbox I don't see the capsule-update files generated. Is there > something missing? The building of the EFI capsules was moved to the corresponding

Re: [PATCH 3/8] binman: capsule: Generate capsules through config file

2023-09-11 Thread Sughosh Ganu
hi Simon, On Mon, 11 Sept 2023 at 00:44, Simon Glass wrote: > > Hi Sughosh, > > On Fri, 8 Sept 2023 at 06:00, Sughosh Ganu wrote: > > > > Add support in binman for generating capsules by reading the capsule > > parameters through a config file. Also add a test ca

Re: UEFI update files missing on sandbox?

2023-09-14 Thread Sughosh Ganu
hi Simon, On Wed, 13 Sept 2023 at 23:37, Simon Glass wrote: > > Hi Sughosh, > > On Sun, 10 Sept 2023 at 13:13, Simon Glass wrote: > > > > Hi Sughosh, > > > > On Sun, 10 Sept 2023 at 04:54, Sughosh Ganu wrote: > > > > > > hi Simon, > &g

Re: [PATCH 3/8] binman: capsule: Generate capsules through config file

2023-09-14 Thread Sughosh Ganu
hi Simon, On Wed, 13 Sept 2023 at 23:37, Simon Glass wrote: > > Hi Sughosh, > > On Mon, 11 Sept 2023 at 08:13, Sughosh Ganu wrote: > > > > hi Simon, > > > > On Mon, 11 Sept 2023 at 00:44, Simon Glass wrote: > > > > > > Hi Sughosh,

Re: [PATCH 1/8] tools: mkeficapsule: Add support for parsing capsule params from config file

2023-09-14 Thread Sughosh Ganu
hi Tom. On Thu, 14 Sept 2023 at 00:54, Tom Rini wrote: > > On Fri, Sep 08, 2023 at 05:29:55PM +0530, Sughosh Ganu wrote: > > > Add support for specifying the parameters needed for capsule > > generation through a config file, instead of passing them through > > comman

Re: [PATCH 0/8] Add some more EFI capsule tooling support

2023-09-14 Thread Sughosh Ganu
hi Tom, On Thu, 14 Sept 2023 at 00:54, Tom Rini wrote: > > On Fri, Sep 08, 2023 at 05:29:54PM +0530, Sughosh Ganu wrote: > > > Recently, a set of patches were merged in next, which were adding > > support for generating capsules as part of the U-Boot build. Mid way >

[PATCH v2 0/3] rockpi4: Add capsule update support

2022-09-05 Thread Sughosh Ganu
EFI variables. Sughosh Ganu (3): rockpi4: capsule: Add functions needed for supporting capsule updates rockpi4: board: Add firmware image information needed for capsule updates rockpi4: capsule: Enable UEFI capsule update on RockPi4 boards arch/arm/mach-rockchip/Kconfig | 1

[PATCH v2 1/3] rockpi4: capsule: Add functions needed for supporting capsule updates

2022-09-05 Thread Sughosh Ganu
Add functions needed to support the UEFI capsule update feature on rockchip boards. Currently, the feature is being enabled on the RockPi4 boards with firmware images residing on GPT partitioned storage media. Signed-off-by: Sughosh Ganu --- Changes since V1: * Move the capsule update related

[PATCH v2 2/3] rockpi4: board: Add firmware image information needed for capsule updates

2022-09-05 Thread Sughosh Ganu
Add information that will be needed for enabling the UEFI capsule update feature on the RockPi4 boards. With the feature enabled, it would be possible to update the idbloader and u-boot.itb images on the RockPi4B and RockPi4C variants. Signed-off-by: Sughosh Ganu --- Changes since V1: * Split

[PATCH v2 3/3] rockpi4: capsule: Enable UEFI capsule update on RockPi4 boards

2022-09-05 Thread Sughosh Ganu
Enable the UEFI capsule update functionality on the RockPi4B and RockPi4C boards. Support is being enabled for updating the idbloader and u-boot firmware images residing on GPT partitioned storage devices. Signed-off-by: Sughosh Ganu --- Changes since V1: * Split the enabling of the feature into

Re: [PATCH v9 05/15] stm32mp1: dk2: Add image information for capsule updates

2022-09-06 Thread Sughosh Ganu
hi Etienne, On Tue, 6 Sept 2022 at 00:49, Etienne Carriere wrote: > > Hello Sughosh, > > On Fri, 26 Aug 2022 at 11:57, Sughosh Ganu wrote: > > > > Enabling capsule update functionality on the platform requires > > populating information on the images th

Re: [PATCH v9 09/15] FWU: Add boot time checks as highlighted by the FWU specification

2022-09-06 Thread Sughosh Ganu
hi Etienne, On Tue, 6 Sept 2022 at 12:31, Etienne Carriere wrote: > > Hi Sughosh, > > Reviewed-by: Etienne Carriere with a > minor comment. > > > On Fri, 26 Aug 2022 at 11:58, Sughosh Ganu wrote: > > > > The FWU Multi Bank Update specification requires the U

Re: [PATCH v9 03/15] FWU: Add FWU metadata access driver for GPT partitioned block devices

2022-09-06 Thread Sughosh Ganu
hi Etienne, On Tue, 6 Sept 2022 at 12:31, Etienne Carriere wrote: > > Hi Sughosh, > > Reviewed-by: Etienne Carriere with > comment addressed. Will address both your review comments. Thanks. -sughosh > > > On Fri, 26 Aug 2022 at 11:57, Sughosh Ganu wrote: > > &g

Re: [PATCH v9 07/15] FWU: STM32MP1: Add support to read boot index from backup register

2022-09-06 Thread Sughosh Ganu
hi Etienne, On Tue, 6 Sept 2022 at 12:57, Etienne Carriere wrote: > > Hi Sughosh, > > I have a last comment on this series, related to the below patch and > patch "test: dm: Add test cases for FWU Metadata uclass". > > On Fri, 26 Aug 2022 at 11:58, Sughosh Ganu wr

Re: [PATCH v9 07/15] FWU: STM32MP1: Add support to read boot index from backup register

2022-09-06 Thread Sughosh Ganu
hi Etienne, On Tue, 6 Sept 2022 at 13:07, Sughosh Ganu wrote: > > hi Etienne, > > On Tue, 6 Sept 2022 at 12:57, Etienne Carriere > wrote: > > > > Hi Sughosh, > > > > I have a last comment on this series, related to the below patch and > > patch &quo

Re: [PATCH v9 02/15] FWU: Add FWU metadata structure and driver for accessing metadata

2022-09-07 Thread Sughosh Ganu
hi Ilias, On Wed, 7 Sept 2022 at 12:15, Ilias Apalodimas wrote: > > Hi Sughosh, > > On Fri, Aug 26, 2022 at 03:27:03PM +0530, Sughosh Ganu wrote: > > In the FWU Multi Bank Update feature, the information about the > > updatable images is stored as part of the metadata,

Re: [PATCH v9 06/15] FWU: Add helper functions for accessing FWU metadata

2022-09-07 Thread Sughosh Ganu
hi Ilias, On Wed, 7 Sept 2022 at 11:29, Ilias Apalodimas wrote: > > On Fri, Aug 26, 2022 at 03:27:07PM +0530, Sughosh Ganu wrote: > > Add weak functions for getting the update index value and dfu > > alternate number needed for FWU Multi Bank update > > functional

Re: [PATCH v9 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-09-07 Thread Sughosh Ganu
hi Takahiro, On Thu, 8 Sept 2022 at 07:45, Takahiro Akashi wrote: > > Hi Sughosh, > > On Fri, Aug 26, 2022 at 03:27:11PM +0530, Sughosh Ganu wrote: > > The FWU Multi Bank Update feature supports updation of firmware images > > to one of multiple sets(also called banks)

Re: [PATCH] RockPi4: Add UEFI capsule update support

2022-09-09 Thread Sughosh Ganu
hi Kever, On Fri, 9 Sept 2022 at 15:38, Kever Yang wrote: > > Hi Sughosh, > > On 2022/9/2 15:52, Sughosh Ganu wrote: > > hi Kever, > > > > On Wed, 29 Jun 2022 at 09:11, Kever Yang wrote: > >> Hi Sughosh, > >> > >>Thanks for you

Re: [PATCH v2 2/3] rockpi4: board: Add firmware image information needed for capsule updates

2022-09-13 Thread Sughosh Ganu
hi Peter, On Fri, 9 Sept 2022 at 18:12, Peter Robinson wrote: > > On Tue, Sep 6, 2022 at 7:59 AM Sughosh Ganu wrote: > > > > Add information that will be needed for enabling the UEFI capsule > > update feature on the RockPi4 boards. With the feature enabled, it > &g

Re: [PATCH v2 1/3] rockpi4: capsule: Add functions needed for supporting capsule updates

2022-09-13 Thread Sughosh Ganu
apsule update feature on > > rockchip boards. Currently, the feature is being enabled on the > > RockPi4 boards with firmware images residing on GPT partitioned > > storage media. > > > > Signed-off-by: Sughosh Ganu > > --- > > Changes since V1: > > * Move the

[PATCH v3 0/3] rockpi4: Add capsule update support

2022-09-14 Thread Sughosh Ganu
summary instead of rockpi * Use num_image_type_guids instead of ROCKPI4_UPDATABLE_IMAGES macro * Move the board specific code out of this file into evb_rk3399.c * Add a function rockchip_capsule_update_board_setup() for setting up the board specific part needed for capsule updates Sughosh Ganu (3

[PATCH v3 1/3] rockchip: capsule: Add functions for supporting capsule updates

2022-09-14 Thread Sughosh Ganu
Add functions needed to support the UEFI capsule update feature on rockchip boards. Currently, the feature is being enabled on the RockPi4 boards with firmware images residing on GPT partitioned storage media. Signed-off-by: Sughosh Ganu --- Changes since V2: * Use rockchip in the commit message

[PATCH v3 2/3] rockpi4: board: Add firmware image information for capsule updates

2022-09-14 Thread Sughosh Ganu
Add information that will be needed for enabling the UEFI capsule update feature on the RockPi4 boards. With the feature enabled, it would be possible to update the idbloader and u-boot.itb images on the RockPi4B and RockPi4C variants. Signed-off-by: Sughosh Ganu --- Changes since V2: * Add a

[PATCH v3 3/3] rockpi4: capsule: Enable UEFI capsule update on RockPi4 boards

2022-09-14 Thread Sughosh Ganu
Enable the UEFI capsule update functionality on the RockPi4B and RockPi4C boards. Support is being enabled for updating the idbloader and u-boot firmware images residing on GPT partitioned uSD card storage device. Signed-off-by: Sughosh Ganu --- Changes since V2: None configs/rock-pi-4

[PATCH v10 00/15] FWU: Add FWU Multi Bank Update feature support

2022-09-15 Thread Sughosh Ganu
to take an uint * as the function parameter instead of the void * as suggested by Etienne. Sughosh Ganu (15): dt/bindings: Add bindings for GPT based FWU Metadata storage device FWU: Add FWU metadata structure and driver for accessing metadata FWU: Add FWU metadata access driver for GPT p

[PATCH v10 01/15] dt/bindings: Add bindings for GPT based FWU Metadata storage device

2022-09-15 Thread Sughosh Ganu
devices. Signed-off-by: Sughosh Ganu Reviewed-by: Heinrich Schuchardt Acked-by: Etienne Carriere Reviewed-by: Ilias Apalodimas --- Changes since V9: None .../firmware/fwu-mdata-gpt.yaml | 32 +++ 1 file changed, 32 insertions(+) create mode 100644 doc/device-tree

[PATCH v10 02/15] FWU: Add FWU metadata structure and driver for accessing metadata

2022-09-15 Thread Sughosh Ganu
, and implementations can be added based on parameters like how the metadata partition is accessed and what type of storage device houses the metadata. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Reviewed-by: Etienne Carriere --- Changes since V9: * Add a helper function fwu_get_dev_mdata

[PATCH v10 03/15] FWU: Add FWU metadata access driver for GPT partitioned block devices

2022-09-15 Thread Sughosh Ganu
based partition scheme. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Reviewed-by: Etienne Carriere --- Changes since V9: * s/formated/formatted in the commit message * Add a '\n' character in the log message drivers/fwu-mdata/Kconfig | 16 ++ drivers/fwu-mdata/Makef

[PATCH v10 04/15] stm32mp1: dk2: Add a node for the FWU metadata device

2022-09-15 Thread Sughosh Ganu
The FWU metadata structure is accessed through the driver model interface. On the stm32mp157c-dk2 board, the FWU metadata is stored on the uSD card. Add the fwu-mdata node on the u-boot specifc dtsi file for accessing the metadata structure. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick

[PATCH v10 05/15] stm32mp1: dk2: Add image information for capsule updates

2022-09-15 Thread Sughosh Ganu
Enabling capsule update functionality on the platform requires populating information on the images that are to be updated using the functionality. Do so for the DK2 board. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Reviewed-by: Ilias Apalodimas --- Changes since V9: * Remove

[PATCH v10 06/15] FWU: Add helper functions for accessing FWU metadata

2022-09-15 Thread Sughosh Ganu
ction. The function to get the dfu alternate number has been added for platforms with GPT partitioned storage devices. Platforms with other storage partition scheme need to implement their own function. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Acked-by: Etienne Carriere --- Ch

[PATCH v10 07/15] FWU: STM32MP1: Add support to read boot index from backup register

2022-09-15 Thread Sughosh Ganu
value is passed through one of the SoC's backup register. Add a function to read the boot index value from the backup register. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Acked-by: Ilias Apalodimas --- Changes since V9: * Change the fwu_plat_get_bootidx() function to take an uint

[PATCH v10 08/15] event: Add an event for main_loop

2022-09-15 Thread Sughosh Ganu
Add an event type EVT_MAIN_LOOP that can be used for registering events that need to be run after the platform has been initialised and before the main_loop function is called. Signed-off-by: Sughosh Ganu Reviewed-by: Simon Glass --- Changes since V9: * Add a comment to indicate where the event

[PATCH v10 09/15] FWU: Add boot time checks as highlighted by the FWU specification

2022-09-15 Thread Sughosh Ganu
system boots in the Trial State for more than a specified number of boot counts, change the Active Bank to be booting the platform from. Call these checks through the main loop event at the time of platform boot. Signed-off-by: Sughosh Ganu Reviewed-by: Etienne Carriere --- Changes since V9

[PATCH v10 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-09-15 Thread Sughosh Ganu
set the updated bank as active bank to subsequently boot from. Signed-off-by: Sughosh Ganu --- Changes since V9: * Move the global variables into local variables as suggested by Ilias. * Change fwu_get_image_alt_num() name to fwu_get_image_image_index() as suggested by Takahiro. * Allow capsule

[PATCH v10 11/15] FWU: cmd: Add a command to read FWU metadata

2022-09-15 Thread Sughosh Ganu
Add a command to read the metadata as specified in the FWU specification and print the fields of the metadata. Signed-off-by: Sughosh Ganu Reviewed-by: Ilias Apalodimas Reviewed-by: Etienne Carriere --- Changes since V9: * Add a document for the command cmd/Kconfig | 6

[PATCH v10 12/15] test: dm: Add test cases for FWU Metadata uclass

2022-09-15 Thread Sughosh Ganu
-- the FIT capsule test will be run on the sandbox_flattree variant. Signed-off-by: Sughosh Ganu Suggested-by: Heinrich Schuchardt --- Changes since V9: * Change the fwu_plat_get_bootidx() function to take an uint * as the function parameter instead of the void * as suggested by Etienne. arch

[PATCH v10 13/15] mkeficapsule: Add support for generating empty capsules

2022-09-15 Thread Sughosh Ganu
://git.codelinaro.org/linaro/dependable-boot/mbfw/uploads/6f7ddfe3be24e18d4319e108a758d02e/mbfw.pdf Signed-off-by: Sughosh Ganu --- Changes since V9: None doc/mkeficapsule.1 | 29 + tools/eficapsule.h | 8 tools/mkeficapsule.c | 96 3 files

[PATCH v10 14/15] mkeficapsule: Add support for setting OEM flags in capsule header

2022-09-15 Thread Sughosh Ganu
: Sughosh Ganu Reviewed-by: Ilias Apalodimas --- Changes since V9: None doc/mkeficapsule.1 | 4 tools/mkeficapsule.c | 17 ++--- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/doc/mkeficapsule.1 b/doc/mkeficapsule.1 index 77ca061efd..6fb2dd0810 100644 --- a/doc

[PATCH v10 15/15] FWU: doc: Add documentation for the FWU feature

2022-09-15 Thread Sughosh Ganu
Add documentattion for the FWU Multi Bank Update feature. The document describes the steps needed for setting up the platform for the feature, as well as steps for enabling the feature on the platform. Signed-off-by: Sughosh Ganu --- Changes since V9: None doc/develop/uefi/fwu_updates.rst

Re: [PATCH v10 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-09-15 Thread Sughosh Ganu
() hi Takahiro, On Fri, 16 Sept 2022 at 07:17, Takahiro Akashi wrote: > > Hi Sughosh, > > On Thu, Sep 15, 2022 at 01:44:46PM +0530, Sughosh Ganu wrote: > > The FWU Multi Bank Update feature supports updation of firmware images > > to one of multiple sets(also call

Re: [PATCH v10 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-09-16 Thread Sughosh Ganu
hi Takahiro, On Fri, 16 Sept 2022 at 12:20, Takahiro Akashi wrote: > > On Fri, Sep 16, 2022 at 10:52:11AM +0530, Sughosh Ganu wrote: > > () hi Takahiro, > > > > On Fri, 16 Sept 2022 at 07:17, Takahiro Akashi > > wrote: > > > > > > Hi Sughosh, >

Re: [PATCH v10 02/15] FWU: Add FWU metadata structure and driver for accessing metadata

2022-09-19 Thread Sughosh Ganu
On Mon, 19 Sept 2022 at 06:03, Jassi Brar wrote: > > On Thu, 15 Sept 2022 at 03:15, Sughosh Ganu wrote: > > > +/** > > + * fwu_get_active_index() - Get active_index from the FWU metadata > > + * @active_idxp: active_index value to be read > > + * > > +

Re: [PATCH v10 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-09-20 Thread Sughosh Ganu
On Tue, 20 Sept 2022 at 13:46, Takahiro Akashi wrote: > > On Fri, Sep 16, 2022 at 04:24:35PM +0530, Sughosh Ganu wrote: > > hi Takahiro, > > > > On Fri, 16 Sept 2022 at 12:20, Takahiro Akashi > > wrote: > > > > > > On Fri, Sep 16, 2022 at 10:

Re: [PATCH v10 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-09-21 Thread Sughosh Ganu
hi Takahiro, On Wed, 21 Sept 2022 at 10:58, Takahiro Akashi wrote: > > Sughosh, > > On Tue, Sep 20, 2022 at 06:34:12PM +0530, Sughosh Ganu wrote: > > On Tue, 20 Sept 2022 at 13:46, Takahiro Akashi > > wrote: > > > > > > On Fri, Sep 16, 2022 at 04:24:

Re: [PATCH v10 06/15] FWU: Add helper functions for accessing FWU metadata

2022-09-22 Thread Sughosh Ganu
hi Ilias, On Thu, 22 Sept 2022 at 14:29, Ilias Apalodimas wrote: > > Hi Sughosh > > On Thu, Sep 15, 2022 at 01:44:42PM +0530, Sughosh Ganu wrote: > > Add weak functions for getting the update index value and dfu > > alternate number needed for FWU Multi Bank update > &

Re: [PATCH v10 03/15] FWU: Add FWU metadata access driver for GPT partitioned block devices

2022-09-26 Thread Sughosh Ganu
hi Ilias, On Thu, 22 Sept 2022 at 14:16, Ilias Apalodimas wrote: > > Hi Sughosh > > On Thu, Sep 15, 2022 at 01:44:39PM +0530, Sughosh Ganu wrote: > > In the FWU Multi Bank Update feature, the information about the > > updatable images is stored as part of the

Re: [PATCH v10 03/15] FWU: Add FWU metadata access driver for GPT partitioned block devices

2022-09-26 Thread Sughosh Ganu
On Mon, 26 Sept 2022 at 08:22, Jassi Brar wrote: > > On Thu, Sep 15, 2022 at 3:16 AM Sughosh Ganu wrote: > > > diff --git a/drivers/fwu-mdata/Kconfig b/drivers/fwu-mdata/Kconfig > > new file mode 100644 > > index 00..7322da48b1 > > --- /dev/null &g

Re: [PATCH v10 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-09-26 Thread Sughosh Ganu
On Mon, 26 Sept 2022 at 08:25, Jassi Brar wrote: > > On Thu, Sep 15, 2022 at 3:17 AM Sughosh Ganu wrote: > > > + > > +static __maybe_unused void fwu_post_update_checks( > > + struct efi_capsule_header *capsule, > > + bool *f

Re: [PATCH v10 02/15] FWU: Add FWU metadata structure and driver for accessing metadata

2022-09-26 Thread Sughosh Ganu
On Mon, 26 Sept 2022 at 08:28, Jassi Brar wrote: > > On Thu, Sep 15, 2022 at 3:15 AM Sughosh Ganu wrote: > > > +/** > > + * @mdata_check: check the validity of the FWU metadata partitions > > + * @get_mdata() - Get a FWU metadata copy > > + * @update_mdata

Re: [PATCH v10 09/15] FWU: Add boot time checks as highlighted by the FWU specification

2022-09-26 Thread Sughosh Ganu
On Mon, 26 Sept 2022 at 08:29, Jassi Brar wrote: > > On Thu, Sep 15, 2022 at 3:17 AM Sughosh Ganu wrote: > > > > diff --git a/include/fwu.h b/include/fwu.h > > index 484289ed4f..d5f77ce83c 100644 > > --- a/include/fwu.h > > +++ b/includ

Re: [PATCH v10 09/15] FWU: Add boot time checks as highlighted by the FWU specification

2022-09-27 Thread Sughosh Ganu
On Mon, 26 Sept 2022 at 19:37, Jassi Brar wrote: > > On Mon, Sep 26, 2022 at 5:08 AM Sughosh Ganu wrote: > > > > On Mon, 26 Sept 2022 at 08:29, Jassi Brar wrote: > > > . > > > > +static int fwu_boottime_checks(void *ctx, struct event *ev

Re: [PATCH v10 02/15] FWU: Add FWU metadata structure and driver for accessing metadata

2022-09-27 Thread Sughosh Ganu
On Mon, 26 Sept 2022 at 20:12, Jassi Brar wrote: > > On Mon, Sep 26, 2022 at 5:00 AM Sughosh Ganu wrote: > > > > On Mon, 26 Sept 2022 at 08:28, Jassi Brar wrote: > > > > > > > > > > . > > > > +/** > > > > + * fwu_re

Re: [PATCH v10 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-09-27 Thread Sughosh Ganu
On Mon, 26 Sept 2022 at 20:24, Jassi Brar wrote: > > On Mon, Sep 26, 2022 at 4:01 AM Sughosh Ganu wrote: > > On Mon, 26 Sept 2022 at 08:25, Jassi Brar wrote: > > > > . > > > > > > > > +static __maybe_unused efi_status_t fw

Re: [PATCH v10 02/15] FWU: Add FWU metadata structure and driver for accessing metadata

2022-09-27 Thread Sughosh Ganu
On Tue, 27 Sept 2022 at 21:55, Jassi Brar wrote: > > On Tue, Sep 27, 2022 at 2:14 AM Sughosh Ganu wrote: > > > > On Mon, 26 Sept 2022 at 20:12, Jassi Brar wrote: > > > > > > On Mon, Sep 26, 2022 at 5:00 AM Sughosh Ganu > > > wrote: > > &g

Re: [PATCH v10 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-09-27 Thread Sughosh Ganu
On Tue, 27 Sept 2022 at 22:19, Jassi Brar wrote: > > On Tue, Sep 27, 2022 at 2:22 AM Sughosh Ganu wrote: > > > > On Mon, 26 Sept 2022 at 20:24, Jassi Brar wrote: > > > > > > On Mon, Sep 26, 2022 at 4:01 AM Sughosh Ganu > > > wrote: >

[PATCH v11 00/15] FWU: Add FWU Multi Bank Update feature support

2022-09-28 Thread Sughosh Ganu
on to highlight the difference in ImageIndex correlation with DFU alt num with FWU feature enabled Sughosh Ganu (15): dt/bindings: Add bindings for GPT based FWU Metadata storage device FWU: Add FWU metadata structure and driver for accessing metadata FWU: Add FWU metadata access drive

[PATCH v11 01/15] dt/bindings: Add bindings for GPT based FWU Metadata storage device

2022-09-28 Thread Sughosh Ganu
devices. Signed-off-by: Sughosh Ganu Reviewed-by: Heinrich Schuchardt Acked-by: Etienne Carriere Reviewed-by: Ilias Apalodimas --- Changes since V10: None .../firmware/fwu-mdata-gpt.yaml | 32 +++ 1 file changed, 32 insertions(+) create mode 100644 doc/device-tree

[PATCH v11 03/15] FWU: Add FWU metadata access driver for GPT partitioned block devices

2022-09-28 Thread Sughosh Ganu
based partition scheme. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Reviewed-by: Etienne Carriere --- Changes since V10: * Use array for storing the metadata partition numbers as suggested by Ilias * Skip a couple of goto's in gpt_check_mdata_validity() as suggested by

[PATCH v11 02/15] FWU: Add FWU metadata structure and driver for accessing metadata

2022-09-28 Thread Sughosh Ganu
, and implementations can be added based on parameters like how the metadata partition is accessed and what type of storage device houses the metadata. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Reviewed-by: Etienne Carriere --- Changes since V10: * s/fwu_update_active_

[PATCH v11 04/15] stm32mp1: dk2: Add a node for the FWU metadata device

2022-09-28 Thread Sughosh Ganu
The FWU metadata structure is accessed through the driver model interface. On the stm32mp157c-dk2 board, the FWU metadata is stored on the uSD card. Add the fwu-mdata node on the u-boot specifc dtsi file for accessing the metadata structure. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick

[PATCH v11 05/15] stm32mp1: dk2: Add image information for capsule updates

2022-09-28 Thread Sughosh Ganu
Enabling capsule update functionality on the platform requires populating information on the images that are to be updated using the functionality. Do so for the DK2 board. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Reviewed-by: Ilias Apalodimas --- Changes since V10: * Use

[PATCH v11 06/15] FWU: Add helper functions for accessing FWU metadata

2022-09-28 Thread Sughosh Ganu
ction. The function to get the dfu alternate number has been added for platforms with GPT partitioned storage devices. Platforms with other storage partition scheme need to implement their own function. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Acked-by: Etienne Carriere --- Ch

[PATCH v11 07/15] FWU: STM32MP1: Add support to read boot index from backup register

2022-09-28 Thread Sughosh Ganu
value is passed through one of the SoC's backup register. Add a function to read the boot index value from the backup register. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Acked-by: Ilias Apalodimas --- Changes since V10: * Remove the casting of boot_idx to a u32 as suggest

[PATCH v11 08/15] event: Add an event for main_loop

2022-09-28 Thread Sughosh Ganu
Add an event type EVT_MAIN_LOOP that can be used for registering events that need to be run after the platform has been initialised and before the main_loop function is called. Signed-off-by: Sughosh Ganu Reviewed-by: Simon Glass Reviewed-by: Ilias Apalodimas --- Changes since V10: None

[PATCH v11 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-09-28 Thread Sughosh Ganu
set the updated bank as active bank to subsequently boot from. Signed-off-by: Sughosh Ganu --- Changes since V10: * Move the computation of the image index to the FMP set_image function as suggested by Takahiro * Use true and false booleans for fw_accept_os as suggested by Jassi * Simplify the

[PATCH v11 09/15] FWU: Add boot time checks as highlighted by the FWU specification

2022-09-28 Thread Sughosh Ganu
system boots in the Trial State for more than a specified number of boot counts, change the Active Bank to be booting the platform from. Call these checks through the main loop event at the time of platform boot. Signed-off-by: Sughosh Ganu Reviewed-by: Etienne Carriere --- Changes since V10

[PATCH v11 11/15] FWU: cmd: Add a command to read FWU metadata

2022-09-28 Thread Sughosh Ganu
Add a command to read the metadata as specified in the FWU specification and print the fields of the metadata. Signed-off-by: Sughosh Ganu Reviewed-by: Ilias Apalodimas Reviewed-by: Etienne Carriere --- Changes since V10: None cmd/Kconfig | 6 +++ cmd/Makefile

[PATCH v11 12/15] test: dm: Add test cases for FWU Metadata uclass

2022-09-28 Thread Sughosh Ganu
-- the FIT capsule test will be run on the sandbox_flattree variant. Signed-off-by: Sughosh Ganu Suggested-by: Heinrich Schuchardt --- Changes since V10: None arch/sandbox/Kconfig | 6 + arch/sandbox/dts/test.dts | 7 +- board/sandbox/sandbox.c

[PATCH v11 13/15] mkeficapsule: Add support for generating empty capsules

2022-09-28 Thread Sughosh Ganu
://git.codelinaro.org/linaro/dependable-boot/mbfw/uploads/6f7ddfe3be24e18d4319e108a758d02e/mbfw.pdf Signed-off-by: Sughosh Ganu --- Changes since V10: None doc/mkeficapsule.1 | 29 + tools/eficapsule.h | 8 tools/mkeficapsule.c | 96 3 files

[PATCH v11 14/15] mkeficapsule: Add support for setting OEM flags in capsule header

2022-09-28 Thread Sughosh Ganu
: Sughosh Ganu Reviewed-by: Ilias Apalodimas --- Changes since V10: None doc/mkeficapsule.1 | 4 tools/mkeficapsule.c | 17 ++--- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/doc/mkeficapsule.1 b/doc/mkeficapsule.1 index 77ca061efd..6fb2dd0810 100644 --- a/doc

[PATCH v11 15/15] FWU: doc: Add documentation for the FWU feature

2022-09-28 Thread Sughosh Ganu
Add documentation for the FWU Multi Bank Update feature. The document describes the steps needed for setting up the platform for the feature, as well as steps for enabling the feature on the platform. Signed-off-by: Sughosh Ganu --- Changes since V10: * Fix review comments suggested by Etienne

Re: [PATCH v10 02/15] FWU: Add FWU metadata structure and driver for accessing metadata

2022-09-28 Thread Sughosh Ganu
On Thu, 29 Sept 2022 at 00:59, Jassi Brar wrote: > > On Wed, Sep 28, 2022 at 1:00 AM Sughosh Ganu wrote: > > > > On Tue, 27 Sept 2022 at 21:55, Jassi Brar wrote: > > > > > > On Tue, Sep 27, 2022 at 2:14 AM Sughosh Ganu > > > wrote: > > &g

Re: [PATCH v11 15/15] FWU: doc: Add documentation for the FWU feature

2022-09-30 Thread Sughosh Ganu
hi Etienne, On Fri, 30 Sept 2022 at 11:57, Etienne Carriere wrote: > > Hello Sughosh, > > 2 comments on the documentation. Otherwise it looks all good to me. > > Best regards, > Etienne > > On Wed, 28 Sept 2022 at 11:31, Sughosh Ganu wrote: > > > > A

Re: [PATCH v11 02/15] FWU: Add FWU metadata structure and driver for accessing metadata

2022-10-02 Thread Sughosh Ganu
hi Etienne, On Fri, 30 Sept 2022 at 11:24, Etienne Carriere wrote: > > Hello Sughosh, > > On Wed, 28 Sept 2022 at 11:30, Sughosh Ganu wrote: > > > > In the FWU Multi Bank Update feature, the information about the > > updatable images is stored as part of the meta

Re: [PATCH v11 09/15] FWU: Add boot time checks as highlighted by the FWU specification

2022-10-03 Thread Sughosh Ganu
hi Ilias, On Mon, 3 Oct 2022 at 15:26, Ilias Apalodimas wrote: > > On Wed, Sep 28, 2022 at 02:59:50PM +0530, Sughosh Ganu wrote: > > The FWU Multi Bank Update specification requires the Update Agent to > > carry out certain checks at the time of platform boot. The Updat

Re: [PATCH v11 05/15] stm32mp1: dk2: Add image information for capsule updates

2022-10-03 Thread Sughosh Ganu
hi Takahiro, On Mon, 3 Oct 2022 at 16:27, Takahiro Akashi wrote: > > Hi Sughosh, > > On Wed, Sep 28, 2022 at 02:59:46PM +0530, Sughosh Ganu wrote: > > Enabling capsule update functionality on the platform requires > > populating information on the images that are

[PATCH v12 00/15] FWU: Add FWU Multi Bank Update feature support

2022-10-03 Thread Sughosh Ganu
() * Describe the config CONFIG_CMD_FWU_METADATA separately * Remove some superfluous configs from the list of config symbols needed for building the feature Sughosh Ganu (15): dt/bindings: Add bindings for GPT based FWU Metadata storage device FWU: Add FWU metadata structure and driver for

[PATCH v12 01/15] dt/bindings: Add bindings for GPT based FWU Metadata storage device

2022-10-03 Thread Sughosh Ganu
devices. Signed-off-by: Sughosh Ganu Reviewed-by: Heinrich Schuchardt Acked-by: Etienne Carriere Reviewed-by: Ilias Apalodimas --- Changes since V11: None .../firmware/fwu-mdata-gpt.yaml | 32 +++ 1 file changed, 32 insertions(+) create mode 100644 doc/device-tree

[PATCH v12 02/15] FWU: Add FWU metadata structure and driver for accessing metadata

2022-10-03 Thread Sughosh Ganu
, and implementations can be added based on parameters like how the metadata partition is accessed and what type of storage device houses the metadata. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Reviewed-by: Etienne Carriere --- Changes since V11: * Use an enum for IMAGE_ACCEP

[PATCH v12 03/15] FWU: Add FWU metadata access driver for GPT partitioned block devices

2022-10-03 Thread Sughosh Ganu
based partition scheme. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Reviewed-by: Etienne Carriere --- Changes since V11: * Declare mdata_parts as an array in gpt_get_mdata_partitions() * Put the assignment to the return value in gpt_check_mdata_validity() as suggested by Etienne

[PATCH v12 04/15] stm32mp1: dk2: Add a node for the FWU metadata device

2022-10-03 Thread Sughosh Ganu
The FWU metadata structure is accessed through the driver model interface. On the stm32mp157c-dk2 board, the FWU metadata is stored on the uSD card. Add the fwu-mdata node on the u-boot specifc dtsi file for accessing the metadata structure. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick

[PATCH v12 05/15] stm32mp1: Add image information for capsule updates

2022-10-03 Thread Sughosh Ganu
Enabling capsule update functionality on the platform requires populating information on the images that are to be updated using the functionality. Do so for the DK2 board. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Reviewed-by: Ilias Apalodimas Reviewed-by: Etienne Carriere

[PATCH v12 06/15] FWU: Add helper functions for accessing FWU metadata

2022-10-03 Thread Sughosh Ganu
ction. The function to get the dfu alternate number has been added for platforms with GPT partitioned storage devices. Platforms with other storage partition scheme need to implement their own function. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Acked-by: Etienne Carriere --- Ch

[PATCH v12 07/15] FWU: STM32MP1: Add support to read boot index from backup register

2022-10-03 Thread Sughosh Ganu
value is passed through one of the SoC's backup register. Add a function to read the boot index value from the backup register. Signed-off-by: Sughosh Ganu Reviewed-by: Patrick Delaunay Acked-by: Ilias Apalodimas --- Changes since V11: None arch/arm/mach-stm32mp/include/mach/stm32.h

[PATCH v12 08/15] event: Add an event for main_loop

2022-10-03 Thread Sughosh Ganu
Add an event type EVT_MAIN_LOOP that can be used for registering events that need to be run after the platform has been initialised and before the main_loop function is called. Signed-off-by: Sughosh Ganu Reviewed-by: Simon Glass --- Changes since V11: None common/board_r.c | 3 +++ common

[PATCH v12 09/15] FWU: Add boot time checks as highlighted by the FWU specification

2022-10-03 Thread Sughosh Ganu
system boots in the Trial State for more than a specified number of boot counts, change the Active Bank to be booting the platform from. Call these checks through the main loop event at the time of platform boot. Signed-off-by: Sughosh Ganu Reviewed-by: Etienne Carriere --- Changes since V11

[PATCH v12 10/15] FWU: Add support for the FWU Multi Bank Update feature

2022-10-03 Thread Sughosh Ganu
set the updated bank as active bank to subsequently boot from. Signed-off-by: Sughosh Ganu --- Changes since V11: None drivers/Kconfig | 2 + drivers/Makefile | 1 + include/fwu.h | 30 + lib/Kconfig | 6 + lib/Makefile

[PATCH v12 11/15] FWU: cmd: Add a command to read FWU metadata

2022-10-03 Thread Sughosh Ganu
Add a command to read the metadata as specified in the FWU specification and print the fields of the metadata. Signed-off-by: Sughosh Ganu Reviewed-by: Ilias Apalodimas Reviewed-by: Etienne Carriere --- Changes since V11: None cmd/Kconfig | 6 +++ cmd/Makefile

[PATCH v12 12/15] test: dm: Add test cases for FWU Metadata uclass

2022-10-03 Thread Sughosh Ganu
-- the FIT capsule test will be run on the sandbox_flattree variant. Signed-off-by: Sughosh Ganu Suggested-by: Heinrich Schuchardt --- arch/sandbox/Kconfig | 6 + arch/sandbox/dts/test.dts | 7 +- board/sandbox/sandbox.c | 8

[PATCH v12 13/15] mkeficapsule: Add support for generating empty capsules

2022-10-03 Thread Sughosh Ganu
://git.codelinaro.org/linaro/dependable-boot/mbfw/uploads/6f7ddfe3be24e18d4319e108a758d02e/mbfw.pdf Signed-off-by: Sughosh Ganu --- Changes since V11: None doc/mkeficapsule.1 | 29 + tools/eficapsule.h | 8 tools/mkeficapsule.c | 96 3 files

[PATCH v12 14/15] mkeficapsule: Add support for setting OEM flags in capsule header

2022-10-03 Thread Sughosh Ganu
: Sughosh Ganu Reviewed-by: Ilias Apalodimas --- Changes since V11: None doc/mkeficapsule.1 | 4 tools/mkeficapsule.c | 17 ++--- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/doc/mkeficapsule.1 b/doc/mkeficapsule.1 index 77ca061efd..6fb2dd0810 100644 --- a/doc

[PATCH v12 15/15] FWU: doc: Add documentation for the FWU feature

2022-10-03 Thread Sughosh Ganu
Add documentation for the FWU Multi Bank Update feature. The document describes the steps needed for setting up the platform for the feature, as well as steps for enabling the feature on the platform. Signed-off-by: Sughosh Ganu --- Changes since V11: * Describe the config

<    1   2   3   4   5   6   7   8   9   10   >