]> git.karo-electronics.de Git - karo-tx-linux.git/commit
random: create add_device_randomness() interface
authorLinus Torvalds <torvalds@linux-foundation.org>
Wed, 4 Jul 2012 15:16:01 +0000 (11:16 -0400)
committerPaul Gortmaker <paul.gortmaker@windriver.com>
Fri, 17 Aug 2012 19:36:05 +0000 (15:36 -0400)
commit79df207bf71de0fc8c2de8d0eead6cd9283a85ed
tree62a574397b2e65a3b0fc1981d4484988d6418450
parent9233ef75a68d43f82dbd4bf699177c4f9f55a1a3
random: create add_device_randomness() interface

commit a2080a67abe9e314f9e9c2cc3a4a176e8a8f8793 upstream.

Add a new interface, add_device_randomness() for adding data to the
random pool that is likely to differ between two devices (or possibly
even per boot).  This would be things like MAC addresses or serial
numbers, or the read-out of the RTC. This does *not* add any actual
entropy to the pool, but it initializes the pool to different values
for devices that might otherwise be identical and have very little
entropy available to them (particularly common in the embedded world).

[ Modified by tytso to mix in a timestamp, since there may be some
  variability caused by the time needed to detect/configure the hardware
  in question. ]

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
drivers/char/random.c
include/linux/random.h