Re: [Qemu-devel] [PATCH v4 2/3] usb-hid: Add high speed mouse configuration

2014-09-26 Thread Gerd Hoffmann
On Do, 2014-09-25 at 17:38 -0400, Jan Vesely wrote: > v2: add usb_mouse_properties > use macros for bmAttributes > v3: rebase > v4: rebase patch looks good, the only thing missing is the compat property, to make sure qemu machine types for 2.1 & older continue to have usb1 mouse+kbd by default

Re: [Qemu-devel] [PATCH v2 1/3] usb-hid: Move descriptor decision to usb-hid initfn

2014-09-26 Thread Gonglei (Arei)
> From: Gerd Hoffmann [mailto:kra...@redhat.com] > Sent: Friday, September 26, 2014 2:53 PM > To: Gonglei (Arei) > Cc: Jan Vesely; QEMU > Subject: Re: [Qemu-devel] [PATCH v2 1/3] usb-hid: Move descriptor decision to > usb-hid initfn > > Hi, > > > > -static void usb_hid_initfn(USBDevice *dev, in

Re: [Qemu-devel] [PATCH 3/8] vga: Separate LE and BE conversion functions

2014-09-26 Thread Gerd Hoffmann
> > > @@ -1572,19 +1585,19 @@ static void vga_draw_graphic(VGACommonState *s, > > > int full_update) > > bits = 8; > > break; > > case 15: > > -v = VGA_DRAW_LINE15; > > -bits = 16; > > +v = big_endian_fb ? VGA_DRAW_LINE15_BE :

[Qemu-devel] [PATCH] exec: don't exit if failed to preallocate memory for memory-backend-file

2014-09-26 Thread Hu Tao
When using monitor command object_add to add a memory backend file but failed to preallocate memory for it, qemu exits silently. So a unexpected user input, e.g. a too large size of memory-backend-file can crash the guest. This is the case of -mem-prealloc, not memory-backend-file,prealloc=y. The

Re: [Qemu-devel] [PATCH 2/2] iohandler: Add Linux implementation of iohandler GSource

2014-09-26 Thread Paolo Bonzini
Il 26/09/2014 03:23, Fam Zheng ha scritto: > > Also, as an extra optimization perhaps you can make a second list with > > iohandlers that were modified or have a read_poll handler, and only call > > iohandler_get_events on that one. > > Sounds good, but I need to benchmark it to tell :) > > There

[Qemu-devel] [PATCH] ui/input: correct the release order of combined keys

2014-09-26 Thread Amos Kong
Commit 2e377f17 wrongly overturned the release order of combined keys, it caused some Windows guests can't be paniced by "virsh send-key KEY_RIGHTCTRL KEY_SCROLLLOCK KEY_SCROLLLOCK" The press event order should be different with release order. Signed-off-by: Amos Kong --- ui/input-legacy.c | 9

[Qemu-devel] [PATCH] input: fix send-key monitor command release event ordering

2014-09-26 Thread Gerd Hoffmann
commit 2e377f1730d06deafb3e3ef6cf88792de4a6f4df changed the ordering of the release events as side effect. Some guests are not happy with that and don't recognise ctrl-alt-del any more. This patch restores the old last-pressed first-released behavior. Cc: Amos Kong Signed-off-by: Gerd Hoffmann

[Qemu-devel] [PATCH v7 00/11] target-arm: Parts of the AArch64 EL2/3 exception model

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Hi, This is a second round of AArch64 EL2/3 patches working on the exception model. Among other things adding HVC/SMC, interrupt routing to EL2/3 and Virtual IRQs/FIQs. The VIRQ/VFIQ support only adds the external signal delivery method. This conflicts slightly with th

[Qemu-devel] [PATCH v7 01/11] target-arm: Add HCR_EL2

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Reviewed-by: Greg Bellows Reviewed-by: Peter Maydell Signed-off-by: Edgar E. Iglesias --- target-arm/cpu.h| 36 target-arm/helper.c | 34 ++ 2 files changed, 70 insertions(+) diff --git a/targe

[Qemu-devel] [PATCH 3/3] os-posix: report error message when lock file failed

2014-09-26 Thread arei.gonglei
From: Gonglei It will cause that create vm failed When manager tool is killed forcibly (kill -9 libvirtd_pid), the file not was unlink, and unlock. It's better that report the error message for users. Signed-off-by: Huangweidong Signed-off-by: Gonglei --- os-posix.c | 2 ++ 1 file changed, 2

[Qemu-devel] [PATCH v7 02/11] target-arm: Add SCR_EL3

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Signed-off-by: Edgar E. Iglesias --- target-arm/cpu.h| 19 ++- target-arm/helper.c | 35 +-- 2 files changed, 51 insertions(+), 3 deletions(-) diff --git a/target-arm/cpu.h b/target-arm/cpu.h index 36507f9..c69d471 1

[Qemu-devel] [PATCH 0/3] os-posix: improve the error message printing

2014-09-26 Thread arei.gonglei
From: Gonglei The patches mainly improve the error message printing. And adjust coding style of os-posix.c. Daemonize the QEMU process after initialization, QEMU will not detach from standard IO until it is ready to receive connections on any of its devices. So, using fprintf print error. Cc: E

[Qemu-devel] [PATCH v7 04/11] target-arm: Break out exception masking to a separate func

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Reviewed-by: Greg Bellows Signed-off-by: Edgar E. Iglesias --- cpu-exec.c | 5 ++--- target-arm/cpu.h | 15 +++ 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/cpu-exec.c b/cpu-exec.c index bd93165..d017588 100644 --- a/cpu-exec.c ++

