Re: [Qemu-devel] [PATCH v5 0/2] block: Reject negative values for throttling options

2016-01-20 Thread Alberto Garcia
On Wed 20 Jan 2016 05:21:19 AM CET, Fam Zheng wrote: > v5: Add valid value testing in iotests. [Berto] > Add details in commit message. [Markus] > Use "%lld" in format string. [Markus] > Fix ")" -> "]" in error message. [Kevin] > > Now the negative values are silently converted to a hu

Re: [Qemu-devel] [PATCH 07/10] pseries: Clean up error handling in spapr_rtas_register()

2016-01-20 Thread Alexey Kardashevskiy
On 01/20/2016 06:18 PM, Markus Armbruster wrote: Eric Blake writes: On 01/19/2016 05:21 PM, Alexey Kardashevskiy wrote: You could drop the redundant () while touching this, as in: Seriously? Why? I personally find it really annoying (but I stay silent) when people omit braces in cases lik

Re: [Qemu-devel] RFC: running the user interface in a thread ...

2016-01-20 Thread Gerd Hoffmann
Hi, > >> Related: Possibly we should move UIs to another *process* instead? > >> At least the ones which use a UI toolkit (i.e. sdl, gtk, cocoa). > > > > Is the worth the effort ? The majority of mgmt apps use spice/vnc which > > is already out of process. When you are using libvirt you are n

Re: [Qemu-devel] VFIO based vGPU(was Re: [Announcement] 2015-Q3 release of XenGT - a Mediated ...)

2016-01-20 Thread Jike Song
On 01/19/2016 03:05 AM, Alex Williamson wrote: > On Mon, 2016-01-18 at 16:56 +0800, Jike Song wrote: >> >> Would you elaborate a bit about 'iommu backends' here? Previously >> I thought that entire type1 will be duplicated. If not, what is supposed >> to add, a new vfio_dma_do_map? > > I don't kno

Re: [Qemu-devel] [PATCH v9 01/37] qobject: Document more shortcomings in our number handling

2016-01-20 Thread Markus Armbruster
Eric Blake writes: > We've already documented that our JSON parsing is locale dependent; > but we should also document that our JSON output has the same > problem. Additionally, JSON requires finite values (you have to > upgrade to JSON5 to get support for Inf or NaN), and our output > risks tru

Re: [Qemu-devel] VFIO based vGPU(was Re: [Announcement] 2015-Q3 release of XenGT - a Mediated ...)

2016-01-20 Thread Tian, Kevin
> From: Song, Jike > Sent: Wednesday, January 20, 2016 5:00 PM > >> BTW, that should be done in the 'bus' driver, right? > > > > I think you have some flexibility between the graphics driver and the > > vfio-vgpu driver in where this is done. If we want vfio-vgpu to be > > more generic, then vgpu

[Qemu-devel] [PATCH v4 2/2] cutils: add avx2 instruction optimization

2016-01-20 Thread Liang Li
buffer_find_nonzero_offset() is a hot function during live migration. Now it use SSE2 instructions for optimization. For platform supports AVX2 instructions, use AVX2 instructions for optimization can help to improve the performance about 30% comparing to SSE2. Zero page check can be faster with t

[Qemu-devel] [PATCH v4 1/2] configure: detect ifunc and avx2 attribute

2016-01-20 Thread Liang Li
Detect if the compiler can support the ifun and avx2, if so, set CONFIG_AVX2_OPT which will be used to turn on the avx2 instruction optimization. Signed-off-by: Liang Li --- configure | 20 1 file changed, 20 insertions(+) diff --git a/configure b/configure index 44ac9ab..b

[Qemu-devel] [PATCH v4 0/3] add avx2 instruction optimization

2016-01-20 Thread Liang Li
buffer_find_nonzero_offset() is a hot function during live migration. Now it use SSE2 instructions for optimization. For platform supports AVX2 instructions, use the AVX2 instructions for optimization can help to improve the performance about 30% comparing to SSE2. Zero page check can be faster wit

Re: [Qemu-devel] [PATCH v3 05/11] igd: TYPE_IGD_PASSTHROUGH_I440FX_PCI_DEVICE: call parent realize

2016-01-20 Thread Gerd Hoffmann
Hi, > > > > +i440fx_realize = k->realize; > > > > k->realize = igd_pt_i440fx_realize; > > > > ... because we are overriding it right here. > > Many device classes have a parent_realize field so they can keep > a pointer to the original realize function. It's better than a > static var

[Qemu-devel] [PATCH v4 0/2] add avx2 instruction optimization

2016-01-20 Thread Liang Li
buffer_find_nonzero_offset() is a hot function during live migration. Now it use SSE2 instructions for optimization. For platform supports AVX2 instructions, use the AVX2 instructions for optimization can help to improve the performance about 30% comparing to SSE2. Zero page check can be faster wit

Re: [Qemu-devel] [PATCH COLO-Frame v13 34/39] net/filter-buffer: Add default filter-buffer for each netdev

2016-01-20 Thread Jason Wang
On 01/20/2016 03:14 PM, Hailiang Zhang wrote: > On 2016/1/20 10:39, Jason Wang wrote: >> >> >> On 01/19/2016 04:39 PM, Hailiang Zhang wrote: >>> Hi Jason, >>> >>> Thanks for your review. >>> >>> On 2016/1/19 11:19, Jason Wang wrote: On 12/29/2015 03:09 PM, zhanghailiang wrote:

Re: [Qemu-devel] [PATCH] usb: check page select value while processing iTD

2016-01-20 Thread Gerd Hoffmann
On Mi, 2016-01-20 at 01:26 +0530, P J P wrote: > While processing isochronous transfer descriptors(iTD), the page > select(PG) field value could lead to an OOB read access. Add > check to avoid it. Added to usb patch queue. thanks, Gerd

