Skip to content

fix possible controller reset hangs in nvme-tcp/nvme-rdma

Sagi Grimberg linux-nvme 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest9 patches 34 repliesIn review
  2. v28 patches 21 repliesSuperseded
  3. v16 patches 14 repliesSuperseded

Changes in v3 from the cover letter

- move NVME_CTRL_NEW state check in __nvme_check_ready to a separate patch
- various comment phrasing fixes
- fixed change log descriptions
- changed patches nvme-tcp/nvme-rdma: fix timeout handler to restore the timed out requests cancellation for all the non-LIVE states as the request is going to be cancelled anyways. The change is now purely fixes how we serialize and fence against error recovery (as pointed out by James).

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/9nvme-fabrics: don't check state NVME_CTRL_NEW for request acceptancedrivers/nvme/host/fabrics.c+0 -12 replies
2/9nvme-fabrics: allow to queue requests for live queuesdrivers/nvme/host/fabrics.c+8 -422 replies
3/9nvme: have nvme_wait_freeze_timeout return if it timed outdrivers/nvme/host/core.c drivers/nvme/host/nvme.h+3 -21 reply
4/9nvme-tcp: serialize controller teardown sequencesdrivers/nvme/host/tcp.c+9 -20 replies
5/9nvme-tcp: fix timeout handlerdrivers/nvme/host/tcp.c+36 -200 replies
6/9nvme-tcp: fix reset hang if controller died in the middle of a resetdrivers/nvme/host/tcp.c+12 -10 replies
7/9nvme-rdma: serialize controller teardown sequencesdrivers/nvme/host/rdma.c+6 -03 replies
8/9nvme-rdma: fix timeout handlerdrivers/nvme/host/rdma.c+33 -162 replies
9/9nvme-rdma: fix reset hang if controller died in the middle of a resetdrivers/nvme/host/rdma.c+12 -11 reply

Reviews trailers per patch

6 of 9 patches have a Reviewed-by or Acked-by.

PatchChristoph HellwigJames Smart
1/9R-b R-b
2/9R-b R-b
3/9R-b
4/9
5/9
6/9
7/9R-b R-b
8/9R-b R-b
9/9R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 0/9] fix possible controller reset hangs in nvme-tcp/nvme-rdma

When a controller reset runs during I/O we may hang if the controller suddenly becomes unresponsive during the reset and/or the reconnection stages. This is due to how the timeout handler did not fail inflight commands properly and also not being able to abort the controller reset sequence when the controller becomes unresponsive (hence can't ever recover even if the controller ever becomes responsive again).

This set fixes nvme-tcp and nvme-rdma for exactly the same scenarios.

Changes from v2:
- move NVME_CTRL_NEW state check in __nvme_check_ready to a separate patch
- various comment phrasing fixes
- fixed change log descriptions
- changed patches nvme-tcp/nvme-rdma: fix timeout handler to restore the timed out requests cancellation for all the non-LIVE states as the request is going to be cancelled anyways. The change is now purely fixes how we serialize and fence against error recovery (as pointed out by James).

Changes from v1:
- added patches 3,6 to protect against possible (but rare) double completions for timed out requests.

Sagi Grimberg (9):
nvme-fabrics: don't check state NVME_CTRL_NEW for request acceptance
nvme-fabrics: allow to queue requests for live queues
nvme: have nvme_wait_freeze_timeout return if it timed out
nvme-tcp: serialize controller teardown sequences
nvme-tcp: fix timeout handler
nvme-tcp: fix reset hang if controller died in the middle of a reset
nvme-rdma: serialize controller teardown sequences
nvme-rdma: fix timeout handler
nvme-rdma: fix reset hang if controller died in the middle of a reset

 drivers/nvme/host/core.c    |  3 +-
 drivers/nvme/host/fabrics.c | 13 +++---
 drivers/nvme/host/nvme.h    |  2 +-
 drivers/nvme/host/rdma.c    | 68 +++++++++++++++++++++++--------
 drivers/nvme/host/tcp.c     | 80 ++++++++++++++++++++++++++-----------
 5 files changed, 119 insertions(+), 47 deletions(-)
Signature · 7 lines
2.25.1


_______________________________________________
Linux-nvme mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-nvme