linux-stable/net/smc
Eric Dumazet acf3314a31 net: annotate data-races around sk->sk_lingertime
[ Upstream commit bc1fb82ae1 ]

sk_getsockopt() runs locklessly. This means sk->sk_lingertime
can be read while other threads are changing its value.

Other reads also happen without socket lock being held,
and must be annotated.

Remove preprocessor logic using BITS_PER_LONG, compilers
are smart enough to figure this by themselves.

v2: fixed a clang W=1 (-Wtautological-constant-out-of-range-compare) warning
    (Jakub)

Fixes: 1da177e4c3 ("Linux-2.6.12-rc2")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-09-13 09:48:05 +02:00
..
Kconfig
Makefile net/smc: fix compile warning for smc_sysctl 2022-03-07 11:59:17 +00:00
af_smc.c net: annotate data-races around sk->sk_lingertime 2023-09-13 09:48:05 +02:00
smc.h net/smc: Fix setsockopt and sysctl to specify same buffer size again 2023-08-16 18:32:25 +02:00
smc_cdc.c net/smc: fix NULL sndbuf_desc in smc_cdc_tx_handler() 2023-03-13 16:03:58 -07:00
smc_cdc.h net/smc: fix kernel panic caused by race of smc_sock 2021-12-28 12:42:45 +00:00
smc_clc.c net/smc: Fix setsockopt and sysctl to specify same buffer size again 2023-08-16 18:32:25 +02:00
smc_clc.h net/smc: Allow virtually contiguous sndbufs or RMBs for SMC-R 2022-07-18 11:19:17 +01:00
smc_close.c net: deal with most data-races in sk_wait_event() 2023-05-10 10:03:32 +01:00
smc_close.h
smc_core.c net/smc: Fix setsockopt and sysctl to specify same buffer size again 2023-08-16 18:32:25 +02:00
smc_core.h net/smc: Use percpu ref for wr tx reference 2023-03-17 08:59:01 +00:00
smc_diag.c net/smc: Separate SMC-D and ISM APIs 2023-01-25 09:46:48 +00:00
smc_ib.c mm, treewide: redefine MAX_ORDER sanely 2023-04-05 19:42:46 -07:00
smc_ib.h net/smc: optimize for smc_sndbuf_sync_sg_for_device and smc_rmb_sync_sg_for_cpu 2022-07-18 11:19:17 +01:00
smc_ism.c net/smc: Introduce explicit check for v2 support 2023-03-15 08:18:35 +00:00
smc_ism.h net/smc: Register SMC-D as ISM client 2023-01-25 09:46:48 +00:00
smc_llc.c net/smc: Avoid to access invalid RMBs' MRs in SMCRv1 ADD LINK CONT 2023-06-03 20:51:04 +01:00
smc_llc.h net/smc: Introduce a specific sysctl for TEST_LINK time 2022-09-22 12:58:21 +02:00
smc_netlink.c genetlink: start to validate reserved header bytes 2022-08-29 12:47:15 +01:00
smc_netlink.h net/smc: add support for user defined EIDs 2021-09-14 12:49:10 +01:00
smc_netns.h net/smc: introduce list of pnetids for Ethernet devices 2020-09-28 15:19:03 -07:00
smc_pnet.c net/smc: De-tangle ism and smc device initialization 2023-01-25 09:46:49 +00:00
smc_pnet.h net/smc: Use a mutex for locking "struct smc_pnettable" 2022-02-24 09:09:33 -08:00
smc_rx.c net: deal with most data-races in sk_wait_event() 2023-05-10 10:03:32 +01:00
smc_rx.h
smc_stats.c net/smc: Fix ENODATA tests in smc_nl_get_fback_stats() 2021-06-21 12:16:58 -07:00
smc_stats.h net/smc: Make SMC statistics network namespace aware 2021-06-16 12:54:02 -07:00
smc_sysctl.c net/smc: Fix setsockopt and sysctl to specify same buffer size again 2023-08-16 18:32:25 +02:00
smc_sysctl.h net/smc: fix -Wmissing-prototypes warning when CONFIG_SYSCTL not set 2022-03-09 20:02:35 -08:00
smc_tracepoint.c net/smc: Introduce tracepoint for smcr link down 2021-11-01 13:39:14 +00:00
smc_tracepoint.h net/smc: Add net namespace for tracepoints 2022-01-02 12:07:39 +00:00
smc_tx.c net: deal with most data-races in sk_wait_event() 2023-05-10 10:03:32 +01:00
smc_tx.h net/smc: Cork when sendpage with MSG_SENDPAGE_NOTLAST flag 2022-01-31 15:08:20 +00:00
smc_wr.c net/smc: Use percpu ref for wr tx reference 2023-03-17 08:59:01 +00:00
smc_wr.h net/smc: Use percpu ref for wr tx reference 2023-03-17 08:59:01 +00:00