public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Kory Maincent <kory.maincent@bootlin.com>
To: u-boot@lists.denx.de
Cc: "Thomas Petazzoni" <thomas.petazzoni@bootlin.com>,
	"Tom Rini" <trini@konsulko.com>,
	"Patrice Chotard" <patrice.chotard@foss.st.com>,
	"Paul HENRYS" <paul.henrys_ext@softathome.com>,
	"Sughosh Ganu" <sughosh.ganu@arm.com>,
	"Greg Malysa" <malysagreg@gmail.com>,
	"Arturs Artamonovs" <arturs.artamonovs@analog.com>,
	"Vasileios Bimpikas" <vasileios.bimpikas@analog.com>,
	"Utsav Agarwal" <utsav.agarwal@analog.com>,
	"Nathan Barrett-Morrison" <nathan.morrison@timesys.com>,
	"Peng Fan" <peng.fan@nxp.com>, "Simon Glass" <sjg@chromium.org>,
	"Duje Mihanović" <duje@dujemihanovic.xyz>,
	"Stefan Roese" <stefan.roese@mailbox.org>,
	"Mattijs Korpershoek" <mkorpershoek@kernel.org>,
	"Sumit Garg" <sumit.garg@kernel.org>,
	"Heiko Schocher" <hs@nabladev.com>,
	"Alif Zakuan Yuslaimi" <alif.zakuan.yuslaimi@altera.com>,
	"E Shattow" <e@freeshell.de>,
	"Raymond Mao" <raymondmaoca@gmail.com>,
	"Jan Kiszka" <jan.kiszka@siemens.com>,
	"Shiji Yang" <yangshiji66@outlook.com>,
	"Daniel Golle" <daniel@makrotopia.org>,
	"Heinrich Schuchardt" <xypron.glpk@gmx.de>,
	"Ilias Apalodimas" <ilias.apalodimas@linaro.org>,
	"Leonard Anderweit" <l.anderweit@phytec.de>,
	"Kory Maincent" <kory.maincent@bootlin.com>,
	"Yao Zi" <me@ziyao.cc>
Subject: [PATCH v4 0/6] Add support for fwumdata
Date: Mon, 23 Feb 2026 14:18:34 +0100	[thread overview]
Message-ID: <20260223-feature_fwumdata-v4-0-680ea4ad6ce6@bootlin.com> (raw)

Add a new fwumdata tool to allows users to read, display, and modify FWU
(Firmware Update) metadata from Linux userspace. It provides functionality
similar to fw_printenv/fw_setenv but for FWU metadata. Users can view
metadata, change active/previous bank indices, modify bank states, and set
image acceptance flags. Configuration is done via fwumdata.config file.

Made a few change to mkfwumdata tool along the way.

Here is an output example

$ ./fwumdata -l
FWU Metadata:
	Version:            2
	Active Index:       0
	Previous Index:     1
	CRC32:              0x1f21ff7b
	Metadata Size:      120 bytes
	Descriptor Offset:  32
	Bank States:
		Bank 0: accepted (0xfc)
		Bank 1: accepted (0xfc)

	Firmware Store Descriptor:
		Number of Banks:       2
		Number of Images:      1
		Image Entry Size:      80
		Bank Info Entry Size:  24

	Images:
		Image 0:
			Image Type GUID:  65ae85ad-1fb3-0b46-8c5d-285543aa6eab
			Location GUID:    51513491-da07-2a4f-9bea-375ea53b1b5c
			Banks:
				Bank 0:
					Image GUID:  cb2df442-f929-6a44-a374-672d92eb2aa7
					Accepted:    yes (1)
				Bank 1:
					Image GUID:  a839a18f-395c-484f-83b8-0354077c8f9f
					Accepted:    yes (1)

Changes in v4:
- Add missing "always" suffix in Makefile description
- Link to v3: https://lore.kernel.org/r/20260216-feature_fwumdata-v3-0-9ecc5b10456d@bootlin.com

Changes in v3:
- Rebase on master.
- Link to v2: https://lore.kernel.org/r/20251212-feature_fwumdata-v2-0-ad51572fbe79@bootlin.com

Changes in v2:
- Fix a small offset mistake in last patch

