summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/task-analyzer.py
diff options
context:
space:
mode:
authorDamien Le Moal <damien.lemoal@opensource.wdc.com>2023-03-06 04:13:13 +0300
committerChristoph Hellwig <hch@lst.de>2023-03-15 16:58:53 +0300
commit6173a77b7e9d3e202bdb9897b23f2a8afe7bf286 (patch)
tree706cc3488fc991687413ee9496eaea9661fcc29e /tools/perf/scripts/python/task-analyzer.py
parent8e19b87cfce2de2125f11363d7dea3d08f16ccae (diff)
downloadlinux-6173a77b7e9d3e202bdb9897b23f2a8afe7bf286.tar.xz
nvmet: avoid potential UAF in nvmet_req_complete()
An nvme target ->queue_response() operation implementation may free the request passed as argument. Such implementation potentially could result in a use after free of the request pointer when percpu_ref_put() is called in nvmet_req_complete(). Avoid such problem by using a local variable to save the sq pointer before calling __nvmet_req_complete(), thus avoiding dereferencing the req pointer after that function call. Fixes: a07b4970f464 ("nvmet: add a generic NVMe target") Signed-off-by: Damien Le Moal <damien.lemoal@opensource.wdc.com> Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'tools/perf/scripts/python/task-analyzer.py')
0 files changed, 0 insertions, 0 deletions