nvmf/vfio-user: rename vfio_user_stop_ctrlr() to vfio_user_destroy_ctrlr()

The original function will disconnect queue pairs first and then free
controller memory finally, so rename it to vfio_user_destroy_ctrlr().

Change-Id: Idc235e4186bd4164be712fc9d4cda4991efc6248
Signed-off-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7624
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: <dongx.yi@intel.com>
This commit is contained in:
Changpeng Liu 2021-04-27 21:16:03 +08:00 committed by Jim Harris
parent 0cc8bcf508
commit 45b5676738

View File

@ -1932,7 +1932,7 @@ vfio_user_qpair_disconnect_cb(void *ctx)
}
static int
vfio_user_stop_ctrlr(struct nvmf_vfio_user_ctrlr *ctrlr)
vfio_user_destroy_ctrlr(struct nvmf_vfio_user_ctrlr *ctrlr)
{
uint32_t i;
struct nvmf_vfio_user_qpair *qpair;
@ -1970,7 +1970,7 @@ vfio_user_poll_mmio(void *ctx)
/* initiator shutdown or reset, waiting for another re-connect */
if (errno == ENOTCONN) {
vfio_user_stop_ctrlr(ctrlr);
vfio_user_destroy_ctrlr(ctrlr);
return SPDK_POLLER_BUSY;
}