]> git.karo-electronics.de Git - linux-beck.git/commit
random: forget lock in lockless accounting
authorGreg Price <price@MIT.EDU>
Sat, 30 Nov 2013 01:09:37 +0000 (20:09 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 20 Mar 2014 02:18:51 +0000 (22:18 -0400)
commita58aa4edc6d2e779894b1fa95a2f4de157ff3b3b
tree9ae4c66ee56c768cdc6370a879154acbccb10133
parentee1de406ba6eb1e01f143fe3351e70cc772cc63e
random: forget lock in lockless accounting

The only mutable data accessed here is ->entropy_count, but since
10b3a32d2 ("random: fix accounting race condition") we use cmpxchg to
protect our accesses to ->entropy_count here.  Drop the use of the
lock.

Cc: Jiri Kosina <jkosina@suse.cz>
Signed-off-by: Greg Price <price@mit.edu>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
drivers/char/random.c