* [SPDK] coredump in the memory malloc
@ 2017-12-21 2:10 Huang Frank
0 siblings, 0 replies; 2+ messages in thread
From: Huang Frank @ 2017-12-21 2:10 UTC (permalink / raw)
To: spdk
[-- Attachment #1: Type: text/plain, Size: 1412 bytes --]
hi,all
I meet a strange problem. I first alloacte a block for some variable, I want 0x400000 align. In the following ways:
spdk_dma_zmalloc(buf_size, 0x400000, &dma_addr);
It return 0x7ffff2600000.And then the next malloc get coredump. the address of elem in malloc_elem_free_list_insert equal to the prev malloc address.
(gdb) bt
#0 0x0000000000431b70 in malloc_elem_free_list_insert (elem=0x7ffff2600000)
at /home/xxx/spdk/dpdk/lib/librte_eal/common/malloc_elem.c:187
#1 0x0000000000431d94 in malloc_elem_alloc (elem=0x7ffff2600000, size=64, align=64, bound=0)
at /home/xxx/spdk/dpdk/lib/librte_eal/common/malloc_elem.c:249
#2 0x00000000004323fe in malloc_heap_alloc (heap=0x7ffff7fefa1c, type=0x0, size=64, flags=0, align=64, bound=0)
at /home/xxx/spdk/dpdk/lib/librte_eal/common/malloc_heap.c:168
#3 0x000000000043125f in rte_malloc_socket (type=0x0, size=48, align=0, socket_arg=-1)
at /home/xxx/spdk/dpdk/lib/librte_eal/common/rte_malloc.c:91
#4 0x000000000041946f in spdk_dma_malloc_socket (size=48, align=0, phys_addr=0x0, socket_id=-1) at env.c:58
#5 0x00000000004194c8 in spdk_dma_zmalloc_socket (size=48, align=0, phys_addr=0x0, socket_id=-1) at env.c:68
#6 0x000000000041954a in spdk_dma_zmalloc (size=48, align=0, phys_addr=0x0) at env.c:84
Is there some limitation for using spdk_dma_zmalloc?
________________________________
kinzent(a)hotmail.com
[-- Attachment #2: attachment.html --]
[-- Type: text/html, Size: 2568 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [SPDK] coredump in the memory malloc
@ 2017-12-21 3:46 Huang Frank
0 siblings, 0 replies; 2+ messages in thread
From: Huang Frank @ 2017-12-21 3:46 UTC (permalink / raw)
To: spdk
[-- Attachment #1: Type: text/plain, Size: 1669 bytes --]
Pls ignore it, it is my own probelm.
________________________________
kinzent(a)hotmail.com
From: Huang Frank<mailto:kinzent(a)hotmail.com>
Date: 2017-12-21 10:10
To: spdk<mailto:spdk(a)lists.01.org>
Subject: [SPDK] coredump in the memory malloc
hi,all
I meet a strange problem. I first alloacte a block for some variable, I want 0x400000 align. In the following ways:
spdk_dma_zmalloc(buf_size, 0x400000, &dma_addr);
It return 0x7ffff2600000.And then the next malloc get coredump. the address of elem in malloc_elem_free_list_insert equal to the prev malloc address.
(gdb) bt
#0 0x0000000000431b70 in malloc_elem_free_list_insert (elem=0x7ffff2600000)
at /home/xxx/spdk/dpdk/lib/librte_eal/common/malloc_elem.c:187
#1 0x0000000000431d94 in malloc_elem_alloc (elem=0x7ffff2600000, size=64, align=64, bound=0)
at /home/xxx/spdk/dpdk/lib/librte_eal/common/malloc_elem.c:249
#2 0x00000000004323fe in malloc_heap_alloc (heap=0x7ffff7fefa1c, type=0x0, size=64, flags=0, align=64, bound=0)
at /home/xxx/spdk/dpdk/lib/librte_eal/common/malloc_heap.c:168
#3 0x000000000043125f in rte_malloc_socket (type=0x0, size=48, align=0, socket_arg=-1)
at /home/xxx/spdk/dpdk/lib/librte_eal/common/rte_malloc.c:91
#4 0x000000000041946f in spdk_dma_malloc_socket (size=48, align=0, phys_addr=0x0, socket_id=-1) at env.c:58
#5 0x00000000004194c8 in spdk_dma_zmalloc_socket (size=48, align=0, phys_addr=0x0, socket_id=-1) at env.c:68
#6 0x000000000041954a in spdk_dma_zmalloc (size=48, align=0, phys_addr=0x0) at env.c:84
Is there some limitation for using spdk_dma_zmalloc?
________________________________
kinzent(a)hotmail.com
[-- Attachment #2: attachment.html --]
[-- Type: text/html, Size: 3664 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-12-21 3:46 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-12-21 2:10 [SPDK] coredump in the memory malloc Huang Frank
2017-12-21 3:46 Huang Frank
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.