Changeset View
Changeset View
Standalone View
Standalone View
head/sys/dev/random/ivy.c
Show First 20 Lines • Show All 54 Lines • ▼ Show 20 Lines | |||||
static u_int random_ivy_read(void *, u_int); | static u_int random_ivy_read(void *, u_int); | ||||
static struct random_source random_ivy = { | static struct random_source random_ivy = { | ||||
.rs_ident = "Intel Secure Key RNG", | .rs_ident = "Intel Secure Key RNG", | ||||
.rs_source = RANDOM_PURE_RDRAND, | .rs_source = RANDOM_PURE_RDRAND, | ||||
.rs_read = random_ivy_read | .rs_read = random_ivy_read | ||||
}; | }; | ||||
SYSCTL_NODE(_kern_random, OID_AUTO, rdrand, CTLFLAG_RW, 0, | SYSCTL_NODE(_kern_random, OID_AUTO, rdrand, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, | ||||
"rdrand (ivy) entropy source"); | "rdrand (ivy) entropy source"); | ||||
static bool acquire_independent_seed_samples = false; | static bool acquire_independent_seed_samples = false; | ||||
SYSCTL_BOOL(_kern_random_rdrand, OID_AUTO, rdrand_independent_seed, | SYSCTL_BOOL(_kern_random_rdrand, OID_AUTO, rdrand_independent_seed, | ||||
CTLFLAG_RWTUN, &acquire_independent_seed_samples, 0, | CTLFLAG_RWTUN, &acquire_independent_seed_samples, 0, | ||||
"If non-zero, use more expensive and slow, but safer, seeded samples " | "If non-zero, use more expensive and slow, but safer, seeded samples " | ||||
"where RDSEED is not present."); | "where RDSEED is not present."); | ||||
static bool | static bool | ||||
▲ Show 20 Lines • Show All 128 Lines • Show Last 20 Lines |