From ed4ae7386257aa66455e330234e513d098a36f84 Mon Sep 17 00:00:00 2001 From: Alex Shumsky Date: Wed, 16 Oct 2024 13:02:03 +0300 Subject: rockchip: board: Increase rng-seed size to make it sufficient for modern Linux Increase rng-seed size to make Linux happy and initialize rng pool instantly. Linux 5.19+ requires 32 bytes of entropy to initialize random pool, but u-boot currently provides only 8 bytes. Linux 5.18 and probably some versions before it used to require 64 bytes. Bump min value to 64 bytes to be on a safe side. Boot with 8 byte rng-seed (Linux 6.11): # dmesg | grep crng [ 12.089286] random: crng init done Boot with 32 byte rng-seed (Linux 6.11): # dmesg | grep crng [ 0.000000] random: crng init done Linux source references: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/char/random.c?h=v5.19#n551 https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/char/random.c?h=v5.18#n236 Signed-off-by: Alex Shumsky Fixes: d2048bafae40 ("rockchip: board: Add board_rng_seed() for all Rockchip devices") Reviewed-by: Dragan Simic Reviewed-by: Marek Vasut Reviewed-by: Quentin Schulz Reviewed-by: Kever Yang --- doc/usage/environment.rst | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'doc/usage') diff --git a/doc/usage/environment.rst b/doc/usage/environment.rst index cc33d3ec0f2..7bd9ffce8d8 100644 --- a/doc/usage/environment.rst +++ b/doc/usage/environment.rst @@ -323,6 +323,11 @@ netretry Useful on scripts which control the retry operation themselves. +rng_seed_size + Size of random value added to device-tree node /chosen/rng-seed. + This variable is given as a decimal number. + If unset, 64 bytes is used as the default. + silent_linux If set then Linux will be told to boot silently, by adding 'console=' to its command line. If "yes" it will be -- cgit v1.3.1