[Qemu-devel] [PATCH 1/3] os-posix: change tab to space avoid violating coding style

2014-09-26 Thread arei.gonglei
From: Gonglei Cc: Eric Blake Signed-off-by: Gonglei --- os-posix.c | 79 +- 1 file changed, 42 insertions(+), 37 deletions(-) diff --git a/os-posix.c b/os-posix.c index cb2a7f7..f0564ef 100644 --- a/os-posix.c +++ b/os-posix.c @@ -20

[Qemu-devel] [PATCH 2/3] os-posix: remove confused errno

2014-09-26 Thread arei.gonglei
From: Gonglei If we get inside the 'else if (status == 1)' conditional, then we know that read() succeeded, and therefore errno is unspecified. Printing strerror(errno) on a random value is not helpful. Cc: Eric Blake Signed-off-by: Gonglei --- os-posix.c | 2 +- 1 file changed, 1 insertion(+

[Qemu-devel] [PATCH v7 06/11] target-arm: A64: Correct updates to FAR and ESR on exceptions

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Not all exception types update both FAR and ESR. Reviewed-by: Alex Bennée Reviewed-by: Greg Bellows Signed-off-by: Edgar E. Iglesias --- target-arm/helper-a64.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/target-arm/helper-a64.c b/targ

[Qemu-devel] [PATCH v7 05/11] target-arm: Don't take interrupts targeting lower ELs

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Reviewed-by: Alex Bennée Reviewed-by: Greg Bellows Reviewed-by: Peter Maydell Signed-off-by: Edgar E. Iglesias --- target-arm/cpu.h | 7 +++ 1 file changed, 7 insertions(+) diff --git a/target-arm/cpu.h b/target-arm/cpu.h index a5e8e0d..7f8a410 100644 --- a/tar

[Qemu-devel] [PATCH v7 10/11] target-arm: Add IRQ and FIQ routing to EL2 and 3

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Reviewed-by: Greg Bellows Signed-off-by: Edgar E. Iglesias --- target-arm/cpu.h| 10 ++ target-arm/helper.c | 17 + 2 files changed, 27 insertions(+) diff --git a/target-arm/cpu.h b/target-arm/cpu.h index 4070a38..00b3ad4 100644 --- a/targ

[Qemu-devel] [PATCH v7 07/11] target-arm: A64: Emulate the HVC insn

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Signed-off-by: Edgar E. Iglesias --- target-arm/cpu.h | 1 + target-arm/helper-a64.c| 1 + target-arm/helper.c| 20 +++- target-arm/helper.h| 1 + target-arm/internals.h | 6 ++ target-arm/op_helper.c | 31 +

[Qemu-devel] [PATCH v7 03/11] target-arm: A64: Refactor aarch64_cpu_do_interrupt

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Introduce new_el and new_mode in preparation for future patches that add support for taking exceptions to and from EL2 and 3. No functional change. Reviewed-by: Peter Maydell Signed-off-by: Edgar E. Iglesias --- target-arm/cpu.h| 7 +++ target-arm/helper

[Qemu-devel] [PATCH v7 11/11] target-arm: Add support for VIRQ and VFIQ

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" This only implements the external delivery method via the GIC. Acked-by: Greg Bellows Signed-off-by: Edgar E. Iglesias --- cpu-exec.c | 12 target-arm/cpu.c| 35 --- target-arm/cpu.h| 35 ++

[Qemu-devel] [PATCH v7 08/11] target-arm: Add a Hypervisor Trap exception type

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Signed-off-by: Edgar E. Iglesias --- target-arm/cpu.h| 1 + target-arm/helper-a64.c | 1 + target-arm/helper.c | 1 + target-arm/internals.h | 1 + 4 files changed, 4 insertions(+) diff --git a/target-arm/cpu.h b/target-arm/cpu.h index b553f3d..ef933e8 10

Re: [Qemu-devel] [PATCH] kvm/valgrind: dont mark memory as initialized

2014-09-26 Thread Paolo Bonzini
Il 25/09/2014 21:07, Christian Borntraeger ha scritto: > since commit 7dda5dc82a77 ("migration: initialize RAM to zero") the > guest memory is defined zero. No need to call valgrind on guest memory. > This reverts commit 62fe83318d2f ("qemu: Use valgrind annotations to > mark kvm guest memory as de

[Qemu-devel] [PATCH v7 09/11] target-arm: A64: Emulate the SMC insn

2014-09-26 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Signed-off-by: Edgar E. Iglesias --- target-arm/cpu.h | 1 + target-arm/helper-a64.c| 1 + target-arm/helper.c| 3 +++ target-arm/helper.h| 1 + target-arm/internals.h | 6 ++ target-arm/op_helper.c | 26 ++

Re: [Qemu-devel] [PATCH v6 08/10] target-arm: A64: Emulate the SMC insn

2014-09-26 Thread Edgar E. Iglesias
On Fri, Sep 26, 2014 at 12:43:40AM +0100, Peter Maydell wrote: > On 26 September 2014 00:31, Edgar E. Iglesias > wrote: > > On Fri, Sep 26, 2014 at 12:17:59AM +0100, Peter Maydell wrote: > >> Oh, yes, that's the trap enable bit. In that case we shouldn't > >> be using EXCP_SMC: this isn't routing

Re: [Qemu-devel] [PATCH 0/3] os-posix: improve the error message printing

2014-09-26 Thread Paolo Bonzini
Il 26/09/2014 10:14, arei.gong...@huawei.com ha scritto: > From: Gonglei > > The patches mainly improve the error message printing. > And adjust coding style of os-posix.c. > > Daemonize the QEMU process after initialization, QEMU will not detach from > standard IO until it is ready to receive c

Re: [Qemu-devel] [PATCH] qemu-ga: added windows support for 'guest-network-get-interfaces'

2014-09-26 Thread Markus Armbruster
Kenth Andersson writes: > This is my first patch so I hope I got everything right. Here, this sentence is part of the commit message. It should go... > Signed-off-by: Kenth Andersson > --- ... here, below the '---' divider. As a happy Windows ignoramus, I can't do a real review, but I'll tr

Re: [Qemu-devel] [PATCH 0/3] os-posix: improve the error message printing

2014-09-26 Thread Gonglei (Arei)
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > Subject: Re: [PATCH 0/3] os-posix: improve the error message printing > > Il 26/09/2014 10:14, arei.gong...@huawei.com ha scritto: > > From: Gonglei > > > > The patches mainly improve the error message printing. > > And adjust coding style of o

Re: [Qemu-devel] [PATCH v2] qga: Rewrite code where using readdir_r

2014-09-26 Thread zhanghailiang
Hi, Ping...,plus;) This is a bug fix. Thanks, zhanghailiang On 2014/9/19 11:09, zhanghailiang wrote: If readdir_r fails, error_setg_errno will reference the freed pointer *dirpath*. Moreover, readdir_r may cause a buffer overflow, using readdir instead. Signed-off-by: zhanghailiang --- v2

Re: [Qemu-devel] [PATCH v2] vl: Adjust the place of calling mlockall to speedup VM's startup

2014-09-26 Thread zhanghailiang
Hi, This has been reviewed, Will anyone pick this up?;) Thanks, zhanghailiang On 2014/9/23 18:42, zhanghailiang wrote: If we configure mlock=on and memory policy=bind at the same time, It will consume lots of time for system to treat with memory, especially when call mbind behind mlockall. Adj

