lkml.org 
[lkml]   [2012]   [Jul]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] random: mix in architectural randomness in extract_buf()
Ok, I'll add this patch to the random tree.  I've modified the commit
message a bit since the speed advertisement of RDRAND is rather
pointless --- processes aren't generating session keys or long term
keys at a high rate, and programs can't count on /dev/random being
super fast and having unlimited entropy, since for most platforms and
even most x86 CPU's deployed in service today, this isn't true --- and
making your userspace program depond upon /dev/random in such a way
that it only works on Ivy Bridge CPU's might be good for Intel from a
vendor lock-in perspective, but it's really bad, non-portable
programming style.

Also, in the future arch_get_random_long() will almost certainly be
hooked up for other architectures, so putting an extended
advertisement for RDRAND really isn't appropriate.

- Ted

commit d2e7c96af1e54b507ae2a6a7dd2baf588417a7e5
Author: H. Peter Anvin <hpa@linux.intel.com>
Date: Fri Jul 27 22:26:08 2012 -0400

random: mix in architectural randomness in extract_buf()

Mix in any architectural randomness in extract_buf() instead of
xfer_secondary_buf(). This allows us to mix in more architectural
randomness, and it also makes xfer_secondary_buf() faster, moving a
tiny bit of additional CPU overhead to process which is extracting the
randomness.

[ Commit description modified by tytso to remove an extended
advertisement for the RDRAND instruction. ]

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Acked-by: Ingo Molnar <mingo@kernel.org>
Cc: DJ Johnston <dj.johnston@intel.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Cc: stable@vger.kernel.org


\
 
 \ /
  Last update: 2012-07-28 05:21    [W:0.133 / U:0.912 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site