nvme-fc: enhance transport error handling when create associations
Status from this message: Applied, thanks!
Get series with b4
b4 am [email protected]Versions newest first
Patches in v1 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | nvme-fc: return non-zero status code when fails to create associationdrivers/ | +15 | 1 reply | |
| 2/2 | nvme-fc: fix race between error recovery and creating associationdrivers/ | +16 | 2 replies |
Reviews trailers per patch
All 2 patches have a Reviewed-by or Acked-by.
| Patch | Caleb Sander | James Smart |
|---|---|---|
| 1/2 | R-b | R-b |
| 2/2 | R-b | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 0/2] nvme-fc: enhance transport error handling when create associations
Currently when there is some transport error happens during creating nvme-fc association, nvme_fc_create_association() could return 0 status code which implies the association creation was done successfully while it's actually not. The consequence is the nvme controller could be stuck in connecting state infinitely. Also there is a potential race condition between transport io error recovery and the last ASSOC_FAILED check in nvme_fc_create_association(). We may end up ignoring a transport error during connecting creation.
Fix these two issues by:
1. Return non-zero status code(-EIO) when needed, so re-connecting or deleting controller will be triggered properly;
2. Protect accessing to nvme-fc controller ASSOC_FAILED flag and nvme controller state transition under nvme-fc controller's spin lock;
Michael Liang (2):
nvme-fc: return non-zero status code when fails to create association
nvme-fc: fix race between error recovery and creating association
drivers/nvme/host/fc.c | 37 +++++++++++++++++++++++++++++-------- 1 file changed, 29 insertions(+), 8 deletions(-)
Signature · 1 line
2.34.1