[Qemu-devel] [PATCH] ui/input: fix event emitting of repeated combined keys

2014-09-26 Thread Amos Kong
Currently we emit press events of combined keys first, then emit release events by reverse order. But it doesn't match with physical keyboard if the keys contain continued & repeated keys. For example, (qemu) sendkey a-b-b Current emited events: (actually the second 'presse b' and 'release b' can

[Qemu-devel] [PATCH RESEND 5/9] virtio-serial: use aliases instead of duplicate qdev properties

2014-09-26 Thread arei.gonglei
From: Gonglei virtio-serial-{pci, s390, ccw} all duplicate the qdev properties of their VirtIOSerial child. This approach does not work well with string or pointer properties since we must be careful about leaking or double-freeing them. Use the QOM alias property to forward property accesses to

[Qemu-devel] [PATCH RESEND 2/9] virtio: fix virtio-net child refcount in transports

2014-09-26 Thread arei.gonglei
From: Gonglei object_initialize() leaves the object with a refcount of 1. object_property_add_child() adds its own reference which is dropped again when the property is deleted. The upshot of this is that we always have a refcount >= 1. Upon hot unplug the virtio-net child is not finalized! Dr

[Qemu-devel] [PATCH RESEND 9/9] virtio-balloon: fix virtio-balloon child refcount in transports

2014-09-26 Thread arei.gonglei
From: Gonglei object_initialize() leaves the object with a refcount of 1. object_property_add_child() adds its own reference which is dropped again when the property is deleted. The upshot of this is that we always have a refcount >= 1. Upon hot unplug the virtio-balloon child is not finalized!

[Qemu-devel] [PATCH] target-xtensa: avoid duplicate timer interrupt delivery

2014-09-26 Thread Max Filippov
Timer interrupt should be raised at the same cycle when CCOUNT equals CCOMPARE. As cycles are counted in batches, timer interrupt is sent every time CCOMPARE lies in the interval [old CCOUNT, new CCOUNT]. This is wrong, because when new CCOUNT equals CCOMPARE interrupt is sent twice, once for the u

[Qemu-devel] [PATCH RESEND 3/9] virtio/vhost scsi: use aliases instead of duplicate qdev properties

2014-09-26 Thread arei.gonglei
From: Gonglei {virtio, vhost}-scsi-{pci, s390, ccw} all duplicate the qdev properties of their VirtIOSCSI/VHostSCSI child. This approach does not work well with string or pointer properties since we must be careful about leaking or double-freeing them. Use the QOM alias property to forward prope

[Qemu-devel] [PATCH RESEND 0/9] virtio: fix virtio child recount in transports

2014-09-26 Thread arei.gonglei
From: Gonglei virtio-$device-{pci, s390, ccw} all duplicate the qdev properties of their virtio child. This approach does not work well with string or pointer properties since we must be careful about leaking or double-freeing them. Use the QOM alias property to forward property accesses to the

[Qemu-devel] [PATCH RESEND 7/9] virtio-rng: use aliases instead of duplicate qdev properties

2014-09-26 Thread arei.gonglei
From: Gonglei virtio-rng-{pci, s390, ccw} all duplicate the qdev properties of their VirtIORNG child. This approach does not work well with string or pointer properties since we must be careful about leaking or double-freeing them. Use the QOM alias property to forward property accesses to the V

