Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 0904f321 authored by Kuniyuki Iwashima's avatar Kuniyuki Iwashima Committed by Vegard Nossum
Browse files

ipv6: Fix data races around sk->sk_prot.



commit 364f997b5cfe1db0d63a390fe7c801fa2b3115f6 upstream.

Commit 086d49058cd8 ("ipv6: annotate some data-races around sk->sk_prot")
fixed some data-races around sk->sk_prot but it was not enough.

Some functions in inet6_(stream|dgram)_ops still access sk->sk_prot
without lock_sock() or rtnl_lock(), so they need READ_ONCE() to avoid
load tearing.

Fixes: 1da177e4 ("Linux-2.6.12-rc2")
Signed-off-by: default avatarKuniyuki Iwashima <kuniyu@amazon.com>
Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
Signed-off-by: default avatarKazunori Kobayashi <kazunori.kobayashi@miraclelinux.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit fda6d62642a9c544a293d7ad7cb058f8c7f8f3dd)
[Vegard: fix conflict due to missing commit
 d74bad4e74ee373787a9ae24197c17b7cdc428d5 ("bpf: Hooks for
 sys_connect").]
Signed-off-by: default avatarVegard Nossum <vegard.nossum@oracle.com>
parent 81d8db93
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment