[Qemu-devel] [PATCH 3/3] fixup! Add qtest for vhost-user

2014-06-12 Thread Nikolay Nikolaev
Replace 'memory-file' with 'memory-backend-file'. Signed-off-by: Nikolay Nikolaev --- tests/vhost-user-test.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/vhost-user-test.c b/tests/vhost-user-test.c index 486e56b..7c826b4 100644 --- a/tests/vhost-user-test.c +++ b

[Qemu-devel] [PATCH 1/3] fixup! Add vhost-user as a vhost backend.

2014-06-12 Thread Nikolay Nikolaev
Replace 'memory-file' with 'memory-backend-file'. Signed-off-by: Nikolay Nikolaev --- hw/virtio/vhost-user.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/virtio/vhost-user.c b/hw/virtio/vhost-user.c index 3244ef8..0df6a93 100644 --- a/hw/virtio/vhost-user.c +++ b/hw/

[Qemu-devel] [PATCH 2/3] fixup! Add the vhost-user netdev backend to the command line

2014-06-12 Thread Nikolay Nikolaev
Replace 'memory-file' with 'memory-backend-file'. Signed-off-by: Nikolay Nikolaev --- qemu-options.hx |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qemu-options.hx b/qemu-options.hx index 1ad2528..ab06df1 100644 --- a/qemu-options.hx +++ b/qemu-options.hx @@ -1802,7 +180

[Qemu-devel] [PATCH 0/3] Fixups for vhost-user

2014-06-12 Thread Nikolay Nikolaev
This is a series of fixups that replace 'memory-file' with 'memory-backend-file'. This is the object type used in the newest (since v4) NUMA series for the file based host memory backend. The patches are against git://git.kernel.org/pub/scm/virt/kvm/mst/qemu.git branch 'vhost'. Tested after reba

[Qemu-devel] [QEMU guest agent] How to transfer file from host to guest and do some operation on that

2014-06-12 Thread Puneet Bakshi
Adding subject. On Thu, Jun 12, 2014 at 8:15 PM, Puneet Bakshi wrote: > Hi, > > I want to be able to install RPM packages (available in host system at > some path) to the online guest VM and want this facility to be available as > a tool. > > I am thinking of having a gemu guest agent (qemu-ga)

Re: [Qemu-devel] [Qemu-discuss] How can we install RPMs in guest VM from host machine using QEMU guest agents

2014-06-12 Thread Puneet Bakshi
Including qemu-devel also. I have a project environment where guest VMs are getting created and destroyed based on some (irrelevant) parameters (these guest VMs are instantiated with QEMU guest agent running and with any possible changes in that). There is a module in host which is controlling all

[Qemu-devel] (no subject)

2014-06-12 Thread Puneet Bakshi
Hi, I want to be able to install RPM packages (available in host system at some path) to the online guest VM and want this facility to be available as a tool. I am thinking of having a gemu guest agent (qemu-ga) running inside guest VM. I did not find any available command ("virsh qemu-agent-comm

[Qemu-devel] [PATCH] memory: Don't call memory_region_update_coalesced_range if nothing changed

2014-06-12 Thread Fam Zheng
With huge number of PCI devices in the system (for example, 200 virtio-blk-pci), this unconditional call can slow down emulation of irrelevant PCI operations drastically, such as a BAR update on a device that has no coalescing region. So avoid it. Signed-off-by: Fam Zheng --- memory.c | 7 ++

Re: [Qemu-devel] Using virtio for inter-VM communication

2014-06-12 Thread Jan Kiszka
On 2014-06-13 02:47, Rusty Russell wrote: > Jan Kiszka writes: >> On 2014-06-12 04:27, Rusty Russell wrote: >>> Henning Schild writes: >>> It was also never implemented, and remains a thought experiment. >>> However, implementing it in lguest should be fairly easy. >> >> The reason why a trusted

Re: [Qemu-devel] [RFC] pc: Register machine classes directly instead of using QEMUMachine

2014-06-12 Thread Eduardo Habkost
On Thu, Jun 12, 2014 at 10:37:29AM +0200, Igor Mammedov wrote: > On Thu, 12 Jun 2014 11:13:49 +0300 > "Michael S. Tsirkin" wrote: > > > On Thu, Jun 12, 2014 at 03:22:24AM -0300, Eduardo Habkost wrote: > > > This is a (mostly) blind and mechanical conversion of the PC QEMUMachine > > > definitions

Re: [Qemu-devel] [PATCH v7 3/4] s390x: Migrate to new NMI interface

2014-06-12 Thread Cornelia Huck
On Fri, 13 Jun 2014 13:36:58 +1000 Alexey Kardashevskiy wrote: > This implements an NMI interface for s390 and s390-ccw machines. > > This removes #ifdef s390 branch in qmp_inject_nmi so new s390's > nmi_monitor_handler() callback is going to be used for NMI. > > Since nmi_monitor_handler()-cal

Re: [Qemu-devel] [PATCH v7 2/4] s390x: Convert QEMUMachine to MachineClass

2014-06-12 Thread Cornelia Huck
On Fri, 13 Jun 2014 13:36:57 +1000 Alexey Kardashevskiy wrote: > This converts s390-virtio and s390-ccw-virtio machines to QOM MachineClass. > This brings ability to add interfaces to the machine classes. The first > interface for addition will be NMI. > > The patch is mechanical so no change in

Re: [Qemu-devel] [Xen-devel] [RFC PATCH V2 1/2] xen: pass kernel initrd to qemu

2014-06-12 Thread Chun Yan Liu
>>> On 6/12/2014 at 05:58 PM, in message <1402567125.9177.26.ca...@kazak.uk.xensource.com>, Ian Campbell wrote: > On Wed, 2014-06-04 at 15:34 +0800, Chunyan Liu wrote: > > xen side patch to support xen HVM direct kernel boot: > > support 'kernel', 'ramdisk', 'root', 'extra' in HVM config file

Re: [Qemu-devel] [PATCH v7 2/4] s390x: Convert QEMUMachine to MachineClass

2014-06-12 Thread Alexey Kardashevskiy
btw only this patche from the series got "[Qemu-devel]" in the subject line and others did not, why? Lists of emails are almost the same, only Eric Blake got kicked off (added him manually to this email cc:), is that connected? :) Why is that subject thing happening? Thanks. On 06/13/2014 01:36

[Qemu-devel] [PATCH v7 0/4] cpus: Add generic "nmi" monitor command support

2014-06-12 Thread Alexey Kardashevskiy
This adds an "nmi" monitor command handler per CPUs. x86, s390 and ppc CPUS are supported. Please comment. Thanks. Changes: v7: * fixed typenames, function names, copyrights * s390x QOM'ed for later addition of the NMI interface * Since none of x86 machines is QOM'ed, postpone migration to new i

[Qemu-devel] [PATCH v7 3/4] s390x: Migrate to new NMI interface

2014-06-12 Thread Alexey Kardashevskiy
This implements an NMI interface for s390 and s390-ccw machines. This removes #ifdef s390 branch in qmp_inject_nmi so new s390's nmi_monitor_handler() callback is going to be used for NMI. Since nmi_monitor_handler()-calling code is platform independent, CPUState::cpu_index is used instead of S39

[Qemu-devel] [PATCH v7 2/4] s390x: Convert QEMUMachine to MachineClass

2014-06-12 Thread Alexey Kardashevskiy
This converts s390-virtio and s390-ccw-virtio machines to QOM MachineClass. This brings ability to add interfaces to the machine classes. The first interface for addition will be NMI. The patch is mechanical so no change in behavior is expected. Signed-off-by: Alexey Kardashevskiy --- hw/s390x/

[Qemu-devel] [PATCH v7 4/4] spapr: Add support for new NMI interface

2014-06-12 Thread Alexey Kardashevskiy
This implements an NMI interface POWERPC SPAPR machine. This enables an "nmi" HMP/QMP command supported on SPAPR. This calls POWERPC_EXCP_RESET (vector 0x100) in the guest to deliver NMI to every CPU. The expected result is XMON (in-kernel debugger) invocation. Signed-off-by: Alexey Kardashevskiy

[Qemu-devel] [PATCH v7 1/4] cpus: Define callback for QEMU "nmi" command

2014-06-12 Thread Alexey Kardashevskiy
This introduces an NMI (Non Maskable Interrupt) interface with a single nmi_monitor_handler() method. A machine or a device can implement it. This searches for an QOM object with this interface and if it is implemented, calls it. The callback implements an action required to cause debug crash dump

[Qemu-devel] [Discuss] Qemu TCG-IR VS LLVM IR

2014-06-12 Thread Chaos Shu
Hi all Recently I am investigating is there better BT solution? I got two kinds of popular method. 1. Qemu TCG-IR is offered by Qemu, translate all to op then to target insn 2. With Qemu runtime information convert all insn to LLVM IR, then with LLVM backend and kinds of opt o

[Qemu-devel] [PATCH] q35: Use PC_Q35_COMPAT_1_4 on pc-q35-1.4 compat_props

