// SPDX-License-Identifier: GPL-2.0 /* * sun8i-ce-trng.c - hardware cryptographic offloader for * Allwinner H3/A64/H5/H2+/H6/R40 SoC * * Copyright (C) 2015-2020 Corentin Labbe <clabbe@baylibre.com> * * This file handle the TRNG * * You could find a link for the datasheet in Documentation/arch/arm/sunxi.rst
*/ #include"sun8i-ce.h" #include <linux/dma-mapping.h> #include <linux/pm_runtime.h> #include <linux/hw_random.h> /* * Note that according to the algorithm ID, 2 versions of the TRNG exists, * The first present in H3/H5/R40/A64 and the second present in H6. * This file adds support for both, but only the second is working * reliabily according to rngtest.
**/
/* recent CE (H6) need length in bytes, in word otherwise */ if (ce->variant->trng_t_dlen_in_bytes)
cet->t_dlen = cpu_to_le32(todo); else
cet->t_dlen = cpu_to_le32(todo / 4);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.