aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/hw_random.txt
diff options
context:
space:
mode:
authorDavid Brownell <dbrownell@users.sourceforge.net>2008-03-24 15:29:51 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-03-24 22:22:19 -0400
commit537878d2c988fa12bbfaec19ee060c7603a48230 (patch)
tree465e8f73b9330c32af8f6207a1c2aed61c5f8963 /Documentation/hw_random.txt
parentcb622bbb69e41f2746aadf5d7d527e77597abe2e (diff)
hw_random doc updates
Update documentation for the hw_random support to be current: - Documentation/hw_random.txt has been updated to reflect the current code: it's a framework now, a "core" with a small sysfs interface, that hardware-specific drivers plug in to. Text specific to Intel hardware is now at the end. - Kconfig now references the Documentation/hw_random.txt file and better explains what this really does. Both chunks of documentation now higlight the fact that the kernel entropy pool is maintained by "rngd", and this driver has nothing directly to do with that important task. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'Documentation/hw_random.txt')
-rw-r--r--Documentation/hw_random.txt59
1 files changed, 40 insertions, 19 deletions
diff --git a/Documentation/hw_random.txt b/Documentation/hw_random.txt
index bb58c36b5845..690f52550c80 100644
--- a/Documentation/hw_random.txt
+++ b/Documentation/hw_random.txt
@@ -1,33 +1,26 @@
1 Hardware driver for Intel/AMD/VIA Random Number Generators (RNG)
2 Copyright 2000,2001 Jeff Garzik <jgarzik@pobox.com>
3 Copyright 2000,2001 Philipp Rumpf <prumpf@mandrakesoft.com>
4
5Introduction: 1Introduction:
6 2
7 The hw_random device driver is software that makes use of a 3 The hw_random framework is software that makes use of a
8 special hardware feature on your CPU or motherboard, 4 special hardware feature on your CPU or motherboard,
9 a Random Number Generator (RNG). 5 a Random Number Generator (RNG). The software has two parts:
6 a core providing the /dev/hw_random character device and its
7 sysfs support, plus a hardware-specific driver that plugs
8 into that core.
10 9
11 In order to make effective use of this device driver, you 10 To make the most effective use of these mechanisms, you
12 should download the support software as well. Download the 11 should download the support software as well. Download the
13 latest version of the "rng-tools" package from the 12 latest version of the "rng-tools" package from the
14 hw_random driver's official Web site: 13 hw_random driver's official Web site:
15 14
16 http://sourceforge.net/projects/gkernel/ 15 http://sourceforge.net/projects/gkernel/
17 16
18About the Intel RNG hardware, from the firmware hub datasheet: 17 Those tools use /dev/hw_random to fill the kernel entropy pool,
19 18 which is used internally and exported by the /dev/urandom and
20 The Firmware Hub integrates a Random Number Generator (RNG) 19 /dev/random special files.
21 using thermal noise generated from inherently random quantum
22 mechanical properties of silicon. When not generating new random
23 bits the RNG circuitry will enter a low power state. Intel will
24 provide a binary software driver to give third party software
25 access to our RNG for use as a security feature. At this time,
26 the RNG is only to be used with a system in an OS-present state.
27 20
28Theory of operation: 21Theory of operation:
29 22
30 Character driver. Using the standard open() 23 CHARACTER DEVICE. Using the standard open()
31 and read() system calls, you can read random data from 24 and read() system calls, you can read random data from
32 the hardware RNG device. This data is NOT CHECKED by any 25 the hardware RNG device. This data is NOT CHECKED by any
33 fitness tests, and could potentially be bogus (if the 26 fitness tests, and could potentially be bogus (if the
@@ -36,9 +29,37 @@ Theory of operation:
36 a security-conscious person would run fitness tests on the 29 a security-conscious person would run fitness tests on the
37 data before assuming it is truly random. 30 data before assuming it is truly random.
38 31
39 /dev/hwrandom is char device major 10, minor 183. 32 The rng-tools package uses such tests in "rngd", and lets you
33 run them by hand with a "rngtest" utility.
34
35 /dev/hw_random is char device major 10, minor 183.
36
37 CLASS DEVICE. There is a /sys/class/misc/hw_random node with
38 two unique attributes, "rng_available" and "rng_current". The
39 "rng_available" attribute lists the hardware-specific drivers
40 available, while "rng_current" lists the one which is currently
41 connected to /dev/hw_random. If your system has more than one
42 RNG available, you may change the one used by writing a name from
43 the list in "rng_available" into "rng_current".
44
45==========================================================================
46
47 Hardware driver for Intel/AMD/VIA Random Number Generators (RNG)
48 Copyright 2000,2001 Jeff Garzik <jgarzik@pobox.com>
49 Copyright 2000,2001 Philipp Rumpf <prumpf@mandrakesoft.com>
50
51
52About the Intel RNG hardware, from the firmware hub datasheet:
53
54 The Firmware Hub integrates a Random Number Generator (RNG)
55 using thermal noise generated from inherently random quantum
56 mechanical properties of silicon. When not generating new random
57 bits the RNG circuitry will enter a low power state. Intel will
58 provide a binary software driver to give third party software
59 access to our RNG for use as a security feature. At this time,
60 the RNG is only to be used with a system in an OS-present state.
40 61
41Driver notes: 62Intel RNG Driver notes:
42 63
43 * FIXME: support poll(2) 64 * FIXME: support poll(2)
44 65