From 09b0c84f1b6a932823ee8836f9cf9f48c9c1a86f Mon Sep 17 00:00:00 2001 From: Ben Walker Date: Tue, 16 Mar 2021 18:53:31 -0700 Subject: [PATCH] event/nvmf: Remove use of spdk_app_stop() This is the only reason the event.h header is included here and it isn't necessary. Signed-off-by: Ben Walker Change-Id: I4c0a9828cfede1ccd1c9263ad66b354ba167f434 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/6919 Community-CI: Broadcom CI Tested-by: SPDK CI Jenkins Reviewed-by: Changpeng Liu Reviewed-by: Shuhei Matsumoto Reviewed-by: Reviewed-by: Tomasz Zawadzki --- module/event/subsystems/nvmf/nvmf_tgt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/module/event/subsystems/nvmf/nvmf_tgt.c b/module/event/subsystems/nvmf/nvmf_tgt.c index 5fd27e5366..5f5ea5dbdf 100644 --- a/module/event/subsystems/nvmf/nvmf_tgt.c +++ b/module/event/subsystems/nvmf/nvmf_tgt.c @@ -34,7 +34,6 @@ #include "event_nvmf.h" #include "spdk/bdev.h" -#include "spdk/event.h" #include "spdk/thread.h" #include "spdk/log.h" #include "spdk/nvme.h" @@ -173,7 +172,8 @@ nvmf_tgt_create_poll_group(void *ctx) pg = calloc(1, sizeof(*pg)); if (!pg) { SPDK_ERRLOG("Not enough memory to allocate poll groups\n"); - spdk_app_stop(-ENOMEM); + g_tgt_state = NVMF_TGT_ERROR; + nvmf_tgt_advance_state(); return; }