numam-spdk/test
Ziye Yang 4cd6544d44 nvmf: solve the memory leak issue caused by subsystem listerner port
The possible issue could be following if you shutdown NVMe-oF target
with TCP transport as an example,

=================================================================
==61022==ERROR: LeakSanitizer: detected memory leaks

Direct leak of 560 byte(s) in 1 object(s) allocated from:
    #0 0x7ffff6efcfe0 in calloc (/lib64/libasan.so.3+0xc6fe0)
    #1 0x4c6216 in spdk_nvmf_tcp_listen /home/ziyeyang/spdk/lib/nvmf/tcp.c:680

Indirect leak of 48 byte(s) in 1 object(s) allocated from:
    #0 0x7ffff6efcfe0 in calloc (/lib64/libasan.so.3+0xc6fe0)
    #1 0x4a77b8 in spdk_posix_sock_create /home/ziyeyang/spdk/lib/sock/posix/posix.c:291

After checking the issue, it seems that we did not call
spdk_nvmf_transport_stop_listen when removing the subsystem listener.
And this patch can solve this issue.

Change-Id: Ic75d99cb0c6a3ba1c47ac79a2d8e3887b0f6b012
Signed-off-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/447020
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: yidong0635 <dongx.yi@intel.com>
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Seth Howell <seth.howell5141@gmail.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-03-08 20:33:33 +00:00
..
app event: Remove arg2 from spdk_app_start() 2019-03-05 08:43:12 +00:00
bdev event: Remove arg2 from spdk_app_start() 2019-03-05 08:43:12 +00:00
blobfs event: Remove arg2 from spdk_app_start() 2019-03-05 08:43:12 +00:00
blobstore histograms: tests for bdev histograms 2019-01-24 21:50:18 +00:00
common test scripts: add -E to sudo git clone in vm_setup.sh 2019-03-04 19:12:10 +00:00
config_converter config_converter: Remove deprecated construct_nvmf_subsystem RPC 2019-01-29 16:17:03 +00:00
cpp_headers build: don't include spdk.app.mk in test/cpp_headers 2018-12-12 22:35:21 +00:00
env test/env: add UNIT_TEST_NO_PCI_ADDR 2019-03-04 14:00:16 +00:00
event event: Remove arg2 from spdk_app_start() 2019-03-05 08:43:12 +00:00
ftl test/ftl: Remove deprecated max_delay parameter from tests 2019-02-20 21:30:29 +00:00
ioat ioat: remove ioat kperf kernel driver test harness 2018-04-30 17:11:53 +00:00
iscsi_tgt test/iscsi_tgt: Use rpc instead of config file. 2019-02-22 18:28:25 +00:00
json_config test:increase the json_config.sh shutdown app timeout value 2019-02-22 09:55:03 +00:00
lvol test/lvol: Implement test case 653 2019-03-01 22:54:07 +00:00
nvme test/nvmf/nvme-cli: don't run nvme-cli as secondary process 2019-01-29 20:54:13 +00:00
nvmf test/nvmf: detect a subclass of Chelsio NICs 2019-03-07 08:35:02 +00:00
ocf OCF: rpc: add get_ocf_bdevs method 2019-01-28 18:53:31 +00:00
pmem bdev: remove delete_bdev RPC 2019-03-01 08:50:07 +00:00
rpc_client jsonrpc: add connection close callback 2019-01-10 14:31:37 +00:00
spdkcli test/spdkcli: update match file to cover larger volume NVMe SSD 2019-03-08 02:18:15 +00:00
unit nvmf: solve the memory leak issue caused by subsystem listerner port 2019-03-08 20:33:33 +00:00
vhost test/vhost: add windows filesystem test 2019-02-25 23:16:44 +00:00
Makefile jsonrpc-client: add new C client library 2018-10-11 20:07:44 +00:00
spdk_cunit.h test: remove leftover spdk_cunit declaration 2018-07-06 22:47:56 +00:00