Re: [Qemu-devel] [PATCH v17 0/9] Virtual Machine Generation ID

2016-01-20 Thread Igor Mammedov
On Tue, 19 Jan 2016 17:49:30 +0100 Laszlo Ersek wrote: > On 01/19/16 15:48, Igor Mammedov wrote: > > Here is SSDT ASL diff with vmgenid device present that > > Laszlo's asked for: > > > > @@ -135,6 +135,11 @@ DefinitionBlock ("tests/acpi-test-data/pc/SSDT.aml", > > "SSDT", 1, "BOCHS ", "BXPCS >

Re: [Qemu-devel] [RFC PATCH v2 00/10] Add colo-proxy based on netfilter

2016-01-20 Thread Jason Wang
On 01/20/2016 03:44 PM, Wen Congyang wrote: >> > >> > ... >> > -chardev socket,id=comparer0,host=ip_primary,port=X,server,nowait >> > -chardev socket,id=comparer1,host=ip_primary,port=Y,server,nowait >> > -chardev socket,id=mirrorer0,host=ip_primary,port=Z,server,nowait >> > -netdev tap,id=hn0 >

Re: [Qemu-devel] [PATCH COLO-Frame v13 34/39] net/filter-buffer: Add default filter-buffer for each netdev

2016-01-20 Thread Hailiang Zhang
On 2016/1/20 17:15, Jason Wang wrote: On 01/20/2016 03:14 PM, Hailiang Zhang wrote: On 2016/1/20 10:39, Jason Wang wrote: On 01/19/2016 04:39 PM, Hailiang Zhang wrote: Hi Jason, Thanks for your review. On 2016/1/19 11:19, Jason Wang wrote: On 12/29/2015 03:09 PM, zhanghailiang wrote:

Re: [Qemu-devel] [PATCH 07/10] pseries: Clean up error handling in spapr_rtas_register()

2016-01-20 Thread Markus Armbruster
Alexey Kardashevskiy writes: > On 01/20/2016 06:18 PM, Markus Armbruster wrote: >> Eric Blake writes: >> >>> On 01/19/2016 05:21 PM, Alexey Kardashevskiy wrote: >>> > You could drop the redundant () while touching this, as in: Seriously? Why? I personally find it really annoyi

Re: [Qemu-devel] [PATCH v3 0/3] Use QCryptoSecret for block device passwords

2016-01-20 Thread Daniel P. Berrange
On Tue, Jan 19, 2016 at 09:41:31PM +0100, Paolo Bonzini wrote: > > > On 19/01/2016 17:46, Daniel P. Berrange wrote: > > On Tue, Jan 19, 2016 at 05:32:35PM +0100, Paolo Bonzini wrote: > >> > >> > >> On 19/01/2016 14:51, Daniel P. Berrange wrote: > >>> This series was previously posted: > >>> > >>>

Re: [Qemu-devel] [PATCH v5 0/4] Extend TPM support with a QEMU-external TPM

2016-01-20 Thread Xu, Quan
Hagen, Thanks. Good news. :) -Quan > On January 20, 2016 at 5:24, wrote: > Hi Quan, > > I'm currently testing and reviewing. I also have some colleagues doing the > same > thing. > > So far: I haven't had any issues with it - this seems to work quite nicely. > > I will keep testing b

[Qemu-devel] [PATCH] qom, qmp, hmp, qapi: create qom-type-list for class properties

2016-01-20 Thread Valentin Rakush
This patch adds support for qom-type-list command that supposed to list object class properties. Will use this functionality further to implement x86_64 cpu properties. Additionally object_class_property_iterator_init function is implemented for consistency. Signed-off-by: Valentin Rakush Cc

Re: [Qemu-devel] [PATCH v4 2/2] cutils: add avx2 instruction optimization

2016-01-20 Thread Paolo Bonzini
On 20/01/2016 10:05, Liang Li wrote: > buffer_find_nonzero_offset() is a hot function during live migration. > Now it use SSE2 instructions for optimization. For platform supports > AVX2 instructions, use AVX2 instructions for optimization can help > to improve the performance about 30% comparing

Re: [Qemu-devel] [RFC PATCH v2 00/10] Add colo-proxy based on netfilter

2016-01-20 Thread Wen Congyang
On 01/20/2016 05:20 PM, Jason Wang wrote: > > > On 01/20/2016 03:44 PM, Wen Congyang wrote: ... -chardev socket,id=comparer0,host=ip_primary,port=X,server,nowait -chardev socket,id=comparer1,host=ip_primary,port=Y,server,nowait -chardev socket,id=mirrorer0,host=ip_primary

Re: [Qemu-devel] [PATCH v4 1/2] configure: detect ifunc and avx2 attribute