[Qemu-devel] [PATCH RESEND 4/9] virtio/vhost-scsi: fix virtio-scsi/vhost-scsi child refcount in transports

2014-09-26 Thread arei.gonglei
From: Gonglei object_initialize() leaves the object with a refcount of 1. object_property_add_child() adds its own reference which is dropped again when the property is deleted. The upshot of this is that we always have a refcount >= 1. Upon hot unplug the virtio-scsi/vhost-scsi child is not fi

[Qemu-devel] [PATCH RESEND 1/9] virtio-net: use aliases instead of duplicate qdev properties

2014-09-26 Thread arei.gonglei
From: Gonglei virtio-net-pci, virtio-net-s390, and virtio-net-ccw all duplicate the qdev properties of their VirtIONet child. This approach does not work well with string or pointer properties since we must be careful about leaking or double-freeing them. Use the QOM alias property to forward pr

[Qemu-devel] [PATCH RESEND 8/9] virtio-rng: fix virtio-rng child refcount in transports

2014-09-26 Thread arei.gonglei
From: Gonglei object_initialize() leaves the object with a refcount of 1. object_property_add_child() adds its own reference which is dropped again when the property is deleted. The upshot of this is that we always have a refcount >= 1. Upon hot unplug the virtio-rng child is not finalized! Dr

[Qemu-devel] [PATCH RESEND 6/9] virtio-serial: fix virtio-serial child refcount in transports

2014-09-26 Thread arei.gonglei
From: Gonglei object_initialize() leaves the object with a refcount of 1. object_property_add_child() adds its own reference which is dropped again when the property is deleted. The upshot of this is that we always have a refcount >= 1. Upon hot unplug the virtio-serial child is not finalized!

[Qemu-devel] [RFC PATCH v0 2/2] target-ppc: Fix an invalid free in opcode table handling code.

2014-09-26 Thread Bharata B Rao
Opcode table has direct, indirect and double indirect handlers, but ppc_cpu_unrealizefn() frees direct handlers which are never allocated and never frees double indirect handlers. Signed-off-by: Bharata B Rao --- target-ppc/translate_init.c | 19 --- 1 file changed, 16 insertions

[Qemu-devel] [RFC PATCH v0 1/2] target-ppc: Use macros in opcodes table handling code

2014-09-26 Thread Bharata B Rao
Define and use macros instead of direct numbers wherever possible in ppc opcodes table handling code. This doesn't change any code functionality. Signed-off-by: Bharata B Rao --- target-ppc/cpu.h| 3 ++- target-ppc/translate_init.c | 24 ++-- 2 files changed, 16

[Qemu-devel] [RFC PATCH v0 0/2] target-ppc: Fix an invalid free

2014-09-26 Thread Bharata B Rao
g_free() in target-ppc/translate_init.c:ppc_cpu_unrealizefn() can fail due to invalid pointer being passed to it. Fix this along with a cleanup. I have never seen ppc_cpu_unrealizefn() getting called for sPAPR guests, but I ran into this issue when I was adding unrealize call from the CPU hot remo

Re: [Qemu-devel] [PACTH v4 5/6] target-arm: add emulation of PSCI calls for system emulation

2014-09-26 Thread Peter Maydell
On 10 September 2014 08:02, Ard Biesheuvel wrote: > From: Rob Herring > > Add support for handling PSCI calls in system emulation. Both version > 0.1 and 0.2 of the PSCI spec are supported. Platforms can enable support > by setting the "psci-conduit" QOM property on the cpus to SMC or HVC > emula

Re: [Qemu-devel] [PATCH v4 08/19] qapi: Better error messages for bad expressions

