nvme-fabrics: introduce init command check for a queue that is not alive
authorSagi Grimberg <sagi@grimberg.me>
Tue, 24 Oct 2017 12:25:20 +0000 (15:25 +0300)
committerChristoph Hellwig <hch@lst.de>
Mon, 20 Nov 2017 07:28:31 +0000 (08:28 +0100)
commit48832f8d58cfedb2f9bee11bbfbb657efb42e7e7
tree30360bde8edf83b16502dc7d832bb5aa586add4b
parent1690102de5651bb85b23d5eeaff682a6b96d705b
nvme-fabrics: introduce init command check for a queue that is not alive

When the fabrics queue is not alive and fully functional, no commands
should be allowed to pass but connect (which moves the queue to a fully
functional state). Any other command should be failed, with either
temporary status BLK_STS_RESOUCE or permanent status BLK_STS_IOERR.

This is shared across all fabrics, hence move the check to fabrics
library.

Signed-off-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Christoph Hellwig <hch@lst.de>
drivers/nvme/host/fabrics.h
drivers/nvme/host/rdma.c