diff options
author | Christophe JAILLET <christophe.jaillet@wanadoo.fr> | 2022-12-03 00:13:36 +0300 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2022-12-04 16:37:08 +0300 |
commit | 3e6743e28b9b43d37ced234bdf8e19955d0216f8 (patch) | |
tree | dde437087b32f8b54df5261225b19f38f39658a3 /include | |
parent | 39ec9e6b141e5a9d7274f40531888f890385a013 (diff) | |
download | linux-3e6743e28b9b43d37ced234bdf8e19955d0216f8.tar.xz |
random: include <linux/once.h> in the right header
<linux/prandom.h> uses DO_ONCE(), so it should include <linux/once.h>
directly. In contrast, <linux/random.h> does not use code from
<linux/once.h>, so it should be removed.
Move the `#include <linux/once.h>` line into the right file.
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Fixes: c0842fbc1b18 ("random32: move the pseudo-random 32-bit definitions to prandom.h")
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/prandom.h | 1 | ||||
-rw-r--r-- | include/linux/random.h | 1 |
2 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/prandom.h b/include/linux/prandom.h index 1f4a0de7b019..c94c02ba065c 100644 --- a/include/linux/prandom.h +++ b/include/linux/prandom.h @@ -9,6 +9,7 @@ #define _LINUX_PRANDOM_H #include <linux/types.h> +#include <linux/once.h> #include <linux/percpu.h> #include <linux/random.h> diff --git a/include/linux/random.h b/include/linux/random.h index b1a34181eed6..4a2a1de423cd 100644 --- a/include/linux/random.h +++ b/include/linux/random.h @@ -6,7 +6,6 @@ #include <linux/bug.h> #include <linux/kernel.h> #include <linux/list.h> -#include <linux/once.h> #include <uapi/linux/random.h> |