]> git.karo-electronics.de Git - karo-tx-linux.git/commit
random: use lockless method of accessing and updating f->reg_idx
authorTheodore Ts'o <tytso@mit.edu>
Wed, 7 Jun 2017 23:01:32 +0000 (19:01 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Wed, 7 Jun 2017 23:01:32 +0000 (19:01 -0400)
commit92e75428ffc90e2a0321062379f883f3671cfebe
treeb06b973a94111993fa11672556d0e0c9d1bd134d
parent9dfa7bba35ac08a63565d58c454dccb7e1bb0a08
random: use lockless method of accessing and updating f->reg_idx

Linus pointed out that there is a much more efficient way of avoiding
the problem that we were trying to address in commit 9dfa7bba35ac0:
"fix race in drivers/char/random.c:get_reg()".

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
drivers/char/random.c