U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Andre Przywara <andre.przywara@arm.com>
To: Debbie Horsfall <debbie.horsfall@arm.com>
Cc: <u-boot@lists.denx.de>, <trini@konsulko.com>,
	<fenghua@phytium.com.cn>, <linus.walleij@linaro.org>,
	<Peter.Hoyes@arm.com>, <liviu.dudau@foss.arm.com>
Subject: Re: [PATCH 1/2] vexpress64: Set the DM_RNG property
Date: Fri, 12 Sep 2025 15:26:59 +0100	[thread overview]
Message-ID: <20250912152659.42851235@donnerap> (raw)
In-Reply-To: <20250910151342.204255-1-debbie.horsfall@arm.com>

On Wed, 10 Sep 2025 16:13:41 +0100
Debbie Horsfall <debbie.horsfall@arm.com> wrote:

Hi,

> Enable the DM_RNG virtio random number generator driver in order to
> consume entropy within U-Boot. This allows U-Boot to inject entropy to the
> kernel via UEFI, so the kernel can use that early, for instance for
> address layout randomisation, or when the kernel does not provide an
> entropy driver itself.

The change looks alright, but is a bit useless on its own, since there
wouldn't be a usable entropy source by default:
- The FVP optionally provides a VIRTIO_RNG device, and this can be simply
enabled on the FVP command line (*.virtio_rng.enabled=1). But the normal
DTs omit the required DT node, since that would cause SErrors when the
command line option is not provided, so this still doesn't show up, even
when now CONFIG_VIRTIO_RNG is set.
- The FVP model can provide the ARMv8.4 FEAT_RNG system registers
(cluster<x>.has_rndr=1), but the feature is not enabled in any of the
VExpress64 builds. This feature uses auto-detection, so it doesn't hurt to
have it always in.

So I would suggest to enable CONFIG_RNG_ARM_RNDR here as well (another
imply line?), to make this more useful.

Cheers,
Andre

> 
> Signed-off-by: Debbie Horsfall <debbie.horsfall@arm.com>
> ---
>  board/armltd/vexpress64/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/board/armltd/vexpress64/Kconfig b/board/armltd/vexpress64/Kconfig
> index 7e8709444fe..f413c51ac43 100644
> --- a/board/armltd/vexpress64/Kconfig
> +++ b/board/armltd/vexpress64/Kconfig
> @@ -21,6 +21,7 @@ config VEXPRESS64_BASE_MODEL
>  	imply EFI_SET_TIME if DM_RTC
>  	select LINUX_KERNEL_IMAGE_HEADER
>  	select POSITION_INDEPENDENT
> +	imply DM_RNG
>  
>  choice
>  	prompt "VExpress64 board variant"


      parent reply	other threads:[~2025-09-12 14:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-10 15:13 [PATCH 1/2] vexpress64: Set the DM_RNG property Debbie Horsfall
2025-09-10 15:13 ` [PATCH 2/2] arm: vexpress64: Enable SYSRESET and SYSRESET_PSCI Debbie Horsfall
2025-09-12 14:26   ` Andre Przywara
2025-09-12 14:26 ` Andre Przywara [this message]

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=20250912152659.42851235@donnerap \
    --to=andre.przywara@arm.com \
    --cc=Peter.Hoyes@arm.com \
    --cc=debbie.horsfall@arm.com \
    --cc=fenghua@phytium.com.cn \
    --cc=linus.walleij@linaro.org \
    --cc=liviu.dudau@foss.arm.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox