]> git.ipfire.org Git - thirdparty/kernel/stable.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)
committerSasha Levin <alexander.levin@microsoft.com>
Wed, 23 May 2018 01:36:30 +0000 (21:36 -0400)
commitd635fe73c14ad168e174901e6ff7ef096b37e28e
tree75bcc55bf7084a3475ff5de6a62f9ce4ddf13aee
parent8ef9d513fa48ed0d7c64f816e111d3b489c2921e
random: use lockless method of accessing and updating f->reg_idx

[ Upstream commit 92e75428ffc90e2a0321062379f883f3671cfebe ]

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>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
drivers/char/random.c