aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/random
diff options
context:
space:
mode:
authorConrad Meyer <cem@FreeBSD.org>2019-11-22 20:24:15 +0000
committerConrad Meyer <cem@FreeBSD.org>2019-11-22 20:24:15 +0000
commitb6db1cc7100350790201bfa550ec47d9a5fbe781 (patch)
tree438e760496a847c3c5d9fd40d0e368570413cb9a /sys/dev/random
parent02d4535d2d09bb2efcfc751f7a051816dd590adb (diff)
Notes
Diffstat (limited to 'sys/dev/random')
-rw-r--r--sys/dev/random/random_harvestq.c8
-rw-r--r--sys/dev/random/random_infra.c2
-rw-r--r--sys/dev/random/randomdev.h8
3 files changed, 8 insertions, 10 deletions
diff --git a/sys/dev/random/random_harvestq.c b/sys/dev/random/random_harvestq.c
index f8a2cbcc0649..0a02694f4132 100644
--- a/sys/dev/random/random_harvestq.c
+++ b/sys/dev/random/random_harvestq.c
@@ -98,6 +98,14 @@ volatile int random_kthread_control;
*/
__read_frequently u_int hc_source_mask;
+struct random_sources {
+ LIST_ENTRY(random_sources) rrs_entries;
+ struct random_source *rrs_source;
+};
+
+static LIST_HEAD(sources_head, random_sources) source_list =
+ LIST_HEAD_INITIALIZER(source_list);
+
SYSCTL_NODE(_kern_random, OID_AUTO, harvest, CTLFLAG_RW, 0,
"Entropy Device Parameters");
diff --git a/sys/dev/random/random_infra.c b/sys/dev/random/random_infra.c
index dd64741a3ea6..a6090b54c454 100644
--- a/sys/dev/random/random_infra.c
+++ b/sys/dev/random/random_infra.c
@@ -101,8 +101,6 @@ SYSCTL_BOOL(_kern_random_initial_seeding, OID_AUTO,
MALLOC_DEFINE(M_ENTROPY, "entropy", "Entropy harvesting buffers and data structures");
-struct sources_head source_list = LIST_HEAD_INITIALIZER(source_list);
-
#if defined(RANDOM_LOADABLE)
struct random_algorithm *p_random_alg_context = NULL;
#else /* !defined(RANDOM_LOADABLE) */
diff --git a/sys/dev/random/randomdev.h b/sys/dev/random/randomdev.h
index abed568fb215..896b31a5fea2 100644
--- a/sys/dev/random/randomdev.h
+++ b/sys/dev/random/randomdev.h
@@ -102,14 +102,6 @@ struct random_source {
random_source_read_t *rs_read;
};
-struct random_sources {
- LIST_ENTRY(random_sources) rrs_entries;
- struct random_source *rrs_source;
-};
-
-LIST_HEAD(sources_head, random_sources);
-extern struct sources_head source_list;
-
void random_source_register(struct random_source *);
void random_source_deregister(struct random_source *);