nvmf: Remove invalid asserts
The address of an array element will never be null. Change-Id: Id460cee75dd037b144271f7b5504004d25092c1e Signed-off-by: Ben Walker <benjamin.walker@intel.com> Reviewed-on: https://review.gerrithub.io/426135 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Chandler-Test-Pool: SPDK Automated Test System <sys_sgsw@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com>
This commit is contained in:
parent
c48402892e
commit
33ed49d2e9
@ -200,7 +200,6 @@ new_qpair(struct spdk_nvmf_qpair *qpair)
|
|||||||
core = nvmf_tgt_get_qpair_core(qpair);
|
core = nvmf_tgt_get_qpair_core(qpair);
|
||||||
|
|
||||||
pg = &g_poll_groups[core];
|
pg = &g_poll_groups[core];
|
||||||
assert(pg != NULL);
|
|
||||||
|
|
||||||
event = spdk_event_allocate(core, nvmf_tgt_poll_group_add, qpair, pg);
|
event = spdk_event_allocate(core, nvmf_tgt_poll_group_add, qpair, pg);
|
||||||
spdk_event_call(event);
|
spdk_event_call(event);
|
||||||
@ -229,7 +228,6 @@ nvmf_tgt_destroy_poll_group(void *ctx)
|
|||||||
struct nvmf_tgt_poll_group *pg;
|
struct nvmf_tgt_poll_group *pg;
|
||||||
|
|
||||||
pg = &g_poll_groups[spdk_env_get_current_core()];
|
pg = &g_poll_groups[spdk_env_get_current_core()];
|
||||||
assert(pg != NULL);
|
|
||||||
|
|
||||||
spdk_nvmf_poll_group_destroy(pg->group);
|
spdk_nvmf_poll_group_destroy(pg->group);
|
||||||
pg->group = NULL;
|
pg->group = NULL;
|
||||||
@ -251,7 +249,6 @@ nvmf_tgt_create_poll_group(void *ctx)
|
|||||||
struct nvmf_tgt_poll_group *pg;
|
struct nvmf_tgt_poll_group *pg;
|
||||||
|
|
||||||
pg = &g_poll_groups[spdk_env_get_current_core()];
|
pg = &g_poll_groups[spdk_env_get_current_core()];
|
||||||
assert(pg != NULL);
|
|
||||||
|
|
||||||
pg->group = spdk_nvmf_poll_group_create(g_spdk_nvmf_tgt);
|
pg->group = spdk_nvmf_poll_group_create(g_spdk_nvmf_tgt);
|
||||||
assert(pg->group != NULL);
|
assert(pg->group != NULL);
|
||||||
|
Loading…
Reference in New Issue
Block a user