[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20251126-b4-m5441x-add-rng-support-v4-0-5309548c9555@yoseli.org>
Date: Wed, 26 Nov 2025 08:08:08 +0100
From: Jean-Michel Hautbois via B4 Relay <devnull+jeanmichel.hautbois.yoseli.org@...nel.org>
To: Greg Ungerer <gerg@...ux-m68k.org>,
Geert Uytterhoeven <geert@...ux-m68k.org>,
Olivia Mackall <olivia@...enic.com>,
Herbert Xu <herbert@...dor.apana.org.au>, Shawn Guo <shawnguo@...nel.org>,
Sascha Hauer <s.hauer@...gutronix.de>,
Pengutronix Kernel Team <kernel@...gutronix.de>,
Fabio Estevam <festevam@...il.com>
Cc: linux-m68k@...ts.linux-m68k.org, linux-kernel@...r.kernel.org,
linux-crypto@...r.kernel.org, imx@...ts.linux.dev,
linux-arm-kernel@...ts.infradead.org,
Jean-Michel Hautbois <jeanmichel.hautbois@...eli.org>,
Frank Li <Frank.Li@....com>
Subject: [PATCH v4 0/2] m68k: coldfire: Add RNG support for MCF54418
This series adds support for the MCF54418 hardware random number generator
(RNGB).
The MCF54418 contains an RNGB hardware block compatible with the imx-rngc
driver. This series enables its use by:
- Adding platform device registration for the RNG hardware
- Enabling the clock at platform initialization
- Making the imx-rngc driver compatible with Coldfire's always-on clock
model using devm_clk_get_optional()
Testing on DLC Next board shows:
- Hardware RNG throughput: 26 MB/s
- FIPS 140-2 quality: 0.2% failure rate (rng-tools)
- Boot time improvement: CRNG initialization 7 seconds faster
Signed-off-by: Jean-Michel Hautbois <jeanmichel.hautbois@...eli.org>
---
Changes in v4:
- Postpone const qualifiers for now
- Link to v3: https://lore.kernel.org/r/20251124-b4-m5441x-add-rng-support-v3-0-f447251dad27@yoseli.org
Changes in v3:
- Depend on COLDFIRE is enough
- Split the clock change in a dedicated commit
- Link to v2: https://lore.kernel.org/r/20251107-b4-m5441x-add-rng-support-v2-0-f91d685832b9@yoseli.org
Changes in v2:
- Split const qualifier changes into a separate patch as suggested by
Frank Li
- Mark all resource arrays (including RNG) as const in device.c
- No functional changes to RNG implementation
---
Jean-Michel Hautbois (2):
hwrng: imx-rngc: Use optional clock
m68k: coldfire: Add RNG support for MCF54418
arch/m68k/coldfire/device.c | 28 ++++++++++++++++++++++++++++
arch/m68k/coldfire/m5441x.c | 2 +-
arch/m68k/include/asm/m5441xsim.h | 9 +++++++++
drivers/char/hw_random/Kconfig | 3 ++-
drivers/char/hw_random/imx-rngc.c | 9 ++++++++-
5 files changed, 48 insertions(+), 3 deletions(-)
---
base-commit: ac3fd01e4c1efce8f2c054cdeb2ddd2fc0fb150d
change-id: 20251107-b4-m5441x-add-rng-support-0fdb8d40210a
Best regards,
--
Jean-Michel Hautbois <jeanmichel.hautbois@...eli.org>
Powered by blists - more mailing lists