From bcc7eefa4c6cce0c719296dcdc40a353160633fc Mon Sep 17 00:00:00 2001 From: Jonas Karlman Date: Thu, 3 Oct 2024 19:59:34 +0000 Subject: board: rockchip: Add Hardkernel ODROID-M2 The Hardkernel ODROID-M2 is a single-board computer based on Rockchip RK3588S2 SoC. It features e.g. 8/16 GB LPDDR5 RAM, 64 GB eMMC, SD-card, GbE LAN, HDMI 2.0, M.2 NVMe and USB 2.0/3.0/Type-C. Features tested on a ODROID-M2 16GB rev1.0 20240611: - SD-card boot - eMMC boot - Ethernet - PCIe/NVMe - USB gadget - USB host Signed-off-by: Jonas Karlman Reviewed-by: Kever Yang --- include/configs/odroid_m2.h | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 include/configs/odroid_m2.h (limited to 'include') diff --git a/include/configs/odroid_m2.h b/include/configs/odroid_m2.h new file mode 100644 index 00000000000..c5ed42cd2e7 --- /dev/null +++ b/include/configs/odroid_m2.h @@ -0,0 +1,11 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ + +#ifndef __ODROID_M2_H +#define __ODROID_M2_H + +#define ROCKCHIP_DEVICE_SETTINGS \ + "cramfsaddr=0x0c000000\0" + +#include + +#endif -- cgit v1.2.3 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 --- include/fdt_support.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/fdt_support.h b/include/fdt_support.h index 741e2360c22..9447a64e060 100644 --- a/include/fdt_support.h +++ b/include/fdt_support.h @@ -202,7 +202,8 @@ int ft_board_setup(void *blob, struct bd_info *bd); * * This function is called if CONFIG_BOARD_RNG_SEED is set, and must * be provided by the board. It should return, via @buf, some suitable - * seed value to pass to the kernel. + * seed value to pass to the kernel. Seed size could be set in a decimal + * environment variable rng_seed_size and it defaults to 64 bytes. * * @param buf A struct abuf for returning the seed and its size. * @return 0 if ok, negative on error. -- cgit v1.2.3