aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/dsa/dsa_loop.c
diff options
context:
space:
mode:
authorSowmini Varadhan <[email protected]>2017-11-30 19:11:29 +0000
committerDavid S. Miller <[email protected]>2017-12-01 20:25:15 +0000
commitf10b4cff98c6977668434fbf5dd58695eeca2897 (patch)
tree71350054376a576a62bafac64b96b601f1290d85 /drivers/net/dsa/dsa_loop.c
parentrds: tcp: correctly sequence cleanup on netns deletion. (diff)
downloadkernel-f10b4cff98c6977668434fbf5dd58695eeca2897.tar.gz
kernel-f10b4cff98c6977668434fbf5dd58695eeca2897.zip
rds: tcp: atomically purge entries from rds_tcp_conn_list during netns delete
The rds_tcp_kill_sock() function parses the rds_tcp_conn_list to find the rds_connection entries marked for deletion as part of the netns deletion under the protection of the rds_tcp_conn_lock. Since the rds_tcp_conn_list tracks rds_tcp_connections (which have a 1:1 mapping with rds_conn_path), multiple tc entries in the rds_tcp_conn_list will map to a single rds_connection, and will be deleted as part of the rds_conn_destroy() operation that is done outside the rds_tcp_conn_lock. The rds_tcp_conn_list traversal done under the protection of rds_tcp_conn_lock should not leave any doomed tc entries in the list after the rds_tcp_conn_lock is released, else another concurrently executiong netns delete (for a differnt netns) thread may trip on these entries. Reported-by: syzbot <[email protected]> Signed-off-by: Sowmini Varadhan <[email protected]> Acked-by: Santosh Shilimkar <[email protected]> Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'drivers/net/dsa/dsa_loop.c')
0 files changed, 0 insertions, 0 deletions