xref: /linux/drivers/char/hw_random/Kconfig (revision d8920a722a8cec625267c09ed40af8fd433d7f9a)
1# SPDX-License-Identifier: GPL-2.0-only
2#
3# Hardware Random Number Generator (RNG) configuration
4#
5
6menuconfig HW_RANDOM
7	tristate "Hardware Random Number Generator Core support"
8	default m
9	help
10	  Hardware Random Number Generator Core infrastructure.
11
12	  To compile this driver as a module, choose M here: the
13	  module will be called rng-core.  This provides a device
14	  that's usually called /dev/hwrng, and which exposes one
15	  of possibly several hardware random number generators.
16
17	  These hardware random number generators do feed into the
18	  kernel's random number generator entropy pool.
19
20	  If unsure, say Y.
21
22if HW_RANDOM
23
24config HW_RANDOM_TIMERIOMEM
25	tristate "Timer IOMEM HW Random Number Generator support"
26	depends on HAS_IOMEM
27	help
28	  This driver provides kernel-side support for a generic Random
29	  Number Generator used by reading a 'dumb' iomem address that
30	  is to be read no faster than, for example, once a second;
31	  the default FPGA bitstream on the TS-7800 has such functionality.
32
33	  To compile this driver as a module, choose M here: the
34	  module will be called timeriomem-rng.
35
36	  If unsure, say Y.
37
38config HW_RANDOM_INTEL
39	tristate "Intel HW Random Number Generator support"
40	depends on (X86 || COMPILE_TEST) && PCI
41	default HW_RANDOM
42	help
43	  This driver provides kernel-side support for the Random Number
44	  Generator hardware found on Intel i8xx-based motherboards.
45
46	  To compile this driver as a module, choose M here: the
47	  module will be called intel-rng.
48
49	  If unsure, say Y.
50
51config HW_RANDOM_AMD
52	tristate "AMD HW Random Number Generator support"
53	depends on (X86 || PPC_MAPLE || COMPILE_TEST)
54	depends on PCI && HAS_IOPORT_MAP
55	default HW_RANDOM
56	help
57	  This driver provides kernel-side support for the Random Number
58	  Generator hardware found on AMD 76x-based motherboards.
59
60	  To compile this driver as a module, choose M here: the
61	  module will be called amd-rng.
62
63	  If unsure, say Y.
64
65config HW_RANDOM_AIROHA
66	tristate "Airoha True HW Random Number Generator support"
67	depends on ARCH_AIROHA || COMPILE_TEST
68	default HW_RANDOM
69	help
70	  This driver provides kernel-side support for the True Random Number
71	  Generator hardware found on Airoha SoC.
72
73	  To compile this driver as a module, choose M here: the
74	  module will be called airoha-rng.
75
76	  If unsure, say Y.
77
78config HW_RANDOM_ATMEL
79	tristate "Atmel Random Number Generator support"
80	depends on (ARCH_AT91 || COMPILE_TEST)
81	default HW_RANDOM
82	help
83	  This driver provides kernel-side support for the Random Number
84	  Generator hardware found on Atmel AT91 devices.
85
86	  To compile this driver as a module, choose M here: the
87	  module will be called atmel-rng.
88
89	  If unsure, say Y.
90
91config HW_RANDOM_BA431
92	tristate "Silex Insight BA431 Random Number Generator support"
93	depends on HAS_IOMEM
94	help
95	  This driver provides kernel-side support for the Random Number
96	  Generator hardware based on Silex Insight BA431 IP.
97
98	  To compile this driver as a module, choose M here: the
99	  module will be called ba431-rng.
100
101config HW_RANDOM_BCM2835
102	tristate "Broadcom BCM2835/BCM63xx Random Number Generator support"
103	depends on ARCH_BCM2835 || ARCH_BCM_NSP || ARCH_BCM_5301X || \
104		   ARCH_BCMBCA || BCM63XX || BMIPS_GENERIC || COMPILE_TEST
105	default HW_RANDOM
106	help
107	  This driver provides kernel-side support for the Random Number
108	  Generator hardware found on the Broadcom BCM2835 and BCM63xx SoCs.
109
110	  To compile this driver as a module, choose M here: the
111	  module will be called bcm2835-rng
112
113	  If unsure, say Y.
114
115config HW_RANDOM_IPROC_RNG200
116	tristate "Broadcom iProc/STB RNG200 support"
117	depends on ARCH_BCM_IPROC || ARCH_BCM2835 || ARCH_BCMBCA || ARCH_BRCMSTB || COMPILE_TEST
118	default HW_RANDOM
119	help
120	  This driver provides kernel-side support for the RNG200
121	  hardware found on the Broadcom iProc and STB SoCs.
122
123	  To compile this driver as a module, choose M here: the
124	  module will be called iproc-rng200
125
126	  If unsure, say Y.
127
128config HW_RANDOM_GEODE
129	tristate "AMD Geode HW Random Number Generator support"
130	depends on (X86_32 || COMPILE_TEST)
131	depends on PCI
132	default HW_RANDOM
133	help
134	  This driver provides kernel-side support for the Random Number
135	  Generator hardware found on the AMD Geode LX.
136
137	  To compile this driver as a module, choose M here: the
138	  module will be called geode-rng.
139
140	  If unsure, say Y.
141
142config HW_RANDOM_N2RNG
143	tristate "Niagara2 Random Number Generator support"
144	depends on SPARC64
145	default HW_RANDOM
146	help
147	  This driver provides kernel-side support for the Random Number
148	  Generator hardware found on Niagara2 cpus.
149
150	  To compile this driver as a module, choose M here: the
151	  module will be called n2-rng.
152
153	  If unsure, say Y.
154
155config HW_RANDOM_VIA
156	tristate "VIA HW Random Number Generator support"
157	depends on X86
158	default HW_RANDOM
159	help
160	  This driver provides kernel-side support for the Random Number
161	  Generator hardware found on VIA based motherboards.
162
163	  To compile this driver as a module, choose M here: the
164	  module will be called via-rng.
165
166	  If unsure, say Y.
167
168config HW_RANDOM_IXP4XX
169	tristate "Intel IXP4xx NPU HW Pseudo-Random Number Generator support"
170	depends on ARCH_IXP4XX || COMPILE_TEST
171	default HW_RANDOM
172	help
173	  This driver provides kernel-side support for the Pseudo-Random
174	  Number Generator hardware found on the Intel IXP45x/46x NPU.
175
176	  To compile this driver as a module, choose M here: the
177	  module will be called ixp4xx-rng.
178
179	  If unsure, say Y.
180
181config HW_RANDOM_OMAP
182	tristate "OMAP Random Number Generator support"
183	depends on ARCH_OMAP16XX || ARCH_OMAP2PLUS || ARCH_MVEBU || ARCH_K3 || COMPILE_TEST
184	default HW_RANDOM
185	help
186	  This driver provides kernel-side support for the Random Number
187	  Generator hardware found on OMAP16xx, OMAP2/3/4/5, AM33xx/AM43xx
188	  multimedia processors, and Marvell Armada 7k/8k SoCs.
189
190	  To compile this driver as a module, choose M here: the
191	  module will be called omap-rng.
192
193	  If unsure, say Y.
194
195config HW_RANDOM_OMAP3_ROM
196	tristate "OMAP3 ROM Random Number Generator support"
197	depends on ARCH_OMAP3 || COMPILE_TEST
198	default HW_RANDOM
199	help
200	  This driver provides kernel-side support for the Random Number
201	  Generator hardware found on OMAP34xx processors.
202
203	  To compile this driver as a module, choose M here: the
204	  module will be called omap3-rom-rng.
205
206	  If unsure, say Y.
207
208config HW_RANDOM_OCTEON
209	tristate "Octeon Random Number Generator support"
210	depends on CAVIUM_OCTEON_SOC
211	default HW_RANDOM
212	help
213	  This driver provides kernel-side support for the Random Number
214	  Generator hardware found on Octeon processors.
215
216	  To compile this driver as a module, choose M here: the
217	  module will be called octeon-rng.
218
219	  If unsure, say Y.
220
221config HW_RANDOM_PASEMI
222	tristate "PA Semi HW Random Number Generator support"
223	depends on PPC_PASEMI || (PPC && COMPILE_TEST)
224	default HW_RANDOM
225	help
226	  This driver provides kernel-side support for the Random Number
227	  Generator hardware found on PA Semi PWRficient SoCs.
228
229	  To compile this driver as a module, choose M here: the
230	  module will be called pasemi-rng.
231
232	  If unsure, say Y.
233
234config HW_RANDOM_VIRTIO
235	tristate "VirtIO Random Number Generator support"
236	depends on VIRTIO
237	help
238	  This driver provides kernel-side support for the virtual Random Number
239	  Generator hardware.
240
241	  To compile this driver as a module, choose M here: the
242	  module will be called virtio-rng.  If unsure, say N.
243
244config HW_RANDOM_MXC_RNGA
245	tristate "Freescale i.MX RNGA Random Number Generator"
246	depends on SOC_IMX31 || COMPILE_TEST
247	default HW_RANDOM
248	help
249	  This driver provides kernel-side support for the Random Number
250	  Generator hardware found on Freescale i.MX processors.
251
252	  To compile this driver as a module, choose M here: the
253	  module will be called mxc-rnga.
254
255	  If unsure, say Y.
256
257config HW_RANDOM_IMX_RNGC
258	tristate "Freescale i.MX RNGC Random Number Generator"
259	depends on HAS_IOMEM
260	depends on SOC_IMX25 || SOC_IMX6SL || SOC_IMX6SLL || SOC_IMX6UL || COMPILE_TEST
261	default HW_RANDOM
262	help
263	  This driver provides kernel-side support for the Random Number
264	  Generator Version C hardware found on some Freescale i.MX
265	  processors. Version B is also supported by this driver.
266
267	  To compile this driver as a module, choose M here: the
268	  module will be called imx-rngc.
269
270	  If unsure, say Y.
271
272config HW_RANDOM_INGENIC_RNG
273	tristate "Ingenic Random Number Generator support"
274	depends on MACH_JZ4780 || MACH_X1000 || COMPILE_TEST
275	default HW_RANDOM
276	help
277	  This driver provides kernel-side support for the Random Number Generator
278	  hardware found in ingenic JZ4780 and X1000 SoC. MIPS Creator CI20 uses
279	  JZ4780 SoC, YSH & ATIL CU1000-Neo uses X1000 SoC.
280
281	  To compile this driver as a module, choose M here: the
282	  module will be called ingenic-rng.
283
284	  If unsure, say Y.
285
286config HW_RANDOM_INGENIC_TRNG
287	tristate "Ingenic True Random Number Generator support"
288	depends on MACH_X1830 || COMPILE_TEST
289	default HW_RANDOM
290	help
291	  This driver provides kernel-side support for the True Random Number Generator
292	  hardware found in ingenic X1830 SoC. YSH & ATIL CU1830-Neo uses X1830 SoC.
293
294	  To compile this driver as a module, choose M here: the
295	  module will be called ingenic-trng.
296
297	  If unsure, say Y.
298
299config HW_RANDOM_NOMADIK
300	tristate "ST-Ericsson Nomadik Random Number Generator support"
301	depends on ARCH_NOMADIK || COMPILE_TEST
302	default HW_RANDOM
303	help
304	  This driver provides kernel-side support for the Random Number
305	  Generator hardware found on ST-Ericsson SoCs (8815 and 8500).
306
307	  To compile this driver as a module, choose M here: the
308	  module will be called nomadik-rng.
309
310	  If unsure, say Y.
311
312config HW_RANDOM_PSERIES
313	tristate "pSeries HW Random Number Generator support"
314	depends on PPC64 && IBMVIO
315	default HW_RANDOM
316	help
317	  This driver provides kernel-side support for the Random Number
318	  Generator hardware found on POWER7+ machines and above
319
320	  To compile this driver as a module, choose M here: the
321	  module will be called pseries-rng.
322
323	  If unsure, say Y.
324
325config HW_RANDOM_POWERNV
326	tristate "PowerNV Random Number Generator support"
327	depends on PPC_POWERNV
328	default HW_RANDOM
329	help
330	  This is the driver for Random Number Generator hardware found
331	  in POWER7+ and above machines for PowerNV platform.
332
333	  To compile this driver as a module, choose M here: the
334	  module will be called powernv-rng.
335
336	  If unsure, say Y.
337
338config HW_RANDOM_HISI
339	tristate "Hisilicon Random Number Generator support"
340	depends on ARCH_HISI || COMPILE_TEST
341	default HW_RANDOM
342	help
343	  This driver provides kernel-side support for the Random Number
344	  Generator hardware found on Hisilicon Hip04 and Hip05 SoC.
345
346	  To compile this driver as a module, choose M here: the
347	  module will be called hisi-rng.
348
349	  If unsure, say Y.
350
351config HW_RANDOM_HISTB
352	tristate "Hisilicon STB Random Number Generator support"
353	depends on ARCH_HISI || COMPILE_TEST
354	default ARCH_HISI
355	help
356	  This driver provides kernel-side support for the Random Number
357	  Generator hardware found on Hisilicon Hi37xx SoC.
358
359	  To compile this driver as a module, choose M here: the
360	  module will be called histb-rng.
361
362config HW_RANDOM_ST
363	tristate "ST Microelectronics HW Random Number Generator support"
364	depends on ARCH_STI || COMPILE_TEST
365	help
366	  This driver provides kernel-side support for the Random Number
367	  Generator hardware found on STi series of SoCs.
368
369	  To compile this driver as a module, choose M here: the
370	  module will be called st-rng.
371
372config HW_RANDOM_XGENE
373	tristate "APM X-Gene True Random Number Generator (TRNG) support"
374	depends on ARCH_XGENE || COMPILE_TEST
375	default HW_RANDOM
376	help
377	  This driver provides kernel-side support for the Random Number
378	  Generator hardware found on APM X-Gene SoC.
379
380	  To compile this driver as a module, choose M here: the
381	  module will be called xgene_rng.
382
383	  If unsure, say Y.
384
385config HW_RANDOM_STM32
386	tristate "STMicroelectronics STM32 random number generator"
387	depends on ARCH_STM32 || COMPILE_TEST
388	depends on HAS_IOMEM
389	default HW_RANDOM
390	help
391	  This driver provides kernel-side support for the Random Number
392	  Generator hardware found on STM32 microcontrollers.
393
394	  To compile this driver as a module, choose M here: the
395	  module will be called stm32-rng.
396
397	  If unsure, say N.
398
399config HW_RANDOM_PIC32
400	tristate "Microchip PIC32 Random Number Generator support"
401	depends on MACH_PIC32 || COMPILE_TEST
402	default HW_RANDOM if MACH_PIC32
403	help
404	  This driver provides kernel-side support for the Random Number
405	  Generator hardware found on a PIC32.
406
407	  To compile this driver as a module, choose M here. the
408	  module will be called pic32-rng.
409
410	  If unsure, say Y.
411
412config HW_RANDOM_POLARFIRE_SOC
413	tristate "Microchip PolarFire SoC Random Number Generator support"
414	depends on HW_RANDOM && POLARFIRE_SOC_SYS_CTRL
415	help
416	  This driver provides kernel-side support for the Random Number
417	  Generator hardware found on PolarFire SoC (MPFS).
418
419	  To compile this driver as a module, choose M here. The
420	  module will be called mfps_rng.
421
422	  If unsure, say N.
423
424
425config HW_RANDOM_MESON
426	tristate "Amlogic Meson Random Number Generator support"
427	depends on ARCH_MESON || COMPILE_TEST
428	depends on HAS_IOMEM && OF
429	default HW_RANDOM if ARCH_MESON
430	help
431	  This driver provides kernel-side support for the Random Number
432	  Generator hardware found on Amlogic Meson SoCs.
433
434	  To compile this driver as a module, choose M here. the
435	  module will be called meson-rng.
436
437	  If unsure, say Y.
438
439config HW_RANDOM_CAVIUM
440	tristate "Cavium ThunderX Random Number Generator support"
441	depends on PCI
442	depends on ARCH_THUNDER || (ARM64 && COMPILE_TEST)
443	default HW_RANDOM
444	help
445	  This driver provides kernel-side support for the Random Number
446	  Generator hardware found on Cavium SoCs.
447
448	  To compile this driver as a module, choose M here: the
449	  module will be called cavium_rng.
450
451	  If unsure, say Y.
452
453config HW_RANDOM_MTK
454	tristate "Mediatek Random Number Generator support"
455	depends on ARCH_MEDIATEK || COMPILE_TEST
456	depends on HAS_IOMEM && OF
457	default HW_RANDOM if ARCH_MEDIATEK
458	help
459	  This driver provides kernel-side support for the Random Number
460	  Generator hardware found on Mediatek SoCs.
461
462	  To compile this driver as a module, choose M here. the
463	  module will be called mtk-rng.
464
465	  If unsure, say Y.
466
467config HW_RANDOM_S390
468	tristate "S390 True Random Number Generator support"
469	depends on S390
470	default HW_RANDOM
471	help
472	  This driver provides kernel-side support for the True
473	  Random Number Generator available as CPACF extension
474	  on modern s390 hardware platforms.
475
476	  To compile this driver as a module, choose M here: the
477	  module will be called s390-trng.
478
479	  If unsure, say Y.
480
481config HW_RANDOM_EXYNOS
482	tristate "Samsung Exynos True Random Number Generator support"
483	depends on ARCH_EXYNOS || COMPILE_TEST
484	depends on HAS_IOMEM
485	default HW_RANDOM if ARCH_EXYNOS
486	help
487	  This driver provides support for the True Random Number
488	  Generator available in Exynos SoCs.
489
490	  To compile this driver as a module, choose M here: the module
491	  will be called exynos-trng.
492
493	  If unsure, say Y.
494
495config HW_RANDOM_OPTEE
496	tristate "OP-TEE based Random Number Generator support"
497	depends on OPTEE
498	default HW_RANDOM
499	help
500	  This  driver provides support for OP-TEE based Random Number
501	  Generator on ARM SoCs where hardware entropy sources are not
502	  accessible to normal world (Linux).
503
504	  To compile this driver as a module, choose M here: the module
505	  will be called optee-rng.
506
507	  If unsure, say Y.
508
509config HW_RANDOM_NPCM
510	tristate "NPCM Random Number Generator support"
511	depends on ARCH_NPCM || COMPILE_TEST
512	depends on HAS_IOMEM
513	default HW_RANDOM if ARCH_NPCM
514	help
515	  This driver provides support for the Random Number
516	  Generator hardware available in Nuvoton NPCM SoCs.
517
518	  To compile this driver as a module, choose M here: the
519	  module will be called npcm-rng.
520
521	  If unsure, say Y.
522
523config HW_RANDOM_KEYSTONE
524	depends on ARCH_KEYSTONE || COMPILE_TEST
525	depends on HAS_IOMEM && OF
526	default HW_RANDOM
527	tristate "TI Keystone NETCP SA Hardware random number generator"
528	help
529	  This option enables Keystone's hardware random generator.
530
531config HW_RANDOM_CCTRNG
532	tristate "Arm CryptoCell True Random Number Generator support"
533	depends on HAS_IOMEM && OF
534	help
535	  Say 'Y' to enable the True Random Number Generator driver for the
536	  Arm TrustZone CryptoCell family of processors.
537	  Currently the CryptoCell 713 and 703 are supported.
538	  The driver is supported only in SoC where Trusted Execution
539	  Environment is not used.
540	  Choose 'M' to compile this driver as a module. The module
541	  will be called cctrng.
542	  If unsure, say 'N'.
543
544config HW_RANDOM_XIPHERA
545	tristate "Xiphera FPGA based True Random Number Generator support"
546	depends on HAS_IOMEM
547	help
548	  This driver provides kernel-side support for Xiphera True Random
549	  Number Generator Intellectual Property Core.
550
551	  To compile this driver as a module, choose M here: the
552	  module will be called xiphera-trng.
553
554config HW_RANDOM_ARM_SMCCC_TRNG
555	tristate "Arm SMCCC TRNG firmware interface support"
556	depends on HAVE_ARM_SMCCC_DISCOVERY
557	default HW_RANDOM
558	help
559	  Say 'Y' to enable the True Random Number Generator driver using
560	  the Arm SMCCC TRNG firmware interface. This reads entropy from
561	  higher exception levels (firmware, hypervisor). Uses SMCCC for
562	  communicating with the firmware:
563	  https://developer.arm.com/documentation/den0098/latest/
564
565	  To compile this driver as a module, choose M here: the
566	  module will be called arm_smccc_trng.
567
568config HW_RANDOM_CN10K
569       tristate "Marvell CN10K Random Number Generator support"
570       depends on HW_RANDOM && PCI && (ARM64 || (64BIT && COMPILE_TEST))
571       default HW_RANDOM if ARCH_THUNDER
572       help
573	 This driver provides support for the True Random Number
574	 generator available in Marvell CN10K SoCs.
575
576	 To compile this driver as a module, choose M here.
577	 The module will be called cn10k_rng. If unsure, say Y.
578
579config HW_RANDOM_JH7110
580	tristate "StarFive JH7110 Random Number Generator support"
581	depends on SOC_STARFIVE || COMPILE_TEST
582	help
583	  This driver provides support for the True Random Number
584	  Generator in StarFive JH7110 SoCs.
585
586	  To compile this driver as a module, choose M here.
587	  The module will be called jh7110-trng.
588
589config HW_RANDOM_ROCKCHIP
590	tristate "Rockchip True Random Number Generator"
591	depends on HW_RANDOM && (ARCH_ROCKCHIP || COMPILE_TEST)
592	depends on HAS_IOMEM
593	default HW_RANDOM
594	help
595	  This driver provides kernel-side support for the True Random Number
596	  Generator hardware found on some Rockchip SoC like RK3566 or RK3568.
597
598	  To compile this driver as a module, choose M here: the
599	  module will be called rockchip-rng.
600
601	  If unsure, say Y.
602
603endif # HW_RANDOM
604
605config UML_RANDOM
606	depends on UML
607	select HW_RANDOM
608	tristate "UML Random Number Generator support"
609	help
610	  This option enables UML's "hardware" random number generator.  It
611	  attaches itself to the host's /dev/random, supplying as much entropy
612	  as the host has, rather than the small amount the UML gets from its
613	  own drivers. It registers itself as a rng-core driver thus providing
614	  a device which is usually called /dev/hwrng. This hardware random
615	  number generator does feed into the kernel's random number generator
616	  entropy pool.
617
618	  If unsure, say Y.
619