[PATCH v5 0/4] arm64: marvell: add cryptographic engine support for 7k/8k
Antoine Tenart
antoine.tenart at free-electrons.com
Mon May 22 07:45:10 PDT 2017
Hi all,
This series adds support for the Inside Secure SafeXcel EIP197
cryptographic engine which can be found on Marvell Armada 7k and 8k
boards. A new cryptographic engine driver is added, as well as the
relevant device tree definition for the Armada 7040 DB and 8040 DB
boards.
This driver needs two firmwares to work correctly. These firmware are
usually used for more advanced operations than the ones supported (as of
now), but we still need them to pass the data to the internal
cryptographic engine.
This series was tested in various ways on both the Armada 7040 DB and
the Armada 8040 DB: using the crypto framework self tests, using tcrypt
and while performing various transfers with iperf on top of IPsec.
This series is based on top of v4.12-rc1, and is available at:
https://github.com/atenart/linux v4.12-rc1/7k8k-crypto
I can rebase if needed. Patches adding device tree nodes and modifying
the arm64 defconfig have been applied to the mvebu tree already.
I'd like to thank Ofer Heifetz and Igal Liberman who helped me to do
this driver by adding functionalities, optimizing functions and testing
(a lot).
Thanks,
Antoine
Since v4:
- Added a dma-mask property and updated the default DMA mask to 64.
- Replaced all <asm/dma-mapping.h> to <linux/dma-mapping.h>.
- Rebased on top of 4.12-rc1.
Since v3:
- Updated to use the skcipher API instead of the ablkcipher one.
- Added explicit zeroing of the keys.
- Fixed the DMA mask.
- Removed a few remaining phys_addr_t.
Since v2:
- Used sha*_zero_message_hash definitions instead of custom ones.
- Used memzero_explicit() instead of memset() to avoid leaks.
- Misc cosmetic updates.
Since v1:
- Fixed two compilation issues reported by Kbuild.
- Removed all dma_to_phys() calls and used the dma addresses instead.
- Added a call to dma_set_mask_and_coherent() before calling any DMA
API helper.
- Removed some DMA free functions to avoid double-freeing.
- Do not rely on sg_nents_for_len() to get the number of sg anymore.
- Added a dedicated kmalloc'ed cache to use for dma_map_single().
Antoine Tenart (4):
Documentation/bindings: Document the SafeXel cryptographic engine
driver
crypto: inside-secure: add SafeXcel EIP197 crypto engine driver
MAINTAINERS: add a maintainer for the Inside Secure crypto driver
arm64: marvell: dts: add dma-mask in crypto nodes for 7k/8k
.../bindings/crypto/inside-secure-safexcel.txt | 29 +
MAINTAINERS | 6 +
.../boot/dts/marvell/armada-cp110-master.dtsi | 1 +
.../arm64/boot/dts/marvell/armada-cp110-slave.dtsi | 1 +
drivers/crypto/Kconfig | 17 +
drivers/crypto/Makefile | 1 +
drivers/crypto/inside-secure/Makefile | 2 +
drivers/crypto/inside-secure/safexcel.c | 930 +++++++++++++++++
drivers/crypto/inside-secure/safexcel.h | 572 +++++++++++
drivers/crypto/inside-secure/safexcel_cipher.c | 556 +++++++++++
drivers/crypto/inside-secure/safexcel_hash.c | 1045 ++++++++++++++++++++
drivers/crypto/inside-secure/safexcel_ring.c | 157 +++
12 files changed, 3317 insertions(+)
create mode 100644 Documentation/devicetree/bindings/crypto/inside-secure-safexcel.txt
create mode 100644 drivers/crypto/inside-secure/Makefile
create mode 100644 drivers/crypto/inside-secure/safexcel.c
create mode 100644 drivers/crypto/inside-secure/safexcel.h
create mode 100644 drivers/crypto/inside-secure/safexcel_cipher.c
create mode 100644 drivers/crypto/inside-secure/safexcel_hash.c
create mode 100644 drivers/crypto/inside-secure/safexcel_ring.c
--
2.9.4
More information about the linux-arm-kernel
mailing list