mbox series

[RFC,v2,0/8] FWU: Add FWU Multi Bank Update for DeveloerBox

Message ID 164511067605.43219.15508992404634142079.stgit@localhost
Headers show
Series FWU: Add FWU Multi Bank Update for DeveloerBox | expand

Message

Masami Hiramatsu Feb. 17, 2022, 3:11 p.m. UTC
Hi,

Here is the 2nd version of RFC series of patches for the FWU Multi
Bank Update support for the DeveloperBox platform.
This series depends on Sughosh's Multi Bank Update v4 [1].

[1] https://lore.kernel.org/all/20220207182001.31270-1-sughosh.ganu@linaro.org/T/#u

Unlike the STM32MP board, DeveloperBox (SynQuacer) loads the firmware
from SPI NOR flash. Thus it doesn't use GPT partitions to store the
firmware banks and the FWU metadata. Instead, it stores those data
at fixed address areas on SPI NOR flash. I carefully chose the areas
which doesn't overlap the previous firmware and EDK2.

This adds FWU metadata SF driver for this FWU multi bank support
on SPI flash without GPT. This is identified by "u-boot,fwu-mdata-sf".
The last patch adds the DT bindings in YAML.

Since there is no GPT, the location GUID for images and the image
GUID for banks are Null GUID. I will fix this with uuid property
for fixed-partition devicetree afterwards.

And the SynQuacer also does not have any non-volatile register.
Thus this allocates the platform defined boot index on the SPI flash
too.

NOTE: To use this series, you also need to update SCP firmware[2] and
TF-A[3] on the DeveloperBox. Those are under cleaning up.

[2] https://git.linaro.org/people/masami.hiramatsu/SCP-firmware.git/
[3] https://git.linaro.org/people/masami.hiramatsu/arm-trusted-firmware.git/

Thank you,

---

Masami Hiramatsu (8):
      FWU: Calculate CRC32 in fwu_update_mdata()
      FWU: Free metadata copy if gpt_get_mdata() failed
      synquacer: Update for TBBR based new FIP layout
      dt/bindings: firmware: Add FWU metadata on SPI flash binding
      FWU: Add FWU metadata access driver for SPI flash
      FWU: synquacer: Add FWU Multi bank update support for DeveloperBox
      FWU: synquacer: Initialize broken metadata
      configs: synquacer: Add FWU support for DeveloperBox


 .../dts/synquacer-sc2a11-developerbox-u-boot.dtsi  |   33 ++
 board/socionext/developerbox/Kconfig               |   24 ++
 board/socionext/developerbox/Makefile              |    1 
 board/socionext/developerbox/fwu_plat.c            |  238 ++++++++++++++++
 configs/synquacer_developerbox_defconfig           |   12 +
 .../firmware/fwu-mdata-sf.yaml                     |   38 +++
 drivers/fwu-mdata/Kconfig                          |    9 +
 drivers/fwu-mdata/Makefile                         |    1 
 drivers/fwu-mdata/fwu-mdata-uclass.c               |   57 +---
 drivers/fwu-mdata/fwu_mdata_gpt_blk.c              |   49 ++-
 drivers/fwu-mdata/fwu_mdata_sf.c                   |  294 ++++++++++++++++++++
 include/configs/synquacer.h                        |   14 +
 include/fwu.h                                      |    2 
 13 files changed, 698 insertions(+), 74 deletions(-)
 create mode 100644 board/socionext/developerbox/fwu_plat.c
 create mode 100644 doc/device-tree-bindings/firmware/fwu-mdata-sf.yaml
 create mode 100644 drivers/fwu-mdata/fwu_mdata_sf.c

--
Masami Hiramatsu <masami.hiramatsu@linaro.org>