All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/5] FMP versioning support
@ 2023-03-23 11:09 Masahisa Kojima
  2023-03-23 11:09 ` [PATCH v4 1/5] efi_loader: store firmware version into FmpState variable Masahisa Kojima
                   ` (4 more replies)
  0 siblings, 5 replies; 14+ messages in thread
From: Masahisa Kojima @ 2023-03-23 11:09 UTC (permalink / raw)
  To: u-boot
  Cc: Heinrich Schuchardt, Ilias Apalodimas, Takahiro Akashi,
	Masahisa Kojima

Firmware version management is not implemented in the current
FMP implementation. This series aims to add the versioning support
in FMP.

EDK II reference implementation utilizes the FMP Payload Header
inserted right before the capsule payload. With this series,
U-Boot also follows the EDK II implementation.

Currently, there is no way to know the current running firmware
version through the EFI interface. FMP->GetImageInfo() returns
always 0 for the version number. So a user can not know that
expected firmware is running after the capsule update.

With this series applied, version number can be specified
in the capsule file generation with mkeficapsule tool, then
user can know the running firmware version through
FMP->GetImageInfo() and ESRT.

Note that this series does not mandate the FMP Payload Header,
compatible with boards that are already using the existing
U-Boot FMP implementation.
If no FMP Payload Header is found in the capsule file, fw_version,
lowest supported version, last attempt version and last attempt
status is set to 0 and this is the same behavior as existing FMP
implementation.

Major Changes in v4:
- add python-based test

Major Changes in v3:
- exclude CONFIG_FWU_MULTI_BANK_UPDATE case

Masahisa Kojima (5):
  efi_loader: store firmware version into FmpState variable
  efi_loader: versioning support in GetImageInfo
  efi_loader: check lowest supported version in capsule update
  mkeficapsule: add FMP Payload Header
  test/py: efi_capsule: test for FMP versioning

 doc/mkeficapsule.1                            |  16 +
 lib/efi_loader/efi_firmware.c                 | 328 ++++++++++++++++--
 test/py/tests/test_efi_capsule/conftest.py    |  58 ++++
 .../test_capsule_firmware_fit.py              | 187 ++++++++++
 .../test_capsule_firmware_raw.py              | 199 +++++++++++
 .../test_capsule_firmware_signed_fit.py       | 159 +++++++++
 .../test_capsule_firmware_signed_raw.py       | 169 +++++++++
 tools/eficapsule.h                            |  31 ++
 tools/mkeficapsule.c                          |  51 ++-
 9 files changed, 1161 insertions(+), 37 deletions(-)

-- 
2.17.1


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2023-03-29  7:46 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-03-23 11:09 [PATCH v4 0/5] FMP versioning support Masahisa Kojima
2023-03-23 11:09 ` [PATCH v4 1/5] efi_loader: store firmware version into FmpState variable Masahisa Kojima
2023-03-28 11:53   ` Ilias Apalodimas
2023-03-28 13:02     ` Ilias Apalodimas
2023-03-29  7:33       ` Masahisa Kojima
2023-03-29  7:45         ` Ilias Apalodimas
2023-03-23 11:09 ` [PATCH v4 2/5] efi_loader: versioning support in GetImageInfo Masahisa Kojima
2023-03-28  6:52   ` Ilias Apalodimas
2023-03-23 11:09 ` [PATCH v4 3/5] efi_loader: check lowest supported version in capsule update Masahisa Kojima
2023-03-28  6:54   ` Ilias Apalodimas
2023-03-23 11:09 ` [PATCH v4 4/5] mkeficapsule: add FMP Payload Header Masahisa Kojima
2023-03-28  6:55   ` Ilias Apalodimas
2023-03-23 11:09 ` [PATCH v4 5/5] test/py: efi_capsule: test for FMP versioning Masahisa Kojima
2023-03-28  6:55   ` Ilias Apalodimas

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.