From mboxrd@z Thu Jan 1 00:00:00 1970 From: Randy Dunlap Subject: Re: [PATCH v28 07/12] LRNG - add kernel crypto API PRNG extension Date: Wed, 15 Jan 2020 16:15:46 -0800 Message-ID: References: <6157374.ptSnyUpaCn@positron.chronox.de> <2641155.iNH938UiKq@positron.chronox.de> <5951792.lmNsirYsPE@positron.chronox.de> <526421170.FD02tCEzJt@positron.chronox.de> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: In-Reply-To: <526421170.FD02tCEzJt@positron.chronox.de> Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org To: =?UTF-8?Q?Stephan_M=c3=bcller?= , Arnd Bergmann Cc: Greg Kroah-Hartman , linux-crypto@vger.kernel.org, LKML , linux-api@vger.kernel.org, "Eric W. Biederman" , "Alexander E. Patrakov" , "Ahmed S. Darwish" , "Theodore Y. Ts'o" , Willy Tarreau , Matthew Garrett , Vito Caputo , Andreas Dilger , Jan Kara , Ray Strode , William Jon McCann , zhangjs , Andy Lutomirski , Florian Weimer , Lennart Poettering , Nicolai Stange , "Peter, Matthias" List-Id: linux-api@vger.kernel.org On 1/15/20 2:34 AM, Stephan Müller wrote: > > CC: "Eric W. Biederman" > CC: "Alexander E. Patrakov" > CC: "Ahmed S. Darwish" > CC: "Theodore Y. Ts'o" > CC: Willy Tarreau > CC: Matthew Garrett > CC: Vito Caputo > CC: Andreas Dilger > CC: Jan Kara > CC: Ray Strode > CC: William Jon McCann > CC: zhangjs > CC: Andy Lutomirski > CC: Florian Weimer > CC: Lennart Poettering > CC: Nicolai Stange > Reviewed-by: Marcelo Henrique Cerri > Reviewed-by: Roman Drahtmueller > Tested-by: Roman Drahtmüller > Tested-by: Marcelo Henrique Cerri > Tested-by: Neil Horman > Signed-off-by: Stephan Mueller > --- > drivers/char/lrng/Kconfig | 10 + > drivers/char/lrng/Makefile | 1 + > drivers/char/lrng/lrng_kcapi.c | 327 +++++++++++++++++++++++++++++++++ > 3 files changed, 338 insertions(+) > create mode 100644 drivers/char/lrng/lrng_kcapi.c > > diff --git a/drivers/char/lrng/Kconfig b/drivers/char/lrng/Kconfig > index 15fb623d9d1f..0d070a3897dd 100644 > --- a/drivers/char/lrng/Kconfig > +++ b/drivers/char/lrng/Kconfig > @@ -80,6 +80,16 @@ config LRNG_DRBG > Enable the SP800-90A DRBG support for the LRNG. Once the > module is loaded, output from /dev/random, /dev/urandom, > getrandom(2), or get_random_bytes is provided by a DRBG. > + > +config LRNG_KCAPI > + tristate "Kernel Crypto API support for the LRNG" > + select CRYPTO_RNG Don't select CRYPTO_RNG unless you know that CRYPTO is set/enabled. > + help > + Enable the support for generic pseudo-random number > + generators offered by the kernel crypto API with the > + LRNG. Once the module is loaded, output from /dev/random, > + /dev/urandom, getrandom(2), or get_random_bytes is > + provided by the selected kernel crypto API RNG. > endif # LRNG_DRNG_SWITCH > > endif # LRNG -- ~Randy Reported-by: Randy Dunlap