2016-01-20 Thread Paolo Bonzini
On 20/01/2016 10:05, Liang Li wrote: > Detect if the compiler can support the ifun and avx2, if so, set > CONFIG_AVX2_OPT which will be used to turn on the avx2 instruction > optimization. > > Signed-off-by: Liang Li > --- > configure | 20 > 1 file changed, 20 insertions(

Re: [Qemu-devel] [PATCH] migration: not send zero page header in ram bulk stage

2016-01-20 Thread Paolo Bonzini
On 19/01/2016 04:17, Li, Liang Z wrote: > > Paolo is right, for VM in destination, QEMU may write VM's memory before > > VM starts. > > So your assumption that "VM's RAM pages are initialized to zero" is > > incorrect. > > This patch will break LM. > > Which portion of the VM's RAM pages will b

Re: [Qemu-devel] [PATCH] migration: not send zero page header in ram bulk stage

2016-01-20 Thread Li, Liang Z
This patch will break LM. > > > > Which portion of the VM's RAM pages will be written by QEMU? Do you > know some exact information? > > I can't wait for Paolo's response. > > It is basically anything that uses rom_add_file_fixed or rom_add_blob_fixed > with an address that points into RAM. > > P

Re: [Qemu-devel] [RFC PATCH v2 00/10] Add colo-proxy based on netfilter

2016-01-20 Thread Wen Congyang
On 01/20/2016 02:54 PM, Jason Wang wrote: > > > On 01/20/2016 11:29 AM, Zhang Chen wrote: >> >>> Sure. >>> >>> Two main comments/suggestions: >>> >>> - TCP analysis is missed in current version, maybe you point a git tree >>> (or another version of RFC) to me for a better understanding of the >>>

Re: [Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-20 Thread Janosch Frank
On 01/18/2016 06:57 PM, Laszlo Ersek wrote: > On 01/18/16 17:31, Andrew Jones wrote: >> On Thu, Jan 14, 2016 at 05:24:23PM +0100, Laszlo Ersek wrote: >>> On 01/14/16 09:48, Janosch Frank wrote: The dump guest memory script for extracting a Linux core from a qemu core is currently limited

Re: [Qemu-devel] [RFC PATCH v2 00/10] Add colo-proxy based on netfilter

2016-01-20 Thread Jason Wang
On 01/20/2016 05:49 PM, Wen Congyang wrote: > On 01/20/2016 05:20 PM, Jason Wang wrote: >> >> On 01/20/2016 03:44 PM, Wen Congyang wrote: > ... > -chardev socket,id=comparer0,host=ip_primary,port=X,server,nowait > -chardev socket,id=comparer1,host=ip_primary,port=Y,server,nowait >

Re: [Qemu-devel] [PATCH v9 02/37] qapi: Avoid use of misnamed DO_UPCAST()

2016-01-20 Thread Markus Armbruster
Eric Blake writes: > The macro DO_UPCAST() is incorrectly named: it converts from a > parent class to a derived class (which is a downcast). Better, > and more consistent with some of the other qapi visitors, is > to use the container_of() macro through a to_FOO() helper. > > Our current definit

Re: [Qemu-devel] [PATCH 07/10] pseries: Clean up error handling in spapr_rtas_register()

2016-01-20 Thread Thomas Huth
On 20.01.2016 06:53, Alexey Kardashevskiy wrote: > On 01/20/2016 03:53 PM, Eric Blake wrote: >> On 01/19/2016 05:21 PM, Alexey Kardashevskiy wrote: >> You could drop the redundant () while touching this, as in: >>> >>> >>> Seriously? Why? I personally find it really annoying (but I stay silent

Re: [Qemu-devel] [RFC PATCH v2 00/10] Add colo-proxy based on netfilter

2016-01-20 Thread Jason Wang
On 01/20/2016 06:01 PM, Wen Congyang wrote: > On 01/20/2016 02:54 PM, Jason Wang wrote: >> >> On 01/20/2016 11:29 AM, Zhang Chen wrote: Sure. Two main comments/suggestions: - TCP analysis is missed in current version, maybe you point a git tree (or another version of

Re: [Qemu-devel] Regarding Intel IGD passthru support for QEMU/KVM

2016-01-20 Thread Gerd Hoffmann
Hi, > Based on the Intel IGD passthru support that has been added to > Qemu/Xen code base, is there any way to use/reuse the same logic > currently to have a successful passthru of an Intel IGD with Qemu/KVM > on a Linux host(Ubuntu x86_64) or will that require some more > work in addition to wh

Re: [Qemu-devel] [RFC PATCH v2 00/10] Add colo-proxy based on netfilter

2016-01-20 Thread Wen Congyang
On 01/20/2016 06:19 PM, Jason Wang wrote: > > > On 01/20/2016 06:01 PM, Wen Congyang wrote: >> On 01/20/2016 02:54 PM, Jason Wang wrote: >>> >>> On 01/20/2016 11:29 AM, Zhang Chen wrote: > Sure. > > Two main comments/suggestions: > > - TCP analysis is missed in current version

Re: [Qemu-devel] [PATCH] vmdk: Create streamOptimized as version 3

2016-01-20 Thread Kevin Wolf
Am 20.01.2016 um 05:28 hat Fam Zheng geschrieben: > On Thu, 09/17 10:55, Kevin Wolf wrote: > > Am 17.09.2015 um 07:04 hat Fam Zheng geschrieben: > > > VMware products accept only version 3 for streamOptimized, let's bump > > > the version. > > > > > > Reported-by: Radoslav Gerganov > > > Signed-o

Re: [Qemu-devel] [RFC PATCH v2 00/10] Add colo-proxy based on netfilter

2016-01-20 Thread Wen Congyang
On 01/20/2016 06:03 PM, Jason Wang wrote: > > > On 01/20/2016 05:49 PM, Wen Congyang wrote: >> On 01/20/2016 05:20 PM, Jason Wang wrote: >>> >>> On 01/20/2016 03:44 PM, Wen Congyang wrote: >> ... >> -chardev socket,id=comparer0,host=ip_primary,port=X,server,nowait >> -chardev socket,i

[Qemu-devel] cgroup blkio.weight or blkio.weight_device has no effect on qemu

2016-01-20 Thread lihuiba
Hi folks, Could you enlighten me how to achieve proportional IO sharing by using cgroup, instead of qemu's io-throttling? My qemu config is like: -drive file=$DISKFILe,if=none,format=qcow2,cache=none,aio=native -device virtio-blk-pci... Test command inside vm is like: dd if=/dev/vdc of=/de

Re: [Qemu-devel] [PATCH v4 1/2] configure: detect ifunc and avx2 attribute

2016-01-20 Thread Li, Liang Z
> On 20/01/2016 10:05, Liang Li wrote: > > Detect if the compiler can support the ifun and avx2, if so, set > > CONFIG_AVX2_OPT which will be used to turn on the avx2 instruction > > optimization. > > > > Signed-off-by: Liang Li > > --- > > configure | 20 > > 1 file changed,

Re: [Qemu-devel] [PATCH v2 31/34] scripts/kvm/kvm_stat: Fix rlimit for unprivileged users

2016-01-20 Thread Paolo Bonzini
On 11/01/2016 16:18, Janosch Frank wrote: > Setting the hard limit as a unprivileged user either returns an error > when it is higher than the current one or irreversibly sets it lower. > > Therefore we leave the hardlimit untouched as long as we don't need to > raise it as this needs CAP_SYS_RE

Re: [Qemu-devel] [PATCH v2 00/34] kvm_stat: Cleanup and fixup

2016-01-20 Thread Paolo Bonzini
On 11/01/2016 16:17, Janosch Frank wrote: > Kvm_stat is a very helpful script for checking the state of VMs, but > when I tried to introduce new features it broke every few lines. > > This patch series aims to make the script more readable and durable, > so future additions to it will break it l

Re: [Qemu-devel] [RFC 3/5] scripts/dump-guest-memory.py: Improve python 3 compatibility

2016-01-20 Thread Paolo Bonzini
On 14/01/2016 09:48, Janosch Frank wrote: > This commit does not make the script python 3 compatible, it is a > preparation that fixes the easy and common incompatibilities. > > Print is a function in python 3 and therefore needs braces around its > arguments. > > Range does not cast a gdb.Valu

Re: [Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-20 Thread Paolo Bonzini
On 20/01/2016 11:03, Janosch Frank wrote: > > In python 3: > 1/2 == 0.5 > 1//2 == 0 > but a // b == floor(a/b), i.e. a cast is made. > > Anyway, I got rid of the import with: > -(-len_desc // 4) I would change that to either: def ceil_div(a, b) return -(-a // b) ... ceil

Re: [Qemu-devel] [PATCH 1/1] nvdimm: disable balloon

2016-01-20 Thread Vladimir Sementsov-Ogievskiy
On 19.01.2016 11:53, Xiao Guangrong wrote: On 01/18/2016 07:42 PM, Denis V. Lunev wrote: From: Vladimir Sementsov-Ogievskiy NVDIMM for now is planned to use as a backing store for DAX filesystem in the guest and thus this memory is excluded from guest memory management and LRUs. In this c

Re: [Qemu-devel] [PATCH] qom, qmp, hmp, qapi: create qom-type-list for class properties

2016-01-20 Thread Daniel P. Berrange
On Wed, Jan 20, 2016 at 12:42:38PM +0300, Valentin Rakush wrote: > This patch adds support for qom-type-list command that supposed to list > object class properties. Will use this functionality further to implement > x86_64 cpu properties. > > Additionally object_class_property_iterator_init fun

Re: [Qemu-devel] [PATCH v2 0/2] qga: guest-set-user-password - added ability to create new user

2016-01-20 Thread Yuriy Pudgorodskiy
On 1/14/2016 5:46 PM, Daniel P. Berrange wrote: On Thu, Jan 14, 2016 at 05:22:39PM +0300, Denis V. Lunev wrote: On 01/14/2016 05:18 PM, Marc-André Lureau wrote: Hi On Wed, Jan 6, 2016 at 1:01 PM, Denis V. Lunev wrote: These patches add optional 'create' flag to guest-set-user-password comman

[Qemu-devel] [PULL v1 0/5] I/O channels fixes

2016-01-20 Thread Daniel P. Berrange
The following changes since commit 3db34bf64ab4f8797565dd8750003156c32b301d: Merge remote-tracking branch 'remotes/afaerber/tags/qom-devices-for-peter' into staging (2016-01-18 17:40:50 +) are available in the git repository at: git://github.com/berrange/qemu tags/pull-io-next-2016-01-2

[Qemu-devel] [PULL v1 3/5] io: some fixes to handling of /dev/null when running commands

2016-01-20 Thread Daniel P. Berrange
The /dev/null file handle was leaked in a couple of places. There is also the possibility that both readfd and writefd point to the same /dev/null file handle, so care must be taken not to close the same file handle twice. Reviewed-by: Paolo Bonzini Signed-off-by: Daniel P. Berrange --- io/chan

[Qemu-devel] [PULL v1 1/5] io: fix sign of errno value passed to error report

2016-01-20 Thread Daniel P. Berrange
When reporting the number of FDs has been exceeded, pass EINVAL to error_setg_errno, rather than -EINVAL. Signed-off-by: Daniel P. Berrange --- io/channel-socket.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/io/channel-socket.c b/io/channel-socket.c index 10a5b31..eaa411f

[Qemu-devel] [PULL v1 2/5] io: increment counter when killing off subcommand

2016-01-20 Thread Daniel P. Berrange
When killing the subcommand, it is intended to first send SIGTERM, then SIGKILL and only report an error if it still doesn't die after SIGKILL. The 'step' counter was not being incremented though, so the code never got past the SIGTERM stage. Signed-off-by: Daniel P. Berrange --- io/channel-comm

[Qemu-devel] [PULL v1 5/5] io: use memset instead of { 0 } for initializing array

2016-01-20 Thread Daniel P. Berrange
Some versions of GCC on OS-X complain about CMSG_SPACE not being constant size, which prevents use of { 0 } io/channel-socket.c: In function 'qio_channel_socket_writev': io/channel-socket.c:497:18: error: variable-sized object may not be initialized char control[CMSG_SPACE(sizeof(int) * SOCKE

[Qemu-devel] [PULL v1 4/5] io: fix description of @errp parameter initialization

2016-01-20 Thread Daniel P. Berrange
The "Error **errp" parameters must be NULL initialized not uninitialized. Signed-off-by: Daniel P. Berrange --- include/io/channel-command.h | 4 ++-- include/io/channel-socket.h | 14 +++--- include/io/channel-tls.h | 4 ++-- include/io/channel.h | 20 ++--

Re: [Qemu-devel] [PATCH] target-arm: Implement FPEXC32_EL2 system register

2016-01-20 Thread Edgar E. Iglesias
On Mon, Jan 18, 2016 at 03:53:34PM +, Peter Maydell wrote: > The AArch64 FPEXC32_EL2 system register is visible at EL2 and EL3, > and allows those exception levels to read and write the FPEXC > register for a lower exception level that is using AArch32. > > Signed-off-by: Peter Maydell Revie

Re: [Qemu-devel] [PATCH] target-arm: Implement FPEXC32_EL2 system register

2016-01-20 Thread Edgar E. Iglesias
On Mon, Jan 18, 2016 at 04:05:36PM +, Peter Maydell wrote: > Oops, got the qemu-arm email address wrong... Replied to the wrong email before... Reviewed-by: Edgar E. Iglesias > > On 18 January 2016 at 15:53, Peter Maydell wrote: > > The AArch64 FPEXC32_EL2 system register is visible at E

Re: [Qemu-devel] [PATCH] target-arm: Make various system registers visible to EL3

2016-01-20 Thread Edgar E. Iglesias
On Tue, Jan 19, 2016 at 06:23:22PM +, Peter Maydell wrote: > The AArch64 system registers DACR32_EL2, IFSR32_EL2, SPSR_IRQ, > SPSR_ABT, SPSR_UND and SPSR_FIQ are visible and fully functional from > EL3 even if the CPU has no EL2 (unlike some others which are RES0 > from EL3 in that configuratio

Re: [Qemu-devel] [PATCH v7] spec: add qcow2 bitmaps extension specification

2016-01-20 Thread Vladimir Sementsov-Ogievskiy
On 19.01.2016 20:48, Kevin Wolf wrote: Am 11.01.2016 um 14:05 hat Vladimir Sementsov-Ogievskiy geschrieben: The new feature for qcow2: storing bitmaps. This patch adds new header extension to qcow2 - Bitmaps Extension. It provides an ability to store virtual disk related bitmaps in a qcow2 imag

Re: [Qemu-devel] [PATCH v5 0/2] block: Reject negative values for throttling options

2016-01-20 Thread Kevin Wolf
Am 20.01.2016 um 05:21 hat Fam Zheng geschrieben: > v5: Add valid value testing in iotests. [Berto] > Add details in commit message. [Markus] > Use "%lld" in format string. [Markus] > Fix ")" -> "]" in error message. [Kevin] > > Now the negative values are silently converted to a huge

Re: [Qemu-devel] [RFC 3/5] scripts/dump-guest-memory.py: Improve python 3 compatibility

2016-01-20 Thread Janosch Frank
On 01/20/2016 12:18 PM, Paolo Bonzini wrote: > > > On 14/01/2016 09:48, Janosch Frank wrote: >> This commit does not make the script python 3 compatible, it is a >> preparation that fixes the easy and common incompatibilities. >> >> Print is a function in python 3 and therefore needs braces aroun

Re: [Qemu-devel] [PATCH v9 04/37] hmp: Improve use of qapi visitor

2016-01-20 Thread Markus Armbruster
Eric Blake writes: > Cache the visitor in a local variable instead of repeatedly > calling the accessor. Pass NULL for the visit_start_struct() > object (which matches the fact that we were already passing 0 > for the size argument, because we aren't using the visit to > allocate a qapi struct).

[Qemu-devel] [PATCH] sd: limit sd_cmd_type array index 'req.cmd'

2016-01-20 Thread P J P
From: Prasad J Pandit While processing standard SD commands, the 'req.cmd' value could lead to OOB read when used as an index into 'sd_cmd_type' array. Limit 'req.cmd' value to avoid such an access. Reported-by: Qinghao Tang Signed-off-by: Prasad J Pandit --- hw/sd/sd.c | 4 +++- 1 file chang

Re: [Qemu-devel] [PATCH v9 05/37] vl: Improve use of qapi visitor

2016-01-20 Thread Markus Armbruster
Eric Blake writes: > Cache the visitor in a local variable instead of repeatedly > calling the accessor. Pass NULL for the visit_start_struct() > object (which matches the fact that we were already passing 0 > for the size argument, because we aren't using the visit to > allocate a qapi struct).

[Qemu-devel] [PATCH v1 0/3] target-arm: Add a few more S2 MMU input checks

2016-01-20 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" This adds the inputsize < pamax check and also fixes the startlevel checks to apply to the 64bit translations. Comments welcome! Cheers, Edgar Edgar E. Iglesias (3): target-arm: Apply S2 MMU startlevel table size check to AArch64 target-arm: Make pamax an argument

[Qemu-devel] [PATCH v1 2/3] target-arm: Make pamax an argument to check_s2_startlevel

2016-01-20 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Make pamax an argument to check_s2_startlevel in preparation for future reuse. No functional change. Signed-off-by: Edgar E. Iglesias --- target-arm/helper.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/target-arm/helper.c b/target-arm/

[Qemu-devel] [PATCH v1 1/3] target-arm: Apply S2 MMU startlevel table size check to AArch64

2016-01-20 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" The S2 starting level table size check applies to both AArch32 and AArch64. Move it to common code. Signed-off-by: Edgar E. Iglesias --- target-arm/helper.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/target-arm/helper.c b/targ

[Qemu-devel] [PATCH v1 3/3] target-arm: Implement the S2 MMU inputsize < pamax check

2016-01-20 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Implement the inputsize < pamax check for Stage 2 translations. We have multiple choices for how to respond to errors and choose to fault. Signed-off-by: Edgar E. Iglesias --- target-arm/helper.c | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-)

Re: [Qemu-devel] [RFC 0/5] scripts/dump-guest-memory.py: Add multi-arch support

2016-01-20 Thread Markus Armbruster
Paolo Bonzini writes: > On 20/01/2016 11:03, Janosch Frank wrote: >> >> In python 3: >> 1/2 == 0.5 >> 1//2 == 0 >> but a // b == floor(a/b), i.e. a cast is made. >> >> Anyway, I got rid of the import with: >> -(-len_desc // 4) > > I would change that to either: > > def ceil_div(a, b) >

Re: [Qemu-devel] [PATCH v1 4/5] kvm/x86: Hyper-V VMBus hypercall userspace exit

2016-01-20 Thread Paolo Bonzini
On 14/01/2016 09:30, Pavel Fedin wrote: > Hello! > >> --- a/Documentation/virtual/kvm/api.txt >> +++ b/Documentation/virtual/kvm/api.txt >> @@ -3359,6 +3359,14 @@ Hyper-V SynIC state change. Notification is used to >> remap SynIC >> event/message pages and to enable/disable SynIC messages/eve

Re: [Qemu-devel] [PATCH] sd: limit sd_cmd_type array index 'req.cmd'

2016-01-20 Thread Peter Maydell
On 20 January 2016 at 13:14, P J P wrote: > From: Prasad J Pandit > > While processing standard SD commands, the 'req.cmd' value could > lead to OOB read when used as an index into 'sd_cmd_type' array. > Limit 'req.cmd' value to avoid such an access. > > Reported-by: Qinghao Tang > Signed-off-by

Re: [Qemu-devel] [PATCH] hw/arm/virt: Add always-on property to the virt board timer

2016-01-20 Thread Andrew Jones
On Tue, Jan 19, 2016 at 07:48:14PM +0100, Andrew Jones wrote: > On Tue, Jan 19, 2016 at 01:43:07PM +, Marc Zyngier wrote: > > >> On Tue, Jan 19, 2016 at 01:37:16PM +0100, Andrew Jones wrote: > > > OK, CCing him. One thing I see is that without this change we're > > > currently setting the clock

Re: [Qemu-devel] [PATCH v1] kvm/x86: Hyper-V tsc page setup

2016-01-20 Thread Paolo Bonzini
On 19/01/2016 08:48, Denis V. Lunev wrote: >> >> diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h >> index 6877b4d7e..93c9e25 100644 >> --- a/include/linux/kvm_host.h >> +++ b/include/linux/kvm_host.h >> @@ -145,6 +145,7 @@ static inline bool is_error_page(struct page *page) >>

Re: [Qemu-devel] [PATCH v1 0/5] KVM: Hyper-V VMBus hypercalls

2016-01-20 Thread Paolo Bonzini
On 19/01/2016 17:47, Paolo Bonzini wrote: >> > ping > I'll try to get to this and the others tomorrow. There are a few changes to make, and I'd like KY to ack the first patches, so I'll have to defer this to the next release. Paolo

Re: [Qemu-devel] [PATCH v3 ] doc: Introduce coding style for errors

2016-01-20 Thread Lluís Vilanova
Thomas Huth writes: > On 18.01.2016 21:26, Eric Blake wrote: >> On 01/15/2016 06:54 AM, Lluís Vilanova wrote: >>> Gives some general guidelines for reporting errors in QEMU. >>> >>> Signed-off-by: Lluís Vilanova >>> --- >>> HACKING | 36 >>> 1 file changed,

Re: [Qemu-devel] [PATCH v9 06/37] balloon: Improve use of qapi visitor

2016-01-20 Thread Markus Armbruster
Eric Blake writes: > Rework the control flow of balloon_stats_get_all() to make it > easier for a later patch to split visit_end_struct(). Also > switch to the uint64 visitor to match the data type. > > Signed-off-by: Eric Blake > Reviewed-by: Marc-André Lureau > > --- > v9: no change > v8: no

Re: [Qemu-devel] [PATCH v17 0/9] Virtual Machine Generation ID

2016-01-20 Thread Laszlo Ersek
On 01/20/16 10:18, Igor Mammedov wrote: > On Tue, 19 Jan 2016 17:49:30 +0100 > Laszlo Ersek wrote: > >> On 01/19/16 15:48, Igor Mammedov wrote: >>> Here is SSDT ASL diff with vmgenid device present that >>> Laszlo's asked for: >>> >>> @@ -135,6 +135,11 @@ DefinitionBlock ("tests/acpi-test-data/pc

Re: [Qemu-devel] qxl : no mouse cursor with sdl2/gtk UI

2016-01-20 Thread nicolas prochazka
hello, my libvirt definition xml file, if i change qxl by vga , mouse pointer is present , if i change vm seven to windows81 , mouse pointer is present ( using wddm qxl driver not the same as seven ) with windows seven vm, last qxl , mouse click is ok, but there'is no mouse pointer ( sound card, u

Re: [Qemu-devel] [PATCH] hw/arm/virt: Add always-on property to the virt board timer

2016-01-20 Thread Marc Zyngier
On 20/01/16 14:01, Andrew Jones wrote: > On Tue, Jan 19, 2016 at 07:48:14PM +0100, Andrew Jones wrote: >> On Tue, Jan 19, 2016 at 01:43:07PM +, Marc Zyngier wrote: > On Tue, Jan 19, 2016 at 01:37:16PM +0100, Andrew Jones wrote: OK, CCing him. One thing I see is that without this change

[Qemu-devel] cgroup blkio weight has no effect on qemu

2016-01-20 Thread 陈博
Hi folks, Could you enlighten me how to achieve proportional IO sharing by using cgroup, instead of qemu's io-throttling? My qemu config is like: -drive file=$DISKFILe,if=none,format=qcow2,cache=none,aio=native -device virtio-blk-pci... Test command inside vm is like: dd if=/dev/vdc of=/dev/

[Qemu-devel] cgroup blkio weight has no effect on qemu

2016-01-20 Thread Bob Chen
Sorry for disturbing by reply, don't know why I'm not able to send a new mail. Hi folks, Could you enlighten me how to achieve proportional IO sharing by using cgroup, instead of qemu's io-throttling? My qemu config is like: -drive file=$DISKFILe,if=none,format=qcow2,cac

[Qemu-devel] cgroup blkio weight has no effect on qemu

2016-01-20 Thread Bob Chen
Hi folks, Could you enlighten me how to achieve proportional IO sharing by using cgroup, instead of qemu's io-throttling? My qemu config is like: -drive file=$DISKFILe,if=none,format=qcow2,cache=none,aio=native -device virtio-blk-pci... Test command inside vm is like: dd if=/dev/vdc of=/d

[Qemu-devel] cgroup blkio weight has no effect on qemu

2016-01-20 Thread Bob Chen
Hi folks, Could you enlighten me how to achieve proportional IO sharing by using cgroup, instead of qemu's io-throttling? My qemu config is like: -drive file=$DISKFILe,if=none,format=qcow2,cache=none,aio=native -device virtio-blk-pci... Test command inside vm is like: dd if=/dev/vdc of=/d

Re: [Qemu-devel] [PATCH v14 7/8] Implement new driver for block replication

2016-01-20 Thread Changlong Xie
On 01/20/2016 08:04 AM, Eric Blake wrote: On 01/13/2016 02:18 AM, Changlong Xie wrote: From: Wen Congyang Signed-off-by: Wen Congyang Signed-off-by: zhanghailiang Signed-off-by: Gonglei Signed-off-by: Changlong Xie --- block/Makefile.objs | 1 + block/replication-comm.c

[Qemu-devel] cgroup blkio weight has no effect on qemu

2016-01-20 Thread Bob Chen
Hi folks, Could you enlighten me how to achieve proportional IO sharing by using cgroup, instead of qemu's io-throttling? My qemu config is like: -drive file=$DISKFILe,if=none,format=qcow2,cache=none,aio=native -device virtio-blk-pci... Test command inside vm is like: dd if=/dev/vdc of=/dev/null

Re: [Qemu-devel] RFC: running the user interface in a thread ...

2016-01-20 Thread Kevin Wolf
Am 19.01.2016 um 15:14 hat Gerd Hoffmann geschrieben: > Hi, > > > That does feel safer, if you can find an efficient way to do the graphics. > > A lot less code running with the privs of the qemu process. > > That is where it starts to become tricky ... > > On modern linux we can simply use dm

Re: [Qemu-devel] [PATCH v4 0/3] add avx2 instruction optimization

2016-01-20 Thread 陈博
Sorry for disturbing by reply, don't know why I'm not able to send a new mail. Hi folks, Could you enlighten me how to achieve proportional IO sharing by using cgroup, instead of qemu's io-throttling? My qemu config is like: -drive file=$DISKFILe,if=none,format=qcow2,cache=none,aio=native

[Qemu-devel] cgroup blkio weight has no effect on qemu

2016-01-20 Thread 陈博
Hi, Could you enlighten me how to achieve proportional IO sharing by using cgroup, instead of qemu's own io-throttling? My qemu config is like: -drive file=$DISKFILe,if=none,format=qcow2,cache=none,aio=native -device virtio-blk-pci... Test command inside vm is like: dd if=/dev/vdc of=/dev/nu

Re: [Qemu-devel] [PATCH v1 4/5] kvm/x86: Hyper-V VMBus hypercall userspace exit

2016-01-20 Thread Pavel Fedin
Hello! > Because, as the docs say, we don't want to do that. Where do they say this? I remember that "we want to use KVM_EXIT_IO or KVM_EXIT_MMIO for handling device I/O". In other words - we should not introduce anything that requires any other mechanism (e. g. hypercalls) to handle this. An

[Qemu-devel] cgroup blkio weight has no effect on qemu

2016-01-20 Thread Bob Chen
Hi folks, Could you enlighten me how to achieve proportional IO sharing by using cgroup, instead of qemu's io-throttling? My qemu config is like: -drive file=$DISKFILe,if=none,format=qcow2,cache=none,aio=native -device virtio-blk-pci... Test command inside vm is like: dd if=/dev/vdc of=/dev/

Re: [Qemu-devel] [PATCH v5 0/4] Extend TPM support with a QEMU-external TPM

2016-01-20 Thread Hagen Lauer
Hi Quan, I'm currently testing and reviewing. I also have some colleagues doing the same thing. So far: I haven't had any issues with it - this seems to work quite nicely. I will keep testing but I don't really expect any functional hiccups. Best Regards, Hagen -Original Message- From

[Qemu-devel] cgroup blkio.weight is not working for qemu

2016-01-20 Thread Bob Chen
Hi folks, Could you enlighten me how to achieve proportional IO sharing by using cgroup, instead of qemu's io-throttling? My qemu config is like: -drive file=$DISKFILe,if=none,format=qcow2,cache=none,aio=native -device virtio-blk-pci... Test command inside vm is like: dd if=/dev/vdc of=/dev/null

Re: [Qemu-devel] [PATCH v1] kvm/x86: Hyper-V tsc page setup

2016-01-20 Thread Denis V. Lunev
On 01/20/2016 05:05 PM, Paolo Bonzini wrote: On 19/01/2016 08:48, Denis V. Lunev wrote: diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index 6877b4d7e..93c9e25 100644 --- a/include/linux/kvm_host.h +++ b/include/linux/kvm_host.h @@ -145,6 +145,7 @@ static inline bool is_error_

Re: [Qemu-devel] cgroup blkio weight has no effect on qemu

2016-01-20 Thread Daniel P. Berrange
On Wed, Jan 20, 2016 at 06:41:16PM +0800, 陈博 wrote: Sending the question once is enough, and reply with a 'ping' message if no one has answered after a few days waiting for response. There is no need to send the same mail 11 times over. Regards, Daniel -- |: http://berrange.com -o-http:

Re: [Qemu-devel] [PATCH v1] kvm/x86: Hyper-V tsc page setup

2016-01-20 Thread Denis V. Lunev
On 01/20/2016 05:52 PM, Roman Kagan wrote: On Wed, Jan 20, 2016 at 05:44:49PM +0300, Denis V. Lunev wrote: On 01/20/2016 05:05 PM, Paolo Bonzini wrote: On 19/01/2016 08:48, Denis V. Lunev wrote: diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index 6877b4d7e..93c9e25 100644 --

Re: [Qemu-devel] [PATCH v2] pc: allow raising low memory via max-ram-below-4g option

2016-01-20 Thread Gerd Hoffmann
Hi, > > + *qemu -M pc,max-ram-below-4g=2G -m 4G -> 2048M low, 2048M high > I assume max-ram-below-4g > 3.5G was unsupported before, and we > are breaking compatibility intentionally. max-ram-below-4g did only reduce memory, so max-ram-below-4g > 3.5G (or max-ram-below-4g > 3G with

Re: [Qemu-devel] [PATCH v1] kvm/x86: Hyper-V tsc page setup

2016-01-20 Thread Andrey Smetanin
On 01/20/2016 05:05 PM, Paolo Bonzini wrote: On 19/01/2016 08:48, Denis V. Lunev wrote: diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index 6877b4d7e..93c9e25 100644 --- a/include/linux/kvm_host.h +++ b/include/linux/kvm_host.h @@ -145,6 +145,7 @@ static inline bool is_er

Re: [Qemu-devel] [PATCH v5 0/4] Extend TPM support with a QEMU-external TPM

2016-01-20 Thread Daniel P. Berrange
On Mon, Jan 04, 2016 at 10:23:18AM -0500, Stefan Berger wrote: > The following series of patches extends TPM support with an > external TPM that offers a Linux CUSE (character device in userspace) > interface. This TPM lets each VM access its own private vTPM. What is the backing store for this vT

Re: [Qemu-devel] [PATCH v5 1/4] Provide support for the CUSE TPM

2016-01-20 Thread Daniel P. Berrange
On Mon, Jan 04, 2016 at 10:23:19AM -0500, Stefan Berger wrote: > From: Stefan Berger > > Rather than integrating TPM functionality into QEMU directly > using the TPM emulation of libtpms, we now integrate an external > emulated TPM device. This device is expected to implement a Linux > CUSE inter

Re: [Qemu-devel] [PATCH v1 2/5] drivers/hv: Move VMBus hypercall codes into Hyper-V UAPI header

2016-01-20 Thread KY Srinivasan
> -Original Message- > From: Andrey Smetanin [mailto:asmeta...@virtuozzo.com] > Sent: Tuesday, January 12, 2016 2:51 AM > To: k...@vger.kernel.org > Cc: Gleb Natapov ; Paolo Bonzini > ; Joerg Roedel ; KY Srinivasan > ; Haiyang Zhang ; Roman > Kagan ; Denis V. Lunev ; qemu- > de...@nongnu.

Re: [Qemu-devel] [PATCH] hw/arm/virt: Add always-on property to the virt board timer

2016-01-20 Thread Andrew Jones
On Wed, Jan 20, 2016 at 02:28:05PM +, Marc Zyngier wrote: > On 20/01/16 14:01, Andrew Jones wrote: > > On Tue, Jan 19, 2016 at 07:48:14PM +0100, Andrew Jones wrote: > >> On Tue, Jan 19, 2016 at 01:43:07PM +, Marc Zyngier wrote: > > On Tue, Jan 19, 2016 at 01:37:16PM +0100, Andrew Jones

Re: [Qemu-devel] [PATCH v1] kvm/x86: Hyper-V tsc page setup

2016-01-20 Thread Roman Kagan
On Wed, Jan 20, 2016 at 05:44:49PM +0300, Denis V. Lunev wrote: > On 01/20/2016 05:05 PM, Paolo Bonzini wrote: > > > >On 19/01/2016 08:48, Denis V. Lunev wrote: > >>>diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h > >>>index 6877b4d7e..93c9e25 100644 > >>>--- a/include/linux/kvm_ho

Re: [Qemu-devel] [PATCH v3] vfio/common: Check iova with limit not with size

2016-01-20 Thread Pierre Morel
On 01/12/2016 07:16 PM, Alex Williamson wrote: On Tue, 2016-01-12 at 16:11 +0100, Pierre Morel wrote: In vfio_listener_region_add(), we try to validate that the region is not zero sized and hasn't overflowed the addresses space. But the calculation uses the size of the region instead of using

Re: [Qemu-devel] [PATCH v9 07/37] qapi: Improve generated event use of qapi visitor

2016-01-20 Thread Markus Armbruster
Eric Blake writes: > All other successful clients of visit_start_struct() were paired > with an unconditional visit_end_struct(); but the generated > code for events was relying on qmp_output_visitor_cleanup() to > work on an incomplete visit. Disgusting, isn't it? :) >

Re: [Qemu-devel] [PATCH v1 4/5] kvm/x86: Hyper-V VMBus hypercall userspace exit

2016-01-20 Thread 'Roman Kagan'
On Wed, Jan 20, 2016 at 02:59:08PM +0100, Paolo Bonzini wrote: > >> --- a/Documentation/virtual/kvm/api.txt > >> +++ b/Documentation/virtual/kvm/api.txt > >> @@ -3359,6 +3359,14 @@ Hyper-V SynIC state change. Notification is used to > >> remap SynIC > >> event/message pages and to enable/disable

  1   2   3   >