]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
random: do not include <asm/archrandom.h> from random.h
authorJason A. Donenfeld <Jason@zx2c4.com>
Fri, 28 Oct 2022 23:42:02 +0000 (01:42 +0200)
committerJason A. Donenfeld <Jason@zx2c4.com>
Tue, 20 Dec 2022 02:13:45 +0000 (03:13 +0100)
The <asm/archrandom.h> header is a random.c private detail, not
something to be called by other code. As such, don't make it
automatically available by way of random.h.

Cc: Michael Ellerman <mpe@ellerman.id.au>
Acked-by: Heiko Carstens <hca@linux.ibm.com>
Reviewed-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
arch/powerpc/kernel/setup-common.c
arch/s390/kernel/setup.c
drivers/char/hw_random/powernv-rng.c
drivers/char/hw_random/s390-trng.c
drivers/char/random.c
include/linux/random.h

index 6d041993a45dccf868bccb2d7fca38d2583b15bc..9b10e57040c6c705f4b8ba0e17cd08d5e14b545e 100644 (file)
@@ -59,6 +59,7 @@
 #include <asm/xmon.h>
 #include <asm/cputhreads.h>
 #include <mm/mmu_decl.h>
+#include <asm/archrandom.h>
 #include <asm/fadump.h>
 #include <asm/udbg.h>
 #include <asm/hugetlb.h>
index 2094f575c5329470ac3fc57adee3136faa99f8cd..2b6091349daa2553c504a362ed1e7339aff8bd62 100644 (file)
@@ -52,6 +52,7 @@
 #include <linux/hugetlb.h>
 #include <linux/kmemleak.h>
 
+#include <asm/archrandom.h>
 #include <asm/boot_data.h>
 #include <asm/ipl.h>
 #include <asm/facility.h>
index 429e956f34e1c2b225e0e781a4434ab8ceb8d888..47b88de029f2deec8c84be3d6c5af3aa413f8dee 100644 (file)
@@ -11,6 +11,7 @@
 #include <linux/platform_device.h>
 #include <linux/random.h>
 #include <linux/hw_random.h>
+#include <asm/archrandom.h>
 
 static int powernv_rng_read(struct hwrng *rng, void *data, size_t max, bool wait)
 {
index cffa326ddc8d3b1738621c0bd8a24d08f1458016..d27e32e9bfee11d528248d0f1360c5154a369dca 100644 (file)
@@ -23,6 +23,7 @@
 #include <linux/sched/signal.h>
 #include <asm/debug.h>
 #include <asm/cpacf.h>
+#include <asm/archrandom.h>
 
 MODULE_LICENSE("GPL v2");
 MODULE_AUTHOR("IBM Corporation");
index 5885ed574c6aae34cad8d428909d82b803fe15c8..ce3ccd172cc868d9f89ea2c5489a600ea08e2a0d 100644 (file)
@@ -56,6 +56,7 @@
 #include <linux/sched/isolation.h>
 #include <crypto/chacha.h>
 #include <crypto/blake2s.h>
+#include <asm/archrandom.h>
 #include <asm/processor.h>
 #include <asm/irq.h>
 #include <asm/irq_regs.h>
index 4a2a1de423cd900d4ca12cf1d363ecf078ee5966..b0a940af4fff54e526d5305ff86966b2d1ce7039 100644 (file)
@@ -152,8 +152,6 @@ declare_get_random_var_wait(long, unsigned long)
  */
 #include <linux/prandom.h>
 
-#include <asm/archrandom.h>
-
 #ifdef CONFIG_SMP
 int random_prepare_cpu(unsigned int cpu);
 int random_online_cpu(unsigned int cpu);