From 4a6c5c9a3a3dbffa9f29d1298da047dd28793356 Mon Sep 17 00:00:00 2001 From: Jarod Wilson Date: Mon, 21 Feb 2011 21:43:10 +1100 Subject: [PATCH] --- yaml --- r: 235079 b: refs/heads/master c: 442a4fffffa26fc3080350b4d50172f7589c3ac2 h: refs/heads/master i: 235077: 64680ca1253a811ad5ddcf0a1893b3956c893a22 235075: c31ded3b19f8f7246cc7d12a4848f7eef281614f 235071: b5b9cc9c88fd81b949e21b8a27d9667855e45ab3 v: v3 --- [refs] | 2 +- trunk/drivers/char/random.c | 13 ++++++++++--- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/[refs] b/[refs] index d7e62ffe1ad6..ec668a1ad56a 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: ce92136843cb6e14aba5fd7bc4e88dbe71e70c5a +refs/heads/master: 442a4fffffa26fc3080350b4d50172f7589c3ac2 diff --git a/trunk/drivers/char/random.c b/trunk/drivers/char/random.c index 72a4fcb17745..5e29e8031bbc 100644 --- a/trunk/drivers/char/random.c +++ b/trunk/drivers/char/random.c @@ -128,6 +128,7 @@ * void add_input_randomness(unsigned int type, unsigned int code, * unsigned int value); * void add_interrupt_randomness(int irq); + * void add_disk_randomness(struct gendisk *disk); * * add_input_randomness() uses the input layer interrupt timing, as well as * the event type information from the hardware. @@ -136,9 +137,15 @@ * inputs to the entropy pool. Note that not all interrupts are good * sources of randomness! For example, the timer interrupts is not a * good choice, because the periodicity of the interrupts is too - * regular, and hence predictable to an attacker. Disk interrupts are - * a better measure, since the timing of the disk interrupts are more - * unpredictable. + * regular, and hence predictable to an attacker. Network Interface + * Controller interrupts are a better measure, since the timing of the + * NIC interrupts are more unpredictable. + * + * add_disk_randomness() uses what amounts to the seek time of block + * layer request events, on a per-disk_devt basis, as input to the + * entropy pool. Note that high-speed solid state drives with very low + * seek times do not make for good sources of entropy, as their seek + * times are usually fairly consistent. * * All of these routines try to estimate how many bits of randomness a * particular randomness source. They do this by keeping track of the