summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/bin/stackcollapse-record
diff options
context:
space:
mode:
authorJakub Kicinski <kuba@kernel.org>2026-08-24 11:52:02 -0700
committerJakub Kicinski <kuba@kernel.org>2026-08-24 11:52:02 -0700
commitc745d091fc6fe59bc4c4024d6cee8b8bd120f298 (patch)
treea2668b5a28f2fabec6e194067d334dc4050e01c7 /tools/perf/scripts/python/bin/stackcollapse-record
parent719296c4aa8213d4ac8002e77d5956d436bc98d0 (diff)
parentc924884743e948e25625b7fbf3ee2a9325a204a7 (diff)
Merge branch 'net-smc-fix-use-after-free-in-smc_rx_pipe_buf_release'
Hidayath Khan says: ==================== net/smc: fix use-after-free in smc_rx_pipe_buf_release() smc_rx_pipe_buf_release() tests sk_state before taking the socket lock and then dereferences conn->rmb_desc and conn->lgr. A concurrent close runs smc_conn_free() in between, which releases those structures. On the is_reg_err path smcr_buf_unuse() frees the descriptor outright, so this is a use-after-free. Patch 2/2 fixes this by taking the socket lock first and testing conn->freed instead. smc_conn_free() sets that flag before releasing anything, under the same lock, so the two paths exclude each other. Patch 1/2 is a prerequisite. conn->freed shares a byte with killed and out_of_sync as single-bit bitfields. out_of_sync is written from the receive tasklet without the socket lock, so a concurrent store to freed from process context can be lost in the read-modify-write. Patch 1/2 gives each flag its own byte so stores do not interfere. ==================== Link: https://patch.msgid.link/20260820074642.966856-1-hidayath@linux.ibm.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/bin/stackcollapse-record')
0 files changed, 0 insertions, 0 deletions