All of lore.kernel.org
 help / color / mirror / Atom feed
From: seanedmond@linux.microsoft.com
To: u-boot@lists.denx.de
Cc: dphadke@linux.microsoft.com, ilias.apalodimas@linaro.org,
	trini@konsulko.com, sjg@chromium.org
Subject: [PATCH v5 0/5] Populate kaslr seed with RNG
Date: Thu, 16 Nov 2023 18:02:01 -0800	[thread overview]
Message-ID: <20231117020207.948636-1-seanedmond@linux.microsoft.com> (raw)

From: Sean Edmond <seanedmond@microsoft.com>

This patch series creates a common API (fdt_fixup_kaslr_seed()) for 
populating the kaslr seed in the DTB.  Existing users (kaslrseed,
and ARMv8 sec firmware) have been updated to use this common API.

New functionality has been introduced to populate the kaslr using
the RNG.  This can be enabled with CONFIG_RNG_TPM_SEED.  

changes in v5:
- Always enable OFNODE_MULTI_TREE
- include dm/ofnode-decl.h instead of dm/ofnode.h
- cast buffer to (u8 *) in kaslrseed.c

changes in v4:
- Fix compile issue when CONFIG_OF_CONTROL not set

changes in v3:
- Populate with RNG device instead of TPM device (this is a more generic solution)
- Use event spy to do the FDT fixup
- fix compile error for sandbox for !OFNODE_MULTI_TREE

changes in v2:
- fdt_fixup_kaslr_seed() uses the ofnode API
- Add root_ofnode_from_fdt() to get the root node from an FDT and
  perform error checking on the oftree
- add comments to exported functions
- Add error checking in image_setup_libfdt() for return from
  fdt_tpm_kaslr_seed()
- uclass_get_device() -> uclass_first_device_err()
- Change default config for OFNODE_MULTI_TREE (y if !OF_LIVE)

Dhananjay Phadke (2):
  fdt: common API to populate kaslr seed
  fdt: kaslr seed from RNG device

Sean Edmond (3):
  cmd: kaslrseed: Use common API to fixup FDT
  dm: core: Modify default for OFNODE_MULTI_TREE
  fdt: Fix compile error for !OFNODE_MULTI_TREE

 arch/arm/cpu/armv8/sec_firmware.c | 39 ++++++++--------------
 boot/fdt_support.c                | 55 +++++++++++++++++++++++++++++++
 cmd/kaslrseed.c                   | 22 +++++--------
 drivers/core/Kconfig              |  3 +-
 drivers/core/ofnode.c             | 29 ++++++++++++----
 include/dm/ofnode.h               | 12 +++++++
 include/fdt_support.h             |  9 +++++
 lib/Kconfig                       |  7 ++++
 8 files changed, 130 insertions(+), 46 deletions(-)

-- 
2.42.0


             reply	other threads:[~2023-11-17  2:02 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-17  2:02 seanedmond [this message]
2023-11-17  2:02 ` [PATCH v5 1/5] fdt: common API to populate kaslr seed seanedmond
2023-11-29 17:47   ` Simon Glass
2023-11-17  2:02 ` [PATCH v5 2/5] fdt: kaslr seed from RNG device seanedmond
2023-11-18  7:33   ` Ilias Apalodimas
2023-11-22 23:55     ` Sean Edmond
2023-11-23  6:17       ` Ilias Apalodimas
2023-11-29 17:47   ` Simon Glass
2023-11-29 17:55     ` Ilias Apalodimas
2023-11-17  2:02 ` [PATCH v5 3/5] cmd: kaslrseed: Use common API to fixup FDT seanedmond
2023-11-29 17:47   ` Simon Glass
2023-11-17  2:02 ` [PATCH v5 4/5] dm: core: Modify default for OFNODE_MULTI_TREE seanedmond
2023-11-29 17:47   ` Simon Glass
2023-11-17  2:02 ` [PATCH v5 5/5] fdt: Fix compile error for !OFNODE_MULTI_TREE seanedmond
2023-11-29 17:47   ` Simon Glass

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=20231117020207.948636-1-seanedmond@linux.microsoft.com \
    --to=seanedmond@linux.microsoft.com \
    --cc=dphadke@linux.microsoft.com \
    --cc=ilias.apalodimas@linaro.org \
    --cc=sjg@chromium.org \
    --cc=trini@konsulko.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.