summaryrefslogtreecommitdiffstats
path: root/sys/dev/random/ivy.c
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2015-07-04 21:50:39 +0000
committerdim <dim@FreeBSD.org>2015-07-04 21:50:39 +0000
commit6f44bd3256388beb23fd03fdf43ad5d53cf43e29 (patch)
tree37590f5c697f4198fdddec33c58aefdef0a5f485 /sys/dev/random/ivy.c
parentcea4c167517a0678c7dbf92a0324088dcbac1035 (diff)
parent76b8ff88e56f9ad0639b7e23dd9d1128a0750026 (diff)
downloadFreeBSD-src-6f44bd3256388beb23fd03fdf43ad5d53cf43e29.zip
FreeBSD-src-6f44bd3256388beb23fd03fdf43ad5d53cf43e29.tar.gz
Merge ^/head r284737 through r285152.
Diffstat (limited to 'sys/dev/random/ivy.c')
-rw-r--r--sys/dev/random/ivy.c17
1 files changed, 7 insertions, 10 deletions
diff --git a/sys/dev/random/ivy.c b/sys/dev/random/ivy.c
index 71a61f4..a7cd32f 100644
--- a/sys/dev/random/ivy.c
+++ b/sys/dev/random/ivy.c
@@ -46,18 +46,15 @@ __FBSDID("$FreeBSD$");
#include <machine/specialreg.h>
#include <dev/random/randomdev.h>
-#include <dev/random/randomdev_soft.h>
-#include <dev/random/random_adaptors.h>
-#include <dev/random/live_entropy_sources.h>
#define RETRY_COUNT 10
static u_int random_ivy_read(void *, u_int);
-static struct live_entropy_source random_ivy = {
- .les_ident = "Intel Secure Key RNG",
- .les_source = RANDOM_PURE_RDRAND,
- .les_read = random_ivy_read
+static struct random_source random_ivy = {
+ .rs_ident = "Intel Secure Key RNG",
+ .rs_source = RANDOM_PURE_RDRAND,
+ .rs_read = random_ivy_read
};
static inline int
@@ -108,14 +105,14 @@ rdrand_modevent(module_t mod, int type, void *unused)
switch (type) {
case MOD_LOAD:
if (cpu_feature2 & CPUID2_RDRAND) {
- live_entropy_source_register(&random_ivy);
- printf("random: live provider: \"%s\"\n", random_ivy.les_ident);
+ random_source_register(&random_ivy);
+ printf("random: fast provider: \"%s\"\n", random_ivy.rs_ident);
}
break;
case MOD_UNLOAD:
if (cpu_feature2 & CPUID2_RDRAND)
- live_entropy_source_deregister(&random_ivy);
+ random_source_deregister(&random_ivy);
break;
case MOD_SHUTDOWN:
OpenPOWER on IntegriCloud