diff options
author | 2023-03-06 10:13:13 +0900 | |
---|---|---|
committer | 2023-03-15 14:58:53 +0100 | |
commit | 6173a77b7e9d3e202bdb9897b23f2a8afe7bf286 (patch) | |
tree | 706cc3488fc991687413ee9496eaea9661fcc29e /tools/perf/scripts/python/export-to-postgresql.py | |
parent | nvme-trace: show more opcode names (diff) | |
download | wireguard-linux-6173a77b7e9d3e202bdb9897b23f2a8afe7bf286.tar.xz wireguard-linux-6173a77b7e9d3e202bdb9897b23f2a8afe7bf286.zip |
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/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions