kernels/linux-2.4.0/drivers/char/i810_rng.c
/*
 * rng_timer_ticker - executes every rng_timer_len jiffies,
 *		      adds a single byte to system entropy
 *		      and internal FIPS test pools
 */
executes every rng_timer_len jiffies,
adds a single byte to system entropy
and internal FIPS test pools
executes every rng_timer_len jiffies adds a single byte to system entropy and internal FIPS test pools
static void rng_timer_tick (unsigned long data)
{
	int rng_data;
	spin_lock (&rng_lock);
	if (rng_data_present ()) {
		rng_data = rng_data_read ();
		spin_unlock (&rng_lock);
		if (rng_trusted)
			batch_entropy_store (rng_data, jiffies, rng_entropy);
		rng_fips_test_store (rng_data);
		if (rng_fips_counter > RNG_FIPS_TEST_THRESHOLD)
			rng_run_fips_test ();
	} else {
		spin_unlock (&rng_lock);
	}
	if (rng_timer_enabled) {
		rng_timer.expires = jiffies + rng_timer_len;
		add_timer (&rng_timer);
	}
}
static void rng_timer_tick ( unsigned long data ) { int rng_data ; spin_lock ( & rng_lock ) ; if ( rng_data_present ( ) ) { rng_data = rng_data_read ( ) ; spin_unlock ( & rng_lock ) ; if ( rng_trusted ) batch_entropy_store ( rng_data , jiffies , rng_entropy ) ; rng_fips_test_store ( rng_data ) ; if ( rng_fips_counter > RNG_FIPS_TEST_THRESHOLD ) rng_run_fips_test ( ) ; } else { spin_unlock ( & rng_lock ) ; } if ( rng_timer_enabled ) { rng_timer . expires = jiffies + rng_timer_len ; add_timer ( & rng_timer ) ; } }
rng_timer_ticker - executes every rng_timer_len jiffies,
                    adds a single byte to system entropy
                    and internal FIPS test pools
rng_timer_ticker - executes every rng_timer_len jiffies adds a single byte to system entropy and internal FIPS test pools
/* gimme some thermal noise, baby */ /*
		 * if RNG has been verified in the past, add
		 * data just read to the /dev/random pool,
		 * with the entropy specified by the user
		 * via sysctl (defaults to 8 bits)
		 */ /* fitness testing via FIPS, if we have enough data */ /* run the timer again, if enabled */