linux/drivers/nvme
Sagi Grimberg 99160af413 nvme-mpath: fix I/O failure with EAGAIN when failing over I/O
It is possible that the next available path we failover to, happens to
be frozen (for example if it is during connection establishment). If
the original I/O was set with NOWAIT, this cause the I/O to unnecessarily
fail because the request queue cannot be entered, hence the I/O fails with
EAGAIN.

The NOWAIT restriction that was originally set for the I/O is no longer
relevant or needed because this is the nvme requeue context. Hence we
clear the REQ_NOWAIT flag when failing over I/O.

This fix a simple test case of nvme controller reset during I/O when the
multipath device that has only a single path and I/O fails with "Resource
temporarily unavailable" errno. Note that this reproduces with io_uring
which by default sets IOCB_NOWAIT by default.

Signed-off-by: Sagi Grimberg <sagi@grimberg.me>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Keith Busch <kbusch@kernel.org>
2023-06-27 08:16:26 -07:00
..
common treewide: use get_random_u32() when possible 2022-10-11 17:42:58 -06:00
host nvme-mpath: fix I/O failure with EAGAIN when failing over I/O 2023-06-27 08:16:26 -07:00
target nvmet: Reorder fields in 'struct nvmet_ns' 2023-06-21 09:41:40 -07:00
Kconfig nvme: implement In-Band authentication 2022-08-02 17:14:49 -06:00
Makefile nvme: implement In-Band authentication 2022-08-02 17:14:49 -06:00