Commit 7bf7d778 authored by Keith Busch's avatar Keith Busch Committed by Jens Axboe

nvme/pci: Don't mark IOD as aborted if abort wasn't sent

This patch sets the aborted flag only if an abort was sent, reducing
excessive kernel message spamming for completed IO that wasn't actually
aborted.
Reported-by: default avatarJens Axboe <axboe@kernel.dk>
Signed-off-by: default avatarKeith Busch <keith.busch@intel.com>
Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
Reviewed-by: default avatarSagi Grimberg <sagi@grimberg.me>
Signed-off-by: default avatarJens Axboe <axboe@fb.com>
parent 9a69b0ed
...@@ -898,12 +898,11 @@ static enum blk_eh_timer_return nvme_timeout(struct request *req, bool reserved) ...@@ -898,12 +898,11 @@ static enum blk_eh_timer_return nvme_timeout(struct request *req, bool reserved)
return BLK_EH_HANDLED; return BLK_EH_HANDLED;
} }
iod->aborted = 1;
if (atomic_dec_return(&dev->ctrl.abort_limit) < 0) { if (atomic_dec_return(&dev->ctrl.abort_limit) < 0) {
atomic_inc(&dev->ctrl.abort_limit); atomic_inc(&dev->ctrl.abort_limit);
return BLK_EH_RESET_TIMER; return BLK_EH_RESET_TIMER;
} }
iod->aborted = 1;
memset(&cmd, 0, sizeof(cmd)); memset(&cmd, 0, sizeof(cmd));
cmd.abort.opcode = nvme_admin_abort_cmd; cmd.abort.opcode = nvme_admin_abort_cmd;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment