Lines Matching refs:entropy
507 type entropy[CHACHA_BLOCK_SIZE * 3 / (2 * sizeof(type))]; \
536 if (batch->position >= ARRAY_SIZE(batch->entropy) || \
538 _get_random_bytes(batch->entropy, sizeof(batch->entropy)); \
543 ret = batch->entropy[batch->position]; \
544 batch->entropy[batch->position] = 0; \
836 unsigned long flags, entropy = random_get_entropy(); in random_pm_notification() local
847 _mix_pool_bytes(&entropy, sizeof(entropy)); in random_pm_notification()
867 unsigned long entropy[BLAKE2S_BLOCK_SIZE / sizeof(long)]; in random_init_early() local
875 for (i = 0, arch_bits = sizeof(entropy) * 8; i < ARRAY_SIZE(entropy);) { in random_init_early()
876 longs = arch_get_random_seed_longs(entropy, ARRAY_SIZE(entropy) - i); in random_init_early()
878 _mix_pool_bytes(entropy, sizeof(*entropy) * longs); in random_init_early()
882 longs = arch_get_random_longs(entropy, ARRAY_SIZE(entropy) - i); in random_init_early()
884 _mix_pool_bytes(entropy, sizeof(*entropy) * longs); in random_init_early()
888 arch_bits -= sizeof(*entropy) * 8; in random_init_early()
908 unsigned long entropy = random_get_entropy(); in random_init() local
912 _mix_pool_bytes(&entropy, sizeof(entropy)); in random_init()
929 WARN(!entropy, "Missing cycle counter and fallback timer; RNG " in random_init()
943 unsigned long entropy = random_get_entropy(); in add_device_randomness() local
947 _mix_pool_bytes(&entropy, sizeof(entropy)); in add_device_randomness()
958 void add_hwgenerator_randomness(const void *buf, size_t len, size_t entropy, bool sleep_after) in add_hwgenerator_randomness() argument
961 credit_init_bits(entropy); in add_hwgenerator_randomness()
967 if (sleep_after && !kthread_should_stop() && (crng_ready() || !entropy)) in add_hwgenerator_randomness()
1115 unsigned long entropy = random_get_entropy(); in add_interrupt_randomness() local
1120 fast_mix(fast_pool->pool, entropy, in add_interrupt_randomness()
1153 unsigned long entropy = random_get_entropy(), now = jiffies, flags; in add_timer_randomness() local
1162 fast_mix(this_cpu_ptr(&irq_randomness)->pool, entropy, num); in add_timer_randomness()
1165 _mix_pool_bytes(&entropy, sizeof(entropy)); in add_timer_randomness()
1259 unsigned long entropy; member
1279 unsigned long entropy = random_get_entropy(); in entropy_timer() local
1281 mix_pool_bytes(&entropy, sizeof(entropy)); in entropy_timer()
1300 stack->entropy = random_get_entropy(); in try_to_generate_entropy()
1301 if (stack->entropy != last) in try_to_generate_entropy()
1303 last = stack->entropy; in try_to_generate_entropy()
1349 mix_pool_bytes(&stack->entropy, sizeof(stack->entropy)); in try_to_generate_entropy()
1351 stack->entropy = random_get_entropy(); in try_to_generate_entropy()
1353 mix_pool_bytes(&stack->entropy, sizeof(stack->entropy)); in try_to_generate_entropy()