+31
−6
Loading
Serparate spdk_nvme_ctrlr_disconnect() into nvme_ctrlr_disconnect() and nvme_ctrlr_disconnect_done() to call nvme_ctrlr_disconnect_done() after adminq is actually disconnected when disconnecting adminq asynchronously. The following patches will add a new flag is_disconnecting to struct spdk_nvme_ctrlr and prevent us from setting ctrlr->is_failed to true between nvme_ctrlr_disconnect() and nvme_ctrlr_disconnect_done(). By this patch, nvme_ctrlr_disconnect() and nvme_ctrlr_disconnect_done() are executed in the same context. So it is not possible to set ctrlr->is_failed to true between nvme_ctrlr_disconnect() and nvme_ctrlr_disconnect_done(). Hence nvme_ctrlr_disconnect_done() does not have to clear ctrlr->is_failed again. Signed-off-by:Shuhei Matsumoto <smatsumoto@nvidia.com> Change-Id: I18b5b68f37e27b54782691823edae9738c26faa1 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/10999 Tested-by:
SPDK CI Jenkins <sys_sgci@intel.com> Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com> Community-CI: Mellanox Build Bot Reviewed-by:
Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by:
Ben Walker <benjamin.walker@intel.com>