Skip to content

Commit

Permalink
nvme-pci: Fix abort command id
Browse files Browse the repository at this point in the history
The request tag is no longer the only component of the command id.

Fixes: e7006de ("nvme: code command_id with a genctr for use-after-free validation")
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Keith Busch <kbusch@kernel.org>
  • Loading branch information
Keith Busch committed Oct 7, 2021
1 parent 298ba0e commit 85f74ac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/nvme/host/pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -1330,7 +1330,7 @@ static enum blk_eh_timer_return nvme_timeout(struct request *req, bool reserved)
iod->aborted = 1;

cmd.abort.opcode = nvme_admin_abort_cmd;
cmd.abort.cid = req->tag;
cmd.abort.cid = nvme_cid(req);
cmd.abort.sqid = cpu_to_le16(nvmeq->qid);

dev_warn(nvmeq->dev->ctrl.device,
Expand Down

0 comments on commit 85f74ac

Please sign in to comment.