Skip to content
Commit e5fccaa1 authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller
Browse files

net: core: add READ_ONCE/WRITE_ONCE annotations for sk->sk_bound_dev_if



sock_bindtoindex_locked() needs to use WRITE_ONCE(sk->sk_bound_dev_if, val),
because other cpus/threads might locklessly read this field.

sock_getbindtodevice(), sock_getsockopt() need READ_ONCE()
because they run without socket lock held.

Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent fdb5fd7f
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