2014-06-12 Thread Eduardo Habkost
pc-q35-1.4 was incorrectly using PC_COMPAT_1_4 instead of PC_Q35_COMPAT_1_4. The only side-effect was that the hpet compat property (inherited from PC_Q35_COMPAT_1_7) was missing. Without this patch, pc-q35-1.4 inicorrectly initializes hpet-intcap to 0xff0104 (behavior introduced in QEMU 2.0, by

[Qemu-devel] [PATCH] audio: Fix using freed pointer in wav_fini_out

2014-06-12 Thread arei.gonglei
From: Gonglei Spotted by Coverity: (8) Event freed_arg: "fclose(FILE *)" frees "wav->f". (9) Event cond_true: Condition "fclose(wav->f)", taking true branch Also see events: [pass_freed_arg] 212 if (fclose (wav->f)) { (10) Event pass_freed_arg: Passing freed pointer "wav->f" as an

Re: [Qemu-devel] Using virtio for inter-VM communication

2014-06-12 Thread Rusty Russell
Jan Kiszka writes: > On 2014-06-12 04:27, Rusty Russell wrote: >> Henning Schild writes: >> It was also never implemented, and remains a thought experiment. >> However, implementing it in lguest should be fairly easy. > > The reason why a trusted helper, i.e. additional logic in the > hypervisor,

Re: [Qemu-devel] [PATCH v3 14/32] target-arm: Respect SCR.FW, SCR.AW and SCTLR.NMFI

2014-06-12 Thread Greg Bellows
On 10 June 2014 18:54, Fabian Aggeler wrote: > bits when modifying CPSR. > > Signed-off-by: Fabian Aggeler > --- > target-arm/helper.c | 42 +++--- > 1 file changed, 39 insertions(+), 3 deletions(-) > > diff --git a/target-arm/helper.c b/target-arm/helper.c >

Re: [Qemu-devel] [PATCH v3 11/32] target-arm: add async excp target_el&mode function

2014-06-12 Thread Greg Bellows
On 10 June 2014 18:54, Fabian Aggeler wrote: > Adds a dedicated function for IRQ and FIQ exceptions to determine > target_el and mode (Aarch32) according to tables in ARM ARMv8 and > ARM ARM v7. > > Signed-off-by: Fabian Aggeler > --- > target-arm/cpu.h| 3 ++ > target-arm/helper.c | 137

Re: [Qemu-devel] [PATCH v3 10/32] target-arm: extend Aarch64 SCR.{FIQ|IRQ} handling

2014-06-12 Thread Greg Bellows
This should be squashed with 9/32. On 10 June 2014 18:54, Fabian Aggeler wrote: > If EL3 is using Aarch64 IRQ/FIQ masking is ignored in > all exception levels other than EL3 if SCR.{FIQ|IRQ} is > set to 1 (routed to EL3). > > Signed-off-by: Fabian Aggeler > --- > target-arm/cpu.h | 98 > +

Re: [Qemu-devel] [PATCH v3 05/32] target-arm: reject switching to monitor mode

2014-06-12 Thread Greg Bellows
Missing case where it is UNPREDICTABLE to enter FIQ mode from non-secure state if NSACR.RFR is 1. On 10 June 2014 18:54, Fabian Aggeler wrote: > From: Sergey Fedorov > > ...from non-secure state. > > Signed-off-by: Sergey Fedorov > Signed-off-by: Fabian Aggeler > --- > target-arm/helper.c |

Re: [Qemu-devel] [PATCH v3 02/32] target-arm: move Aarch32 SCR into security reglist

2014-06-12 Thread Greg Bellows
Conflict with Edgar's changes around the name of the security register group v8_el3_cp_reginfo vs. security_cp_reginfo. Given that there is a difference between the v7 regs and their v8 equivalents such as encoding, I propose we create 2 separate groups, but map them to the same storage where appl

Re: [Qemu-devel] [PATCH v3 19/32] target-arm: insert Aarch32 cpregs twice into hashtable

2014-06-12 Thread Sergey Fedorov
Hi Fabian, 11.06.2014 03:55, Fabian Aggeler wrote: > Prepare for cp register banking by inserting every cp register twice, > once for secure world and once for non-secure world. > > Signed-off-by: Fabian Aggeler > --- > target-arm/cpu.h | 14 +++--- > target-arm/helper.c| 20 ++

Re: [Qemu-devel] [PATCH v3 04/32] target-arm: add arm_is_secure() function

2014-06-12 Thread Sergey Fedorov
I suggested to combine arm_is_secure() and arm_is_secure_below_el3(). Since the code follows the v8 pseudo code my suggestion is really not a good idea. So I apologize twice for wasting your time :) // Sergey 12.06.2014 22:35, Greg Bellows wrote: > To make sure I understand, you are proposing tha

Re: [Qemu-devel] [PATCH v3 04/32] target-arm: add arm_is_secure() function

2014-06-12 Thread Greg Bellows
To make sure I understand, you are proposing that we simply use the return from arm_current_pl of 3 to indicate isSecure? Fabian's code closely follows the v8 spec pseudo code. I believe the case that would be omitted if we let a return of 3 mean "secure" is the case where we are in EL0/1 with SC

Re: [Qemu-devel] [PATCH v3 04/32] target-arm: add arm_is_secure() function

2014-06-12 Thread Sergey Fedorov
Hi Greg, I'm sorry, I wasn't thoughtful enough and missed that. I would just suggest to combine that functions since they have a common part, i.e.: if (arm_feature(env, ARM_FEATURE_EL3)) { ... What do you think? // Sergey 12.06.2014 20:26, Greg Bellows пишет: > Hi Sergey, > > I thi

Re: [Qemu-devel] [Xen-devel] [PATCH v2] libxl: change default QEMU machine to pc-i440fx-1.6

2014-06-12 Thread Fabio Fantoni
2014-06-12 16:33 GMT+02:00 Stefano Stabellini < stefano.stabell...@eu.citrix.com>: > Choose pc-i440fx-1.6 instead of pc for HVM guests, so that we know for > sure what is the machine that we are emulating. > > Use pc-i440fx-1.6 regardless of the xen_platform_pci option. Add the > xen-platform devi

Re: [Qemu-devel] [PATCH v3 8/9] vmstate: Add preallocation for migrating arrays (VMS_ALLOC flag)

2014-06-12 Thread Alexander Graf
On 06/12/2014 05:02 PM, Alexey Kardashevskiy wrote: On 06/08/2014 09:59 AM, Alexey Kardashevskiy wrote: On 06/03/2014 11:19 PM, Alexey Kardashevskiy wrote: On 05/30/2014 07:34 PM, Alexey Kardashevskiy wrote: There are few helpers already to support array migration. However they all require the

Re: [Qemu-devel] Why I advise against using ivshmem

2014-06-12 Thread Paolo Bonzini
Il 12/06/2014 18:02, Vincent JARDIN ha scritto: * Get all the required parts outside QEMU packaged in major distros, or absorbed into QEMU Redhat did disable it. why? it is there in QEMU. We don't ship everything that is part of QEMU, just like we selectively disable many drivers in Lin

[Qemu-devel] Bug: VNC not refreshing the screen properly

2014-06-12 Thread Anthony PERARD
Hi, I've discovered that, with QEMU 2.0, the screen is not properly updated on my VNC client. This is running under Xen unstable. Same thing with happend with master. So, what happen is, when I move a window on a Windows XP guest, there are some artefact, part of the window get something differen

Re: [Qemu-devel] [PATCH v3 04/32] target-arm: add arm_is_secure() function

2014-06-12 Thread Greg Bellows
Hi Sergey, I think I am missing your point. In patch 6 arm_current_pl calls arm_is_secure. Can you elaborate? Greg On 11 June 2014 07:17, Sergey Fedorov wrote: > On 11.06.2014 03:54, Fabian Aggeler wrote: > > arm_is_secure() function allows to determine CPU security state > > if the CPU imp

Re: [Qemu-devel] USB passthrough in qemu

2014-06-12 Thread Michal Suchanek
On 12 June 2014 12:26, Gerd Hoffmann wrote: > Hi, > >> However, for the piix4 which is the default platform and is desirable >> due to driver issues in many cases no simple way to instantiate the >> companion setup and have qemu automagically attach the devices >> correctly exists. > > We havn't

Re: [Qemu-devel] Why I advise against using ivshmem

2014-06-12 Thread Vincent JARDIN
Markus, see inline (I am not on all mailing list, please, keep the cc list). > Sure! The reasons for my dislike range from practical to > philosophical. My practical concerns include: 1. ivshmem code needs work, but has no maintainer See David's contributions: http://patchwork.ozlabs.org/

[Qemu-devel] Help debugging audio problem

2014-06-12 Thread Programmingkid
What does this code mean? if (!glue (s->nb_hw_voices_, TYPE)) { return NULL; } The code is found in audio_template.h at line 244. I tried using GDB to figure out what it was doing, but had little luck. The AC97 sound card does not work, and I'm trying to change that. Any help

Re: [Qemu-devel] [PATCH v3 8/9] vmstate: Add preallocation for migrating arrays (VMS_ALLOC flag)

2014-06-12 Thread Alexey Kardashevskiy
On 06/08/2014 09:59 AM, Alexey Kardashevskiy wrote: > On 06/03/2014 11:19 PM, Alexey Kardashevskiy wrote: >> On 05/30/2014 07:34 PM, Alexey Kardashevskiy wrote: >>> There are few helpers already to support array migration. However they all >>> require the destination side to preallocate arrays befo

Re: [Qemu-devel] [PATCH applied] ich: get rid of spaces in type name

2014-06-12 Thread Michael S. Tsirkin
On Thu, Jun 12, 2014 at 04:33:11PM +0200, Markus Armbruster wrote: > "Michael S. Tsirkin" writes: > > > On Thu, Jun 12, 2014 at 10:27:53AM +0200, Markus Armbruster wrote: > >> "Michael S. Tsirkin" writes: > >> > >> > Names with spaces in them are nasty, let's not go there. > >> > >> Yes, they

[Qemu-devel] [PATCH v2] libxl: change default QEMU machine to pc-i440fx-1.6

2014-06-12 Thread Stefano Stabellini
Choose pc-i440fx-1.6 instead of pc for HVM guests, so that we know for sure what is the machine that we are emulating. Use pc-i440fx-1.6 regardless of the xen_platform_pci option. Add the xen-platform device if requested. Move the machine options earlier, before any emulated devices options so th

[Qemu-devel] Why I advise against using ivshmem (was: Using virtio for inter-VM communication)

2014-06-12 Thread Markus Armbruster
Henning Schild writes: > On Thu, 12 Jun 2014 08:48:04 +0200 > Markus Armbruster wrote: > >> Vincent JARDIN writes: >> >> > On 10/06/2014 18:48, Henning Schild wrote:> Hi, >> >> In a first prototype i implemented a ivshmem[2] device for the >> >> hypervisor. That way we can share memory between

Re: [Qemu-devel] [PATCH v2 12/22] target-mips: add ALIGN, DALIGN, BITSWAP and DBITSWAP instructions

2014-06-12 Thread Richard Henderson
On 06/12/2014 01:35 AM, Leon Alrae wrote: > Yes, it clutters the code a bit. However, by looking at the other > instructions I got the impression that preferable approach is to avoid > generating unnecessary code if we can. This seems to be sensible so I'm > trying to stick to it. So in bitswap exa

Re: [Qemu-devel] [PATCH applied] ich: get rid of spaces in type name

2014-06-12 Thread Markus Armbruster
"Michael S. Tsirkin" writes: > On Thu, Jun 12, 2014 at 10:27:53AM +0200, Markus Armbruster wrote: >> "Michael S. Tsirkin" writes: >> >> > Names with spaces in them are nasty, let's not go there. >> >> Yes, they are, but please use '-' instead of '_'. I can see just a few >> devices with '_' i

Re: [Qemu-devel] [PATCH 7/7] virtio-scsi: add support for the any_layout feature

2014-06-12 Thread Paolo Bonzini
Il 12/06/2014 14:33, Michael S. Tsirkin ha scritto: > On Thu, Jun 12, 2014 at 02:09:08PM +0200, Paolo Bonzini wrote: >> Store the request and response headers by value, and let >> virtio_scsi_parse_req check that there is only one of datain >> and dataout. >> >> Signed-off-by: Paolo Bonzini >> ---

Re: [Qemu-devel] [PATCH 3/9] block: Move json: parsing to bdrv_fill_options()

2014-06-12 Thread Eric Blake
On 06/12/2014 06:26 AM, Benoît Canet wrote: >> +static QDict *parse_json_filename(const char *filename, Error **errp) >> +{ > > I am under the impression that this code move could be avoided by using a > function > prototype: the patch would be less cluttered. I'm a fan of avoiding function pr

Re: [Qemu-devel] [PATCH v6 1/4] cpus: Define callback for QEMU "nmi" command

2014-06-12 Thread Eric Blake
On 06/11/2014 09:29 PM, Alexey Kardashevskiy wrote: > On 06/12/2014 11:46 AM, Eric Blake wrote: >> On 06/11/2014 06:10 PM, Alexey Kardashevskiy wrote: >> > + * This program is free software; you can redistribute it and/or modify > + * it under the terms of the GNU General Public License a

Re: [Qemu-devel] [PATCH v3 3/4] audio: Fix using freed pointer in wav_fini_out()

2014-06-12 Thread Gerd Hoffmann
> -dolog ("wav_fini_out: fclose %p failed\nReason: %s\n", > > > > - wav->f, strerror (errno)); > > > > +dolog ("wav_fini_out: fclose 'wav->f' failed\nReason: %s\n", > > > > + strerror (errno)); > > > > > > I would just drop the 'wav->f' here. > > > > Or d

[Qemu-devel] Fsync on directory in virtio-9pfs fails

2014-06-12 Thread Karolin Varner
Hi, i think I ran into this (https://lists.gnu.org/archive/html/qemu-devel/2011-04/msg02144.html) problem. Has that patch ever been included? Regards, Karolin Varner

Re: [Qemu-devel] [PATCH v3 3/4] audio: Fix using freed pointer in wav_fini_out()

2014-06-12 Thread Gonglei (Arei)
> -Original Message- > From: Gerd Hoffmann [mailto:kra...@redhat.com] > Sent: Thursday, June 12, 2014 6:32 PM > To: Peter Maydell > Cc: Gonglei (Arei); QEMU Developers; Huangweidong (C); Luonengjun; Luiz > Capitulino; Vassili Karpov; Stefan Hajnoczi; Paolo Bonzini > Subject: Re: [Qemu-devel

Re: [Qemu-devel] [PATCH v3 4/4] vga: Fix divide-by-zero in vga_update_text

2014-06-12 Thread Gonglei (Arei)
> -Original Message- > From: Gerd Hoffmann [mailto:kra...@redhat.com] > Sent: Thursday, June 12, 2014 6:44 PM > To: Gonglei (Arei) > Cc: qemu-devel@nongnu.org; pbonz...@redhat.com; lcapitul...@redhat.com; > av1...@comtv.ru; stefa...@redhat.com; Luonengjun; Huangweidong (C) > Subject: Re: [P

Re: [Qemu-devel] Using virtio for inter-VM communication

2014-06-12 Thread Markus Armbruster
Henning Schild writes: > On Thu, 12 Jun 2014 08:48:04 +0200 > Markus Armbruster wrote: > >> Vincent JARDIN writes: >> >> > On 10/06/2014 18:48, Henning Schild wrote:> Hi, >> >> In a first prototype i implemented a ivshmem[2] device for the >> >> hypervisor. That way we can share memory between

Re: [Qemu-devel] [PATCH v2 0/2] vnc: Drop some superfluous conditionals

2014-06-12 Thread Markus Armbruster
Gerd Hoffmann writes: > On Fr, 2014-06-06 at 18:47 +0200, Markus Armbruster wrote: >> Markus Armbruster (2): >> vnc: Drop superfluous conditionals around g_free() >> vnc: Drop superfluous conditionals around g_strdup() >> >> ui/vnc-tls.c | 6 ++ >> ui/vnc.c | 15 --- >>

Re: [Qemu-devel] [PATCH 6/9] block: Inline bdrv_file_open()

2014-06-12 Thread Benoît Canet
The Wednesday 11 Jun 2014 à 16:05:00 (+0200), Kevin Wolf wrote : > It doesn't do much any more, we can move the code to bdrv_open() now. > > Signed-off-by: Kevin Wolf > --- > block.c | 51 +++ > 1 file changed, 11 insertions(+), 40 deletions(-) >

Re: [Qemu-devel] [PATCH 5/9] block: Use common driver selection code for bdrv_open_file()

2014-06-12 Thread Benoît Canet
The Wednesday 11 Jun 2014 à 16:04:59 (+0200), Kevin Wolf wrote : > This moves the bdrv_open_file() call a bit down so that it can use the > bdrv_open() code that selects the right block driver. > > The code between the old and the new call site is either common code > (the error message for an unk

Re: [Qemu-devel] [PATCH 4/9] block: Always pass driver name through options QDict

2014-06-12 Thread Benoît Canet
The Wednesday 11 Jun 2014 à 16:04:58 (+0200), Kevin Wolf wrote : > The "driver" entry in the options QDict is now only missing if we're > opening an image with format probing. > > We also catch cases now where both the drv argument and a "driver" > option is specified, e.g. by specifying -drive fo

Re: [Qemu-devel] [PATCH v6 2/4] target-s390x: Migrate to new NMI interface

2014-06-12 Thread Alexey Kardashevskiy
On 06/12/2014 09:02 PM, Cornelia Huck wrote: > On Thu, 12 Jun 2014 19:38:40 +1000 > Alexey Kardashevskiy wrote: > >> On 06/12/2014 04:31 PM, Cornelia Huck wrote: >>> On Thu, 12 Jun 2014 03:03:01 +1000 >>> Alexey Kardashevskiy wrote: >>> This implements an NMI interface for s390 machine. >>>

Re: [Qemu-devel] [PATCH 7/7] virtio-scsi: add support for the any_layout feature

2014-06-12 Thread Michael S. Tsirkin
On Thu, Jun 12, 2014 at 02:09:08PM +0200, Paolo Bonzini wrote: > Store the request and response headers by value, and let > virtio_scsi_parse_req check that there is only one of datain > and dataout. > > Signed-off-by: Paolo Bonzini > --- > hw/scsi/virtio-scsi.c | 161 > ++

Re: [Qemu-devel] [PATCH v3 00/10] usb: usb host adapter hotplug

2014-06-12 Thread Gonglei (Arei)
> -Original Message- > From: Gerd Hoffmann [mailto:kra...@redhat.com] > Sent: Thursday, June 12, 2014 7:33 PM > To: Gonglei (Arei) > Cc: qemu-devel@nongnu.org; Luonengjun; Huangweidong (C); Huangpeng > (Peter) > Subject: Re: [PATCH v3 00/10] usb: usb host adapter hotplug > > On Mi, 2014-06

Re: [Qemu-devel] [PATCH 3/9] block: Move json: parsing to bdrv_fill_options()

2014-06-12 Thread Benoît Canet
The Wednesday 11 Jun 2014 à 16:04:57 (+0200), Kevin Wolf wrote : > Signed-off-by: Kevin Wolf > --- > block.c | 88 > + > 1 file changed, 45 insertions(+), 43 deletions(-) > > diff --git a/block.c b/block.c > index effb3e6..b9c2b41

Re: [Qemu-devel] [PATCH 2/9] block: Move bdrv_fill_options() call to bdrv_open()

2014-06-12 Thread Benoît Canet
The Wednesday 11 Jun 2014 à 16:04:56 (+0200), Kevin Wolf wrote : > bs->options now contains the modified version of the options. > > Signed-off-by: Kevin Wolf > --- > block.c | 26 -- > 1 file changed, 16 insertions(+), 10 deletions(-) > > diff --git a/block.c b/block.c

Re: [Qemu-devel] [PULL 0/4] migration queue

2014-06-12 Thread Juan Quintela
Peter Maydell wrote: > On 10 June 2014 17:31, Juan Quintela wrote: >> Hi >> >> This includes: >> >> - last two patches that remove version_minimum_id_old. >> >> - refactor of opening of files was already tested (this is test-vmstate only) >> - v4 of flags in ram_load from Peter. >> >> Please, app

[Qemu-devel] [PATCH v2] ppc: spapr-rtas - implement os-term rtas call

2014-06-12 Thread Nikunj A Dadhania
PAPR compliant guest calls this in absence of kdump. After receiving this call qemu could trigger a guest dump. This guest dump can be used to analyse using crash tool. Signed-off-by: Nikunj A Dadhania --- v2: indentation fixes hw/ppc/spapr_rtas.c | 32 1 file

[Qemu-devel] [PATCH v2] spapr: add uuid/host details to device tree

2014-06-12 Thread Nikunj A Dadhania
Useful for identifying the guest/host uniquely within the guest. Adding following properties to the guest root node. vm,uuid - uuid of the guest host-model - Host model number host-serial - Host machine serial number hypervisor type - Tells its "kvm" Signed-off-by: Nikunj A Dadhania --- v2: ind

[Qemu-devel] [PATCH 7/7] virtio-scsi: add support for the any_layout feature

2014-06-12 Thread Paolo Bonzini
Store the request and response headers by value, and let virtio_scsi_parse_req check that there is only one of datain and dataout. Signed-off-by: Paolo Bonzini --- hw/scsi/virtio-scsi.c | 161 ++-- include/hw/i386/pc.h| 4 + include/hw/

[Qemu-devel] [PATCH 3/7] virtio-scsi: add target swap for VirtIOSCSICtrlTMFReq fields

2014-06-12 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- hw/scsi/virtio-scsi.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/hw/scsi/virtio-scsi.c b/hw/scsi/virtio-scsi.c index e548ad3..c32c99b 100644 --- a/hw/scsi/virtio-scsi.c +++ b/hw/scsi/virtio-scsi.c @@ -207,6 +207,7 @@ static void virti

[Qemu-devel] [PATCH 5/7] virtio-scsi: prepare sense data handling for any_layout

2014-06-12 Thread Paolo Bonzini
Retrieve sense and copy it to guest memory, to prepare for when we will use qemu_iovec_from_buf. Swap response and request, since we'll use the tail of VirtIOSCSIReq for the CDB. Signed-off-by: Paolo Bonzini --- hw/scsi/virtio-scsi.c | 22 -- 1 file changed, 12 insertions(+)

[Qemu-devel] [PATCH 4/7] virtio-scsi: add extra argument and return type to qemu_sgl_concat

2014-06-12 Thread Paolo Bonzini
Will be used for anylayout support. Signed-off-by: Paolo Bonzini --- hw/scsi/virtio-scsi.c | 27 --- 1 file changed, 20 insertions(+), 7 deletions(-) diff --git a/hw/scsi/virtio-scsi.c b/hw/scsi/virtio-scsi.c index c32c99b..7337dbf 100644 --- a/hw/scsi/virtio-scsi.c +++

[Qemu-devel] [PATCH 0/7] virtio-scsi: do not rely on iov boundaries

2014-06-12 Thread Paolo Bonzini
The upcoming virtio 1.0 standard requires virtio devices not to rely on iov boundaries when parsing requests or sending responses. This series converts virtio-scsi. Please review. Patch 3 is a free bugfix that is easier after the previous patch. Paolo Paolo Bonzini (7): util: add return value

[Qemu-devel] [PATCH 6/7] virtio-scsi: introduce virtio_scsi_complete_cmd_req

2014-06-12 Thread Paolo Bonzini
This is also related to sense handling, and will be used by anylayout. Signed-off-by: Paolo Bonzini --- hw/scsi/virtio-scsi.c | 11 --- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/hw/scsi/virtio-scsi.c b/hw/scsi/virtio-scsi.c index 60f77cd..107e9cb 100644 --- a/hw/scsi/

[Qemu-devel] [PATCH 2/7] virtio-scsi: start preparing for any_layout

2014-06-12 Thread Paolo Bonzini
- Introduce virtio_scsi_init_req and virtio_scsi_free_req - rename qemu_sgl_init_external to qemu_sgl_concat - move virtio_scsi_parse_req from virtio_scsi_pop_req to callers and add header length checks to virtio_scsi_parse_req. Signed-off-by: Paolo Bonzini --- hw/scsi/virtio-scsi.c | 121 ++

[Qemu-devel] [PATCH 1/7] util: add return value to qemu_iovec_concat_iov

2014-06-12 Thread Paolo Bonzini
This will be necessary later to recognize the case where a request has both dataout and datain. Signed-off-by: Paolo Bonzini --- include/qemu-common.h | 6 +++--- util/iov.c| 10 ++ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/include/qemu-common.h b/includ

Re: [Qemu-devel] [PATCH 1/9] block: Create bdrv_fill_options()

2014-06-12 Thread Benoît Canet
The Wednesday 11 Jun 2014 à 16:04:55 (+0200), Kevin Wolf wrote : > The idea of bdrv_fill_options() is to convert every parameter for > opening images, in particular the filename and flags, to entries in the > options QDict. > > This patch starts with moving the filename parsing and driver probing

[Qemu-devel] [PATCH v3 3/7][RESEND PATCH] bitmap dump code via QAPI framework with runstates

2014-06-12 Thread Sanidhya Kashyap
Reformatted the code and added the functionality of dumping the blocks' info which can be read by the user when required. I have also made the block name length global. Signed-off-by: Sanidhya Kashyap --- include/exec/cpu-all.h | 3 +- migration.c| 7 ++ qapi-schema.json |

Re: [Qemu-devel] [PATCH] audio: Drop superfluous conditionals around g_free()

2014-06-12 Thread Gerd Hoffmann
On Fr, 2014-06-06 at 18:35 +0200, Markus Armbruster wrote: > Signed-off-by: Markus Armbruster > --- > audio/alsaaudio.c | 12 > audio/audio_template.h | 15 --- > audio/ossaudio.c | 6 ++ > hw/audio/adlib.c | 4 +--- > 4 files changed, 11 insertions

Re: [Qemu-devel] [PATCH v2 0/2] vnc: Drop some superfluous conditionals

2014-06-12 Thread Gerd Hoffmann
On Fr, 2014-06-06 at 18:47 +0200, Markus Armbruster wrote: > Markus Armbruster (2): > vnc: Drop superfluous conditionals around g_free() > vnc: Drop superfluous conditionals around g_strdup() > > ui/vnc-tls.c | 6 ++ > ui/vnc.c | 15 --- > 2 files changed, 6 insertions(+)

Re: [Qemu-devel] [PATCH v3 00/10] usb: usb host adapter hotplug

2014-06-12 Thread Gerd Hoffmann
On Mi, 2014-06-11 at 09:23 +, Gonglei (Arei) wrote: > Hi, > > Gerd, do you plan to apply and pull the patch serials? Thanks! Series looks sane, I want run some stress tests on them before committing though. Havn't found yet the time to do that. > I have finished some qtest cases for usb hos

Re: [Qemu-devel] [PATCH v3 2/7] RunState: added two new flags for bitmap dump and migration process

2014-06-12 Thread Sanidhya Kashyap
> int runstate_is_running(void) > { > -return runstate_check(RUN_STATE_RUNNING); > +return (runstate_check(RUN_STATE_RUNNING) || > +runstate_check(RUN_STATE_MIGRATE) || > +runstate_check(RUN_STATE_DUMP_BITMAP)); > } Forgot to apply the checkpatch script. The retu

Re: [Qemu-devel] [PATCH RFC 8/8] virtio: add endian-ambivalent support to VirtIODevice

2014-06-12 Thread Greg Kurz
On Thu, 12 Jun 2014 13:59:59 +0300 "Michael S. Tsirkin" wrote: > On Thu, Jun 12, 2014 at 12:50:56PM +0200, Greg Kurz wrote: > > On Thu, 12 Jun 2014 12:39:27 +0200 > > Alexander Graf wrote: > > > > > > > > > > > > Am 12.06.2014 um 12:14 schrieb Greg Kurz : > > > > > > > > On Thu, 12 Jun 2014

Re: [Qemu-devel] [PATCH v3 4/4] vga: Fix divide-by-zero in vga_update_text

2014-06-12 Thread Paolo Bonzini
Il 12/06/2014 12:43, Gerd Hoffmann ha scritto: That doesn't fix the reported issue. It's "width" which Coverity thinks might be zero, not cursor_offset. And cursor_offset being zero is perfectly fine, happens when the cursor is in the upper left corner. I have no idea why Coverity thinks width

Re: [Qemu-devel] [PATCH v6 2/4] target-s390x: Migrate to new NMI interface

2014-06-12 Thread Cornelia Huck
On Thu, 12 Jun 2014 19:38:40 +1000 Alexey Kardashevskiy wrote: > On 06/12/2014 04:31 PM, Cornelia Huck wrote: > > On Thu, 12 Jun 2014 03:03:01 +1000 > > Alexey Kardashevskiy wrote: > > > >> This implements an NMI interface for s390 machine. > >> > >> This removes #ifdef s390 branch in qmp_injec

Re: [Qemu-devel] [PATCH RFC 8/8] virtio: add endian-ambivalent support to VirtIODevice

2014-06-12 Thread Michael S. Tsirkin
On Thu, Jun 12, 2014 at 12:50:56PM +0200, Greg Kurz wrote: > On Thu, 12 Jun 2014 12:39:27 +0200 > Alexander Graf wrote: > > > > > > > > Am 12.06.2014 um 12:14 schrieb Greg Kurz : > > > > > > On Thu, 12 Jun 2014 11:43:20 +0200 > > > Alexander Graf wrote: > > > > > >> > > >>> On 12.06.14 11:3

Re: [Qemu-devel] [PATCH RFC 8/8] virtio: add endian-ambivalent support to VirtIODevice

2014-06-12 Thread Alexander Graf
> Am 12.06.2014 um 12:50 schrieb Greg Kurz : > > On Thu, 12 Jun 2014 12:39:27 +0200 > Alexander Graf wrote: > >> >> >>> Am 12.06.2014 um 12:14 schrieb Greg Kurz : >>> >>> On Thu, 12 Jun 2014 11:43:20 +0200 >>> Alexander Graf wrote: >>> >> On 12.06.14 11:39, Paolo Bonzini wrote:

Re: [Qemu-devel] [PATCH RFC 8/8] virtio: add endian-ambivalent support to VirtIODevice

2014-06-12 Thread Michael S. Tsirkin
On Thu, Jun 12, 2014 at 12:14:40PM +0200, Greg Kurz wrote: > On Thu, 12 Jun 2014 11:43:20 +0200 > Alexander Graf wrote: > > > > > On 12.06.14 11:39, Paolo Bonzini wrote: > > > Il 12/06/2014 11:37, Michael S. Tsirkin ha scritto: > > >> Maybe just drop unnecessary stuff for new machine types? > >

Re: [Qemu-devel] [PATCH RFC 8/8] virtio: add endian-ambivalent support to VirtIODevice

2014-06-12 Thread Michael S. Tsirkin
On Thu, Jun 12, 2014 at 11:43:20AM +0200, Alexander Graf wrote: > > On 12.06.14 11:39, Paolo Bonzini wrote: > >Il 12/06/2014 11:37, Michael S. Tsirkin ha scritto: > >>Maybe just drop unnecessary stuff for new machine types? > >>Then we won't need hacks to migrate it. > > > >For any machine type it

Re: [Qemu-devel] [PATCH RFC 8/8] virtio: add endian-ambivalent support to VirtIODevice

2014-06-12 Thread Michael S. Tsirkin
On Thu, Jun 12, 2014 at 11:39:42AM +0200, Paolo Bonzini wrote: > Il 12/06/2014 11:37, Michael S. Tsirkin ha scritto: > >Maybe just drop unnecessary stuff for new machine types? > >Then we won't need hacks to migrate it. > > For any machine type it's trivial to migrate it. All machine types > incl

Re: [Qemu-devel] [PATCH RFC 8/8] virtio: add endian-ambivalent support to VirtIODevice

2014-06-12 Thread Greg Kurz
On Thu, 12 Jun 2014 12:39:27 +0200 Alexander Graf wrote: > > > > Am 12.06.2014 um 12:14 schrieb Greg Kurz : > > > > On Thu, 12 Jun 2014 11:43:20 +0200 > > Alexander Graf wrote: > > > >> > >>> On 12.06.14 11:39, Paolo Bonzini wrote: > >>> Il 12/06/2014 11:37, Michael S. Tsirkin ha scritto: >

Re: [Qemu-devel] [PATCH v3 4/4] vga: Fix divide-by-zero in vga_update_text

2014-06-12 Thread Gerd Hoffmann
Hi, > 2097if (cursor_visible && cursor_offset < size && cursor_offset >= 0) > (23) Event divide_by_zero: In expression "cursor_offset / width", > division by expression "width" which may be zero has undefined behavior. > -if (cursor_visible && cursor_offset < size && cursor_off

[Qemu-devel] [PATCH v3 6/7] set the frequency of the dump bitmap process

2014-06-12 Thread Sanidhya Kashyap
No, particular change except the function name changed - value_in_range(). Signed-off-by: Sanidhya Kashyap --- hmp-commands.hx | 15 +++ hmp.c| 12 hmp.h| 1 + qapi-schema.json | 11 +++ qmp-commands.hx | 24 sa

[Qemu-devel] [PATCH v3 5/7] cancel mechanism for an already running dump bitmap process

2014-06-12 Thread Sanidhya Kashyap
Signed-off-by: Sanidhya Kashyap --- hmp-commands.hx | 14 ++ hmp.c| 5 + hmp.h| 1 + qapi-schema.json | 8 qmp-commands.hx | 20 savevm.c | 19 +++ 6 files changed, 67 insertions(+) diff --git a/hm

Re: [Qemu-devel] [PATCH RFC 8/8] virtio: add endian-ambivalent support to VirtIODevice

2014-06-12 Thread Alexander Graf
> Am 12.06.2014 um 12:14 schrieb Greg Kurz : > > On Thu, 12 Jun 2014 11:43:20 +0200 > Alexander Graf wrote: > >> >>> On 12.06.14 11:39, Paolo Bonzini wrote: >>> Il 12/06/2014 11:37, Michael S. Tsirkin ha scritto: Maybe just drop unnecessary stuff for new machine types? Then we won't

[Qemu-devel] [PATCH v3 7/7] python script for extracting bitmap from a binary file

2014-06-12 Thread Sanidhya Kashyap
The script has been modified to store the blocks' information in dictionary format that can be used by the user. Besides, that there was some issue with the script which I have rectified and it is working perfectly. For every iteration, the bitmap is followed by a character - 'M' which acts as a m

[Qemu-devel] [PATCH v3 4/7] hmp interface for dirty bitmap dump

2014-06-12 Thread Sanidhya Kashyap
Signed-off-by: Sanidhya Kashyap --- hmp-commands.hx | 16 hmp.c | 16 hmp.h | 1 + 3 files changed, 33 insertions(+) diff --git a/hmp-commands.hx b/hmp-commands.hx index 5f1a677..cccd53e 100644 --- a/hmp-commands.hx +++ b/hmp-commands.hx @@

[Qemu-devel] [PATCH v3 2/7] RunState: added two new flags for bitmap dump and migration process

2014-06-12 Thread Sanidhya Kashyap
Changed those files that were directly using the RUN_STATE_RUNNING flag. Now, they have been replaced by the runstate_is_running() function. Signed-off-by: Sanidhya Kashyap --- hw/usb/hcd-ehci.c | 2 +- hw/usb/redirect.c | 6 +++--- qapi-schema.json | 7 ++- vl.c | 29 ++

[Qemu-devel] [PATCH v3 0/7] Obtain dirty bitmap via VM logging

2014-06-12 Thread Sanidhya Kashyap
Hi, The following patches introduce the support of the dirty bitmap logging and dumping to a specified file. This patch addresses the issues raised by David and Juan. Since, I have not received any comments on the runstates, I'll keep them in the patch series. v2 --> v3 * Reformatted the code and

[Qemu-devel] [PATCH v3 3/7] bitmap dump code via QAPI framework with runstates

2014-06-12 Thread Sanidhya Kashyap
Reformatted the code and added the functionality of dumping the blocks' info which can be read by the user when required. I have also made the block name length global. Signed-off-by: Sanidhya Kashyap --- include/exec/cpu-all.h | 3 +- migration.c| 7 ++ qapi-schema.json |

[Qemu-devel] [PATCH v3 1/7] enable sharing of the function between migration and bitmap dump

2014-06-12 Thread Sanidhya Kashyap
Added prefix qemu_ to the function as pointed out by Juan. Signed-off-by: Sanidhya Kashyap --- arch_init.c | 19 +++ include/exec/ram_addr.h | 4 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/arch_init.c b/arch_init.c index 23044c1..2fec98b 100

Re: [Qemu-devel] [PATCH v3 3/4] audio: Fix using freed pointer in wav_fini_out()

2014-06-12 Thread Gerd Hoffmann
Hi, > > doclose: > > if (fclose (wav->f)) { > > -dolog ("wav_fini_out: fclose %p failed\nReason: %s\n", > > - wav->f, strerror (errno)); > > +dolog ("wav_fini_out: fclose 'wav->f' failed\nReason: %s\n", > > + strerror (errno)); > > I would just

  1   2   >