devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4] crypto: sun8i-ce: add Allwinner H616 support
@ 2024-06-16 22:07 Andre Przywara
  2024-06-16 22:07 ` [PATCH 1/4] dt-bindings: crypto: sun8i-ce: Add compatible for H616 Andre Przywara
                   ` (4 more replies)
  0 siblings, 5 replies; 14+ messages in thread
From: Andre Przywara @ 2024-06-16 22:07 UTC (permalink / raw)
  To: Corentin Labbe, Herbert Xu, David S . Miller, Chen-Yu Tsai,
	Jernej Skrabec, Samuel Holland, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley
  Cc: linux-crypto, linux-arm-kernel, linux-sunxi, devicetree

This series adds support for the crypto engine in the Allwinner H616
SoC. The IP and its capabilities are very similar to the H6, with the
major difference of the DMA engine supporting 34 bit wide addresses.
This is achieved by just shifting every address by 2 bits in the DMA
descriptors; Allwinner calls this "word addresses".
Patch 2/4 adds support for this by wrapping every address access in a
function that does the shift as needed. Patch 1/4 adds the new
compatible string to the binding, patch 3/4 adds that string to the
driver and enables the address shift for it. The final patch 4/4 adds
the DT node to the SoC .dtsi. Since this is an internal peripheral,
it's always enabled.

Corentin's cryptotest passed for me, though I haven't checked how fast
it is and if it really brings an advantage performance-wise, but maybe
people find it useful to offload that from the CPU cores.
One immediate advantage is the availability of the TRNG device, which
helps to feed the kernel's entropy pool much faster - typically before
we reach userland. Without the driver this sometimes takes minutes, and
delays workloads that rely on the entropy pool.

Please have a look and comment!

Cheers,
Andre

Andre Przywara (4):
  dt-bindings: crypto: sun8i-ce: Add compatible for H616
  crypto: sun8i-ce - wrap accesses to descriptor address fields
  crypto: sun8i-ce - add Allwinner H616 support
  arm64: dts: allwinner: h616: add crypto engine node

 .../bindings/crypto/allwinner,sun8i-ce.yaml   |  2 ++
 .../arm64/boot/dts/allwinner/sun50i-h616.dtsi | 10 +++++++
 .../allwinner/sun8i-ce/sun8i-ce-cipher.c      |  8 ++---
 .../crypto/allwinner/sun8i-ce/sun8i-ce-core.c | 29 ++++++++++++++++++-
 .../crypto/allwinner/sun8i-ce/sun8i-ce-hash.c |  6 ++--
 .../crypto/allwinner/sun8i-ce/sun8i-ce-prng.c |  6 ++--
 .../crypto/allwinner/sun8i-ce/sun8i-ce-trng.c |  2 +-
 drivers/crypto/allwinner/sun8i-ce/sun8i-ce.h  | 10 +++++++
 8 files changed, 61 insertions(+), 12 deletions(-)

-- 
2.39.4


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2024-06-24 16:34 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-16 22:07 [PATCH 0/4] crypto: sun8i-ce: add Allwinner H616 support Andre Przywara
2024-06-16 22:07 ` [PATCH 1/4] dt-bindings: crypto: sun8i-ce: Add compatible for H616 Andre Przywara
2024-06-17  6:51   ` Krzysztof Kozlowski
2024-06-21 14:37   ` Chen-Yu Tsai
2024-06-16 22:07 ` [PATCH 2/4] crypto: sun8i-ce - wrap accesses to descriptor address fields Andre Przywara
2024-06-18  7:39   ` kernel test robot
2024-06-24 16:34     ` Andre Przywara
2024-06-18 13:38   ` kernel test robot
2024-06-21 14:53   ` Chen-Yu Tsai
2024-06-24 16:32     ` Andre Przywara
2024-06-16 22:07 ` [PATCH 3/4] crypto: sun8i-ce - add Allwinner H616 support Andre Przywara
2024-06-21 14:45   ` Chen-Yu Tsai
2024-06-16 22:07 ` [PATCH 4/4] arm64: dts: allwinner: h616: add crypto engine node Andre Przywara
2024-06-22 23:37 ` [PATCH 0/4] crypto: sun8i-ce: add Allwinner H616 support Ryan Walklin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).