[dpdk-dev] [PATCH RFC v2 00/12] lib/librte_vhost: vhost-user support

Xie, Huawei huawei.xie at intel.com
Mon Jan 26 08:24:35 CET 2015


> -----Original Message-----
> From: Linhaifeng [mailto:haifeng.lin at huawei.com]
> Sent: Friday, January 23, 2015 4:17 PM
> To: Xie, Huawei; dev at dpdk.org
> Cc: haifeng.lin at intel.com
> Subject: Re: [dpdk-dev] [PATCH RFC v2 00/12] lib/librte_vhost: vhost-user
> support
> 
> Hi, Xie
> 
> could you test vhost-user with follow numa node xml:
> <memory>2097152</memory>
>   <cpu>
>     <numa>
>       <cell id='0' cpus='0' memory='1048576' memAccess='shared'/>
>       <cell id='0' cpus='0' memory='1048576' memAccess='shared'/>
>     </numa>
>   </cpu>
> 
> 
> I cann't receive data from VM with above xml.
> 

1. 
I guess you want to configure numa memory for guest, and the xml should be:
<cell id='0' cpus='0' memory='1048576' memAccess='shared'/>
<cell id='1' cpus='1' memory='1048576' memAccess='shared'/>
, right?
Otherwise you are specifying the same memdev id, which cause qemu  fail to boot.

2.
>From the following output, qemu uses two hugepage files to map guest memory, \
while we receive two fds "pointing to the same hugepage file".
This should be a qemu bug.
I recall there is bug related to memory mapping with multiple node, right?
We will recommend customers not  to configure multiple memory node in guest until the bug is fixed in qemu.

# ls /proc/`pgrep qemu`/fd -l | grep huge
lrwx------. 1 root root 64 Jan 25 23:09 7 -> /mnt/huge/qemu_back_mem._objects_mem0.UfvViC (deleted)
lrwx------. 1 root root 64 Jan 25 23:09 8 -> /mnt/huge/qemu_back_mem._objects_mem1.kuX5tu (deleted)


# cat /proc/`pgrep qemu`/maps | grep huge
2aaac0000000-2aab00000000 rw-s 00000000 00:20 2674754                    /mnt/huge/qemu_back_mem._objects_mem0.UfvViC (deleted)
2aab00000000-2aab40000000 rw-s 00000000 00:20 2674755                    /mnt/huge/qemu_back_mem._objects_mem1.kuX5tu (deleted)

(gdb) p /x *memory.regions at memory.nregions
$21 = {{guest_phys_addr = 0xc0000, memory_size = 0x7ff40000, userspace_addr = 0x2aaac00c0000,
    mmap_offset = 0xc0000}, {guest_phys_addr = 0x0, memory_size = 0xa0000,
    userspace_addr = 0x2aaac0000000, mmap_offset = 0x0}}


#ls -l /proc/`pgrep vhost`/fd | grep qemu_back
lrwx------. 1 root root 64 Jan 25 23:18 22 -> /mnt/huge/qemu_back_mem._objects_mem0.UfvViC (deleted)
lrwx------. 1 root root 64 Jan 25 23:18 24 -> /mnt/huge/qemu_back_mem._objects_mem0.UfvViC (deleted)


More information about the dev mailing list