qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] virtio-scsi/blk dataplane and guest memory allocation


From: Paolo Bonzini
Subject: Re: [Qemu-devel] virtio-scsi/blk dataplane and guest memory allocation
Date: Thu, 21 Jan 2016 10:01:05 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0


On 20/01/2016 21:12, Roy Shterman wrote:
> Hi,
> 
> I have two questions,
> 
> First, I'm developing for Libiscsi and trying to work with virtio-scsi
> dataplane or even virtio-blk dataplane and it doesn't works well.
> 
> I'm working with latest qemu and latest Libiscsi in RedHat 7 libvirt
> package.
> 
> my iscsi xml part is : 
> 
> virtio-blk - 
> 
>     <disk type='network' device='lun'>
>       <driver name='qemu' type='raw'/>
>       <source protocol='iscsi' name='iqn.2001-04.com.r-dcs03-tgt-3/1'>
>         <host name='11.212.32.52' port='3260'/>
>       </source>
>       <target dev='vdb' bus='virtio'/>
>       <address type='pci' domain='0x0000' bus='0x00' slot='0x07'
> function='0x0'/>
>     </disk>
> 
> virtio-scsi - 
> 
>     <disk type='network' device='lun'>
>       <driver name='qemu' type='raw'/>
>       <source protocol='iscsi' name='iqn.2001-04.com.r-dcs03-tgt-1/1>
>         <host name='11.212.32.52' port='3260'/>
>       </source>
>       <target dev='sda' bus='scsi'/>
>       <address type='drive' controller='0' bus='0' target='0' unit='0'/>
>     </disk>
>     <controller type='scsi' index='0' model='virtio-scsi'>
>       <address type='pci' domain='0x0000' bus='0x00' slot='0x06'
> function='0x0'/>
>     </controller>

There is now support for dataplane in libvirt.  See
https://libvirt.org/formatdomain.html#elementsIOThreadsAllocation and
then you can add an iothread='NN' (NN is a number) to the <driver
name='qemu' type='raw'/> element.

> second thing, I'm trying to look for the code where QEMU allocate all
> guest memory (2 GB) in my case.

Start at memory_allocate_system_memory; ultimately you'll reach
qemu_anon_ram_alloc which is basically an mmap.

paolo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]