Signed-off-by: Kory Maincent <kory.maincent@bootlin.com>
---
Kory Maincent (6):
      tools: gitignore: Add mkfwumdata to the git ignore file
      tools: Reorganize mkfwumdata tool into fwumdata_src directory
      tools: mkfwumdata: Improve error message specificity
      tools: mkfwumdata: Add bank count validation for FWU metadata v2
      tools: Add support for fwumdata tool
      tools: mkfwumdata: Remove dependency on fwu_mdata.h header

 MAINTAINERS                           |   7 +-
 doc/develop/uefi/fwu_updates.rst      |   4 +-
 doc/fwumdata.1                        | 222 +++++++++
 tools/.gitignore                      |   2 +
 tools/Kconfig                         |   9 +-
 tools/Makefile                        |   4 +-
 tools/fwumdata_src/Kconfig            |  19 +
 tools/fwumdata_src/fwumdata.c         | 854 ++++++++++++++++++++++++++++++++++
 tools/fwumdata_src/fwumdata.config    |  33 ++
 tools/fwumdata_src/fwumdata.h         | 138 ++++++
 tools/fwumdata_src/fwumdata.mk        |  10 +
 tools/{ => fwumdata_src}/mkfwumdata.c | 106 ++---
 12 files changed, 1315 insertions(+), 93 deletions(-)
---
base-commit: 30b8c03d8c8f500b3e4cc51f7b7abf573180ea51
change-id: 20251107-feature_fwumdata-58508d61e1d3

Best regards,
-- 
Köry Maincent, Bootlin
Embedded Linux and kernel engineering
https://bootlin.com


             reply	other threads:[~2026-02-23 13:19 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-23 13:18 Kory Maincent [this message]
2026-02-23 13:18 ` [PATCH v4 1/6] tools: gitignore: Add mkfwumdata to the git ignore file Kory Maincent
2026-02-23 13:18 ` [PATCH v4 2/6] tools: Reorganize mkfwumdata tool into fwumdata_src directory Kory Maincent
2026-02-23 13:18 ` [PATCH v4 3/6] tools: mkfwumdata: Improve error message specificity Kory Maincent
2026-02-23 13:18 ` [PATCH v4 4/6] tools: mkfwumdata: Add bank count validation for FWU metadata v2 Kory Maincent
2026-02-23 13:18 ` [PATCH v4 5/6] tools: Add support for fwumdata tool Kory Maincent
2026-02-23 13:18 ` [PATCH v4 6/6] tools: mkfwumdata: Remove dependency on fwu_mdata.h header Kory Maincent
2026-03-18 11:27 ` [PATCH v4 0/6] Add support for fwumdata Dario Binacchi
2026-03-25 10:29   ` Kory Maincent
2026-03-25 10:50     ` Sughosh Ganu

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=20260223-feature_fwumdata-v4-0-680ea4ad6ce6@bootlin.com \
    --to=kory.maincent@bootlin.com \
    --cc=alif.zakuan.yuslaimi@altera.com \
    --cc=arturs.artamonovs@analog.com \
    --cc=daniel@makrotopia.org \
    --cc=duje@dujemihanovic.xyz \
    --cc=e@freeshell.de \
    --cc=hs@nabladev.com \
    --cc=ilias.apalodimas@linaro.org \
    --cc=jan.kiszka@siemens.com \
    --cc=l.anderweit@phytec.de \
    --cc=malysagreg@gmail.com \
    --cc=me@ziyao.cc \
    --cc=mkorpershoek@kernel.org \
    --cc=nathan.morrison@timesys.com \
    --cc=patrice.chotard@foss.st.com \
    --cc=paul.henrys_ext@softathome.com \
    --cc=peng.fan@nxp.com \
    --cc=raymondmaoca@gmail.com \
    --cc=sjg@chromium.org \
    --cc=stefan.roese@mailbox.org \
    --cc=sughosh.ganu@arm.com \
    --cc=sumit.garg@kernel.org \
    --cc=thomas.petazzoni@bootlin.com \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    --cc=utsav.agarwal@analog.com \
    --cc=vasileios.bimpikas@analog.com \
    --cc=xypron.glpk@gmx.de \
    --cc=yangshiji66@outlook.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox