Skip to content

crypto/fsl: add RNG support

Michael Walle u-boot 6 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest6 patches 0 repliesNew
  2. v3 posting 3/30 of 6 patches 0 repliesSuperseded
  3. v3 posting 2/30 of 6 patches 0 repliesSuperseded
Earlier versions · 3
VersionPostedPatchesRepliesStatus
v3 posting 1/36 patches0 repliesSuperseded
v26 patches0 repliesSuperseded
v14 patches0 repliesSuperseded

Changes in v4 from the cover letter

- use private data instead of platform data in RNG driver, thanks Heinrich
- align end address of any invalidate/flush_dcache_range(), thanks Heinrich
- because we do the alignment ourself, use memalign() again (instead of malloc_cache_aligned())

Patches in v4 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6crypto/fsl: make SEC%u status line consistentdrivers/crypto/fsl/jr.c+7 -70 replies
2/6crypto/fsl: export caam_get_era()drivers/crypto/fsl/sec.c include/fsl_sec.h+11 -10 replies
3/6crypto/fsl: support newer SEC modulesdrivers/crypto/fsl/jr.c include/fsl_sec.h+54 -90 replies
4/6crypto/fsl: don't regenerate secure keysdrivers/crypto/fsl/jobdesc.c drivers/crypto/fsl/jobdesc.h drivers/crypto/fsl/jr.c +1 more+9 -70 replies
5/6crypto/fsl: instantiate the RNG with prediciton resistancedrivers/crypto/fsl/desc.h drivers/crypto/fsl/jobdesc.c drivers/crypto/fsl/jobdesc.h +2 more+79 -110 replies
6/6crypto/fsl: add RNG supportdrivers/crypto/fsl/Kconfig drivers/crypto/fsl/Makefile drivers/crypto/fsl/jobdesc.c +3 more+125 -01 reply

Reviews trailers per patch

4 of 6 patches have a Reviewed-by or Acked-by.

PatchHoria Geant?Heinrich Schuchardt
1/6R-b
2/6R-b
3/6R-b
4/6R-b
5/6
6/6T-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v4 thread

Cover letter [PATCH v4 0/6] crypto/fsl: add RNG support

First, improve the compatibility on newer Era CAAMs. These introduced new version registers. Secondly, add RNG support for the CAAM. This way we get random number generator support for EFI for free and KASLR will work with ARM64 kernels booted with bootefi.

Changes since v3:
- use private data instead of platform data in RNG driver, thanks Heinrich
- align end address of any invalidate/flush_dcache_range(), thanks Heinrich
- because we do the alignment ourself, use memalign() again (instead of malloc_cache_aligned())

Changes since v2:
- fix descriptor size of the deinstantiate descriptor
- use malloc_cache_aligned() instead of memalign(ARCH_DMA_MINALIGN..)
- don't check the RDSTA_PR() bit
- fix memcpy() length
- flush the dcache where the rng job description resides

Changes since v1:
- instantiate RNG with prediction resistance
- add annotation for caam_get_era()
- fix all prints to match u-boots status lines
- remove superfluous #ifdef CONFIG_DM_RNG
- changed kconfig help text

Michael Walle (6):
crypto/fsl: make SEC%u status line consistent crypto/fsl: export caam_get_era()
crypto/fsl: support newer SEC modules crypto/fsl: don't regenerate secure keys crypto/fsl: instantiate the RNG with prediciton resistance crypto/fsl: add RNG support

 drivers/crypto/fsl/Kconfig   |  14 +++++
 drivers/crypto/fsl/Makefile  |   1 +
 drivers/crypto/fsl/desc.h    |   2 +
 drivers/crypto/fsl/jobdesc.c |  26 +++++++-
 drivers/crypto/fsl/jobdesc.h |   7 ++-
 drivers/crypto/fsl/jr.c      | 111 +++++++++++++++++++++++++++++------
 drivers/crypto/fsl/rng.c     |  88 +++++++++++++++++++++++++++
 drivers/crypto/fsl/sec.c     |  10 +++-
 include/fsl_sec.h            |  61 +++++++++++++++----
 9 files changed, 285 insertions(+), 35 deletions(-)
 create mode 100644 drivers/crypto/fsl/rng.c
Signature · 1 line
2.20.1