2014-09-26 Thread Markus Armbruster
Kevin Wolf writes: > Am 24.09.2014 um 09:34 hat Markus Armbruster geschrieben: >> Eric Blake writes: >> >> > On 09/23/2014 08:56 AM, Markus Armbruster wrote: >> >> Eric Blake writes: >> >>> Add check_keys to cover these situations, and update testcases to >> >>> match. A couple other tests (e

[Qemu-devel] [PATCH v2] pc-dimm: Don't check dimm->node when there is non-NUMA config

2014-09-26 Thread zhanghailiang
It should not break memory hotplug feature if there is non-NUMA option. This patch would also allow to use pc-dimm as replacement for initial memory for non-NUMA configs. Note: After this patch, the memory hotplug can work normally for Linux guest OS when there is non-NUMA option and NUMA option.

Re: [Qemu-devel] [PULL v3 14/15] virtio-pci: fix migration for pci bus master

2014-09-26 Thread Nikunj A Dadhania
Hi Alex/Peter, The below patch is already been picked in master and ppc-next and has broken pseries booting from virtio-blk device Greg Kurz writes: > On Tue, 23 Sep 2014 07:26:32 +0300 > "Michael S. Tsirkin" wrote: > >> > >> > This commit prevents pseries to boot. SLOF complains with the fol

Re: [Qemu-devel] [PATCH v4 08/19] qapi: Better error messages for bad expressions

2014-09-26 Thread Kevin Wolf
Am 26.09.2014 um 11:15 hat Markus Armbruster geschrieben: > Kevin Wolf writes: > > > Am 24.09.2014 um 09:34 hat Markus Armbruster geschrieben: > >> Eric Blake writes: > >> > >> > On 09/23/2014 08:56 AM, Markus Armbruster wrote: > >> >> Eric Blake writes: > >> >>> Add check_keys to cover these

Re: [Qemu-devel] [PATCH v4 13/19] qapi: More rigourous checking of types

2014-09-26 Thread Markus Armbruster
Eric Blake writes: > Now that we know every expression is valid with regards to > its keys, we can add further tests that those keys refer to > valid types. With this patch, all references to a type (the > 'data': of command, type, union, and event, and the 'returns': > of command) must resolve

[Qemu-devel] [PATCH v2 00/36] complete conversion to hotplug-handler API

2014-09-26 Thread Igor Mammedov
Changes since v1: * added usb-uas test * drop hotplug check in bus_add_child() * make SCSI & USB bus as default HotplugHandler * fixed dummy HBA hot(un)plug * fixed hotunplug on s390x * prevent hotplug of non hotpluggable devices -- Series unifies different hotplug mechanisms to a rece

[Qemu-devel] [PATCH v2 04/36] test: virtio-rng: check if hot-plug/unplug works

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v2: moved code duplication into library --- tests/Makefile | 2 +- tests/virtio-rng-test.c | 10 ++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/tests/Makefile b/tests/Makefile index f5de29c..e72c78c 100644 --- a/tests/Makefil

[Qemu-devel] [PATCH v2 10/36] test: usb: usb-storage hotplug test

2014-09-26 Thread Igor Mammedov
usb-storage is different from usual usb devices in that it uses child SCSI bus for underlying storage. That patch verifies that SCSI bus is hotpluggable for hotplug operation wouldn't succeed without it. Signed-off-by: Igor Mammedov --- tests/usb-hcd-uhci-test.c | 31

[Qemu-devel] [PATCH v2 01/36] test: virtio-scsi: check if hot-plug/unplug works

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov Reviewed-by: Paolo Bonzini --- tests/virtio-scsi-test.c | 29 + 1 file changed, 29 insertions(+) diff --git a/tests/virtio-scsi-test.c b/tests/virtio-scsi-test.c index 3230908..41f9602 100644 --- a/tests/virtio-scsi-test.c +++ b/tests/vir

[Qemu-devel] [PATCH v2 02/36] test: virtio-serial: check if hot-plug/unplug works

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov Reviewed-by: Paolo Bonzini --- tests/virtio-serial-test.c | 27 +++ 1 file changed, 27 insertions(+) diff --git a/tests/virtio-serial-test.c b/tests/virtio-serial-test.c index e743875..bf030a6 100644 --- a/tests/virtio-serial-test.c +++ b/tes

[Qemu-devel] [PATCH v2 13/36] qdev: do not allow to instantiate non hotpluggable device with device_add

2014-09-26 Thread Igor Mammedov
It will allow explicitly mark device as not hotpluggable and avoid its creation with following error at realize time and destroying it afterwards anyway. Instead of it will error out even before instance of device is created. Signed-off-by: Igor Mammedov --- qdev-monitor.c | 3 ++- 1 file change

[Qemu-devel] [PATCH v2 03/36] test: libqos: add qpci_plug_device_test() and qpci_unplug_acpi_device_test()

2014-09-26 Thread Igor Mammedov
functions will be used for testing hot(un)plug of PCI devices. Signed-off-by: Igor Mammedov --- tests/libqos/pci-pc.c | 49 + tests/libqos/pci.h| 3 +++ 2 files changed, 52 insertions(+) diff --git a/tests/libqos/pci-pc.c b/tests/libqos/pci-p

[Qemu-devel] [PATCH v2 05/36] test: virtio-net: check if hot-plug/unplug works

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v2: moved code duplication into library --- tests/Makefile | 2 +- tests/virtio-net-test.c | 10 ++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/tests/Makefile b/tests/Makefile index e72c78c..f2ee9d8 100644 --- a/tests/Makefil

[Qemu-devel] [PATCH v2 06/36] test: virtio-blk: check if hot-plug/unplug works

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v2: moved code duplication into library --- tests/virtio-blk-test.c | 49 ++--- 1 file changed, 38 insertions(+), 11 deletions(-) diff --git a/tests/virtio-blk-test.c b/tests/virtio-blk-test.c index 588666c..d93224b 1

[Qemu-devel] [PATCH v2 09/36] test: usb: generic usb device hotplug

2014-09-26 Thread Igor Mammedov
use usb-tablet as a hotplugged usb device. Signed-off-by: Igor Mammedov --- Since I'm not familiar with internals of USB, for OHCI/XHCI test doesn't verify that usb device has been hotplugged except of checking for error after hotplug. So port checks similar to that of ehci/uhci, left as excercis

[Qemu-devel] [PATCH v2 18/36] qdev: drop hotplug check from bus_add_child()

2014-09-26 Thread Igor Mammedov
check is too restrictive and does not allow to add childs to just created bus during hotplug when the bus is part of composite device. Removing check from bus_add_child() doesn't affect devices creatable with device_add/del commands since they have a similar builtin checks and patch will allow to

[Qemu-devel] [PATCH v2 14/36] qdev: HotplugHandler: rename unplug callback to unplug_request

2014-09-26 Thread Igor Mammedov
'HotplugHandler.unplug' callback is currently used as async call to issue unplug request for device that implements it. Renaming 'unplug' callback to 'unplug_request' should help to avoid confusion about what callback does and would allow to introduce 'unplug' callback that would perform actual dev

[Qemu-devel] [PATCH v2 07/36] test: usb: move uhci port test code to libqos/usb.c

2014-09-26 Thread Igor Mammedov
Move code necessary for testing uhci port into library so it could be used by other USB tests. Signed-off-by: Igor Mammedov --- tests/Makefile| 3 ++- tests/libqos/usb.c| 37 + tests/libqos/usb.h| 14 ++ tests/usb-hcd-e

Re: [Qemu-devel] [PATCH v1 3/3] monitor: add del completion for peripheral device

2014-09-26 Thread Andreas Färber
Hi, Am 18.09.2014 um 09:53 schrieb Zhu Guihua: > Add peripheral_device_del_completion() to let peripheral device del completion > be possible. > > Signed-off-by: Zhu Guihua > --- > monitor.c | 24 > 1 file changed, 24 insertions(+) > > diff --git a/monitor.c b/monitor.

[Qemu-devel] [PATCH v2 12/36] access BusState.allow_hotplug using wraper qbus_is_hotpluggable()

2014-09-26 Thread Igor Mammedov
it would allow transparently switch detection if Bus is hotpluggable from allow_hotplug field to hotplug_handler link and drop allow_hotplug field once all users are converted to hotplug handler API. Signed-off-by: Igor Mammedov Reviewed-by: Paolo Bonzini --- hw/core/qdev.c | 6 +++---

[Qemu-devel] [PATCH v2 15/36] qdev: HotplugHandler: provide unplug callback

2014-09-26 Thread Igor Mammedov
it to be called for actual device removal and will allow to separate request and removal handling phases of x86-CPU devices and also it's a handler to be called for synchronously removable devices. Signed-off-by: Igor Mammedov Reviewed-by: Paolo Bonzini --- unplug handling for bus-less devices w

[Qemu-devel] [PATCH v2 08/36] test: usb: add port test to uhci unit test

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v2: split patch from code movment for ehci test --- tests/Makefile| 2 +- tests/usb-hcd-uhci-test.c | 18 -- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/tests/Makefile b/tests/Makefile index f1eff1b..2374926 10064

[Qemu-devel] [PATCH v2 23/36] s390x: drop not used allow_hotplug in event-facility

2014-09-26 Thread Igor Mammedov
s390-sclp-event-facility creates s390-sclp-events-bus and immeadiatly sets its allow_hotplug field to 0, which is NOP since it's already 0 by default. Also since BUS is not hotpluggable, it's not possible to call SCLP_EVENT{ DeviceClass.unplug } callback from qdev_unplug() making this unreachable

[Qemu-devel] [PATCH v2 20/36] virtio-pci: drop BusState.allow_hotplug

2014-09-26 Thread Igor Mammedov
virtio-pci-bus is an internal object of composite virtio-pci device and it doesn't participate in -device/device_add hotplug flow, and since it's not required by bus_add_child() that BUS must be hotpluggable to be able to add child at runtime, it's possible to drop not needed 'allow_hotplug' field.

[Qemu-devel] [PATCH v2 16/36] qdev: add simple/generic unplug callback for HotplugHandler

2014-09-26 Thread Igor Mammedov
it will be used in shallow conversion from legacy hotplug mechanism and eventually replace all the uses of old mechanism DeviceClass->unplug = qdev_simple_unplug_cb() Signed-off-by: Igor Mammedov Reviewed-by: Paolo Bonzini --- hw/core/qdev.c | 5 + include/hw/qdev-core.h | 2 ++ 2 f

[Qemu-devel] [PATCH v2 25/36] s390x: convert virtio-ccw to hotplug handler API

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v2: fix not working unplug --- hw/s390x/virtio-ccw.c | 17 + 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/hw/s390x/virtio-ccw.c b/hw/s390x/virtio-ccw.c index 33a1d86..09d9500 100644 --- a/hw/s390x/virtio-ccw.c +++ b/hw/s390x/virti

[Qemu-devel] [PATCH v2 24/36] s390x: convert s390-virtio to hotplug handler API

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v2: fix not working unplug --- hw/s390x/s390-virtio-bus.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/hw/s390x/s390-virtio-bus.c b/hw/s390x/s390-virtio-bus.c index 6b6fb61..b575d6c 100644 --- a/hw/s390x/s390-virtio-bus.c +++ b

[Qemu-devel] [PATCH v2 22/36] virtio-mmio: drop useless bus->allow_hotplug = 0

2014-09-26 Thread Igor Mammedov
Bus by default is not hotpluggable. virtio-mmio-bus and its parent types do not set allow_hotplug anywhere explicitly, so remove not needed field access and wrapper along with it. Signed-off-by: Igor Mammedov Reviewed-by: Paolo Bonzini --- hw/virtio/virtio-mmio.c | 17 ++--- 1 file

[Qemu-devel] [PATCH v2 17/36] qdev: add wrapper to set BUS as HotplugHandler

2014-09-26 Thread Igor Mammedov
to be used for conversion of SCSI and USB devices, and would allow to make every HBA/USB host switch to HotplugHandler API without touching each controller explicitly. Signed-off-by: Igor Mammedov --- hw/core/qdev.c | 19 +++ include/hw/qdev-core.h | 11 --- 2 fil

[Qemu-devel] [PATCH v2 11/36] test: usb: usb-uas hotplug test

2014-09-26 Thread Igor Mammedov
checks that it's possible to hotplug usb-uas HBA and then if it's possible to hot(un)plug scsi-disk to it. Thest basically covers hot(un)plug on dummy HBAs without means of hot(un)plug notification of the guest. Signed-off-by: Igor Mammedov --- tests/usb-hcd-xhci-test.c | 61

[Qemu-devel] [PATCH v2 26/36] scsi: set SCSI BUS itself as default HotplugHandler

2014-09-26 Thread Igor Mammedov
That would allow to handle SCSI device unplug on HBAs without dedicated hot(un)plug handlers and avoid making such HBAs explicitly hotpluggable. Signed-off-by: Igor Mammedov --- hw/scsi/scsi-bus.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/hw/scsi/scsi-bus.c b/hw/

[Qemu-devel] [PATCH v2 21/36] virtio-serial: convert to hotplug-handler API

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov Reviewed-by: Paolo Bonzini --- hw/char/virtio-serial-bus.c | 20 +++- 1 file changed, 15 insertions(+), 5 deletions(-) diff --git a/hw/char/virtio-serial-bus.c b/hw/char/virtio-serial-bus.c index 3931085..c6870f1 100644 --- a/hw/char/virtio-serial-bu

[Qemu-devel] [PATCH v2 35/36] qdev: drop legacy hotplug fields/methods

2014-09-26 Thread Igor Mammedov
It removes not needed anymore BusState.allow_hotplug field and DeviceClass.unplug callback. Signed-off-by: Igor Mammedov Reviewed-by: Paolo Bonzini --- hw/core/qdev.c | 16 +++- include/hw/qdev-core.h | 5 + 2 files changed, 4 insertions(+), 17 deletions(-) diff --git

[Qemu-devel] [PATCH v2 32/36] usb-storage: drop not needed "allow_hotplug = 0"

2014-09-26 Thread Igor Mammedov
Drop useless hack that disables hotplug on bus, after backend storage was added to it, by setting "allow_hotplug = 0". Even if bus is hotpluggable, It won't be possible to add another SCSI device to bus since its realize will fail early with error "no free target" in scsi_qdev_realize() method. Si

Re: [Qemu-devel] [PATCH v1 2/3] qom: export object_property_is_child()

2014-09-26 Thread Andreas Färber
Am 18.09.2014 um 09:53 schrieb Zhu Guihua: > Export object_property_is_child() to let it be invoked in other places. > > Signed-off-by: Zhu Guihua > --- > include/qom/object.h | 1 + > qom/object.c | 2 +- > 2 files changed, 2 insertions(+), 1 deletion(-) > > diff --git a/include/qom/ob

[Qemu-devel] [PATCH v2 31/36] usb-bot: drop not needed "allow_hotplug = 0"

2014-09-26 Thread Igor Mammedov
Drop useless hack that disables hotplug on bus by setting "allow_hotplug = 0". Even if bus is hotpluggable, It won't be possible to add another SCSI device to bus since its realize will fail early with error "no free target" in scsi_qdev_realize() method. Signed-off-by: Igor Mammedov --- hw/usb/

[Qemu-devel] [PATCH v2 30/36] usb-bot: mark device as non hotpluggable

2014-09-26 Thread Igor Mammedov
usb-bot creates SCSI bus and immediately makes it non hotpluggable which was making not possible to hotplug usb-bot since QEMU would abort at bus_add_child(scsi-hd) time when usb-bot is realized. Mark usb-bot as not hotpluggable so that attempt to hotplug it would error out even before it gets to

[Qemu-devel] [PATCH v2 34/36] usb: convert usb devices to hotplug handler API

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v2: replace making each host as HotplugHandler with making USB BUS a HotplugHandler. That greatly reduces LOC needed for convertion. --- hw/usb/bus.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/hw/usb/bus.c b/hw/usb/bus.c ind

[Qemu-devel] [PATCH v2 33/36] usb: convert usb-ccid to hotplug handler API

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- hw/usb/dev-smartcard-reader.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/hw/usb/dev-smartcard-reader.c b/hw/usb/dev-smartcard-reader.c index d37ed02..78ce681 100644 --- a/hw/usb/dev-smartcard-reader.c +++ b/hw/usb/dev-smartcard-read

[Qemu-devel] [PATCH v2 36/36] qdev: HotplugHandler: add support for unplugging BUS-less devices

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v2: merged in Paolo's suggestion to reduce indentation in patch --- hw/core/qdev.c | 61 -- 1 file changed, 34 insertions(+), 27 deletions(-) diff --git a/hw/core/qdev.c b/hw/core/qdev.c index bc45a59..215

[Qemu-devel] [PATCH v2 19/36] target-i386: ICC bus: drop BusState.allow_hotplug

2014-09-26 Thread Igor Mammedov
since bus_add_child() no longer cares if BUS is hotpluggable or not, there is no need in setting allow_hotplug field. Signed-off-by: Igor Mammedov --- hw/cpu/icc_bus.c | 8 1 file changed, 8 deletions(-) diff --git a/hw/cpu/icc_bus.c b/hw/cpu/icc_bus.c index 7f44c59..9575fd6 100644 ---

[Qemu-devel] [PATCH v2 28/36] scsi: convert virtio-scsi HBA to hotplug handler API

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v2: * enforce virtio-scsi specific hotplug-handler --- hw/scsi/virtio-scsi.c | 30 -- 1 file changed, 20 insertions(+), 10 deletions(-) diff --git a/hw/scsi/virtio-scsi.c b/hw/scsi/virtio-scsi.c index 86aba88..a08e253 100644 --- a/hw

[Qemu-devel] [PATCH v2 27/36] scsi: convert pvscsi HBA to hotplug handler API

2014-09-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- not tested since it's broken, i.e. QEMU hangs in BIOS with pvscsi device present on CLI v2: * enforce pvscsi specific hotplug-handler --- hw/scsi/vmw_pvscsi.c | 26 ++ 1 file changed, 18 insertions(+), 8 deletions(-) diff --git a/hw/scsi

[Qemu-devel] [PATCH v2 29/36] scsi: cleanup not used anymore SCSIBusInfo{hotplug, hot_unplug} fields

2014-09-26 Thread Igor Mammedov
SCSI subsytem was converted to hotplug handler API and doesn't use SCSIBusInfo{hotplug, hot_unplug} fields and related callbacks anymore. Signed-off-by: Igor Mammedov Reviewed-by: Paolo Bonzini --- hw/scsi/scsi-bus.c | 16 include/hw/scsi/scsi.h | 2 -- 2 files changed, 18

Re: [Qemu-devel] [PACTH v4 3/6] target-arm: add hvc and smc exception emulation handling infrastructure

2014-09-26 Thread Peter Maydell
On 10 September 2014 08:02, Ard Biesheuvel wrote: > From: Rob Herring > > Add the infrastructure to handle and emulate hvc and smc exceptions. > This will enable emulation of things such as PSCI calls. This commit > does not change the behavior and will exit with unknown exception. > > Signed-off

Re: [Qemu-devel] [Xen-devel] [PATCH 2/2] xenfb: Add comment documentation

2014-09-26 Thread Owen Smith
> -Original Message- > From: David Vrabel > Sent: 22 September 2014 11:16 > To: Owen Smith; xen-de...@lists.xen.org > Cc: Stefano Stabellini; qemu-devel@nongnu.org; Ian Campbell > Subject: Re: [Xen-devel] [PATCH 2/2] xenfb: Add comment documentation > > On 22/09/14 10:04, Owen smith wrote:

[Qemu-devel] [PATCH v2] ui/input: fix event emitting of repeated combined keys

2014-09-26 Thread Amos Kong
Currently we emit press events of combined keys first, then emit release events by reverse order. But it doesn't match with physical keyboard if the keys contain continued & repeated keys. For example, (qemu) sendkey a-b-b Current emited events: (actually the second 'presse b' and 'release b' can

Re: [Qemu-devel] [PULL 3/3] s390x/css: catch ccw sequence errors

2014-09-26 Thread Andreas Färber
Christian, Conny, Am 23.09.2014 um 14:14 schrieb Christian Borntraeger: > From: Cornelia Huck > > We must not allow chains of more than 255 ccws without data transfer. > > Reviewed-by: David Hildenbrand > Signed-off-by: Cornelia Huck > Signed-off-by: Jens Freimann > Signed-off-by: Christian

Re: [Qemu-devel] [PATCH] main-loop.c: Handle SIGINT, SIGHUP and SIGTERM synchronously

2014-09-26 Thread Alex Bennée
Peter Maydell writes: > Add the termination signals SIGINT, SIGHUP and SIGTERM to the > list of signals which we handle synchronously via a signalfd. > This avoids a race condition where if we took the SIGTERM > in the middle of qemu_shutdown_requested: > int r = shutdown_requested; > [SIGTE

Re: [Qemu-devel] [PATCH v2] ui/input: fix event emitting of repeated combined keys

2014-09-26 Thread Gerd Hoffmann
On Fr, 2014-09-26 at 18:23 +0800, Amos Kong wrote: > Currently we emit press events of combined keys first, then emit > release events by reverse order. But it doesn't match with physical > keyboard if the keys contain continued & repeated keys. > > For example, (qemu) sendkey a-b-b Hmm, somehow

[Qemu-devel] [Bug 1307225] Re: Running a virtual machine on a Haswell system produces machine check events

2014-09-26 Thread Tobias-leupold
So, at least, this does not seem to be something to worry about. But anyways, why does it only happen if a virtual machine is executed? -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1307225 Title:

Re: [Qemu-devel] [PULL 2/3] s390x/css: support format-0 ccws

2014-09-26 Thread Andreas Färber
Am 23.09.2014 um 14:14 schrieb Christian Borntraeger: > From: Cornelia Huck > > Add support for format-0 ccws in channel programs. As a format-1 ccw > contains the same information as format-0 ccws, only supporting larger > addresses, simply convert every ccw to format-1 as we walk the chain. >

Re: [Qemu-devel] [PATCH 00/23] qom hooks to clean up cpu_exec

2014-09-26 Thread Peter Maydell
On 13 September 2014 17:45, Richard Henderson wrote: > Prompted by trying to review Martin's ARM exception vs gdb > problems, let's clean up cpu_exec so that it's almost readable. > > After the 23 patches, there's one (interesting) ifdef left. > That is, i386 redefining CPU_INTERRUPT_RESET as CPU_

Re: [Qemu-devel] [PATCH v2 00/36] complete conversion to hotplug-handler API

2014-09-26 Thread Cornelia Huck
On Fri, 26 Sep 2014 09:28:05 + Igor Mammedov wrote: > Changes since v1: > * added usb-uas test > * drop hotplug check in bus_add_child() > * make SCSI & USB bus as default HotplugHandler > * fixed dummy HBA hot(un)plug > * fixed hotunplug on s390x > * prevent hotplug of non hotplu

  1   2   3   4   >