Re: [Qemu-devel] [Qemu-ppc] [PATCH 2/2] tcg/ppc*: Move cache initialization to ppc specific code

2011-10-04 Thread Benjamin Herrenschmidt
Not doing it sometimes invokes crash penalties for us. :-) We could add some way to skip the invalidation if we know the host is an implementation that doesn't need it, possibly depending on the context (is it just DMA he wants to avoid doing this on[1], or do their chips have a fully

Re: [Qemu-devel] [Qemu-ppc] [PATCH 2/2] tcg/ppc*: Move cache initialization to ppc specific code

2011-10-04 Thread Paolo Bonzini
On 10/04/2011 07:55 AM, Stefan Weil wrote: I learned now that ppc will need flush_icache_range() for kvm, too. So it won't be possible to implement a uniform handling of flush_icache_range() for all host architectures. x86 and IIRC s390 flush_icache_range is a no-op, so it is possible to call

[Qemu-devel] buildbot failure in qemu on monitor_x86_64_debian_6_0

2011-10-04 Thread qemu
The Buildbot has detected a new failure on builder monitor_x86_64_debian_6_0 while building qemu. Full details are available at: http://buildbot.b1-systems.de/qemu/builders/monitor_x86_64_debian_6_0/builds/50 Buildbot URL: http://buildbot.b1-systems.de/qemu/ Buildslave for this Build: yuzuki

Re: [Qemu-devel] [PATCH 1/2] linux-user: Remove unused code

2011-10-04 Thread Peter Maydell
On 3 October 2011 21:43, Stefan Weil s...@weilnetz.de wrote: The code is unused since 8 years, so remove it. Signed-off-by: Stefan Weil s...@weilnetz.de ---  linux-user/signal.c |    5 +  1 files changed, 1 insertions(+), 4 deletions(-) diff --git a/linux-user/signal.c

Re: [Qemu-devel] buildbot failure in qemu on default_openbsd_4.9

2011-10-04 Thread Stefan Hajnoczi
On Mon, Oct 03, 2011 at 05:57:28PM -0500, Anthony Liguori wrote: On 10/03/2011 06:15 PM, q...@buildbot.b1-systems.de wrote: The Buildbot has detected a new failure on builder default_openbsd_4.9 while building qemu. Full details are available at:

Re: [Qemu-devel] New option for snapshot_blkdev to avoid image creation

2011-10-04 Thread Stefan Hajnoczi
On Mon, Oct 03, 2011 at 04:09:01PM +, Federico Simoncelli wrote: In some situations might be useful to let qemu use an image that was prepared for a live snapshot. The advantage is that creating the snapshot file outside of the qemu process we can use the whole range of options provided by

Re: [Qemu-devel] buildbot failure in qemu on default_x86_64_rhel5

2011-10-04 Thread Stefan Hajnoczi
On Mon, Oct 03, 2011 at 04:10:50PM +0530, Aneesh Kumar K.V wrote: On Mon, 3 Oct 2011 08:37:52 +0100, Stefan Hajnoczi stefa...@gmail.com wrote: On Sat, Oct 01, 2011 at 03:03:23PM +0530, Aneesh Kumar K.V wrote: +#ifndef CONFIG_UTIMENSAT +/* + * We support handle fs driver only if

Re: [Qemu-devel] [Qemu-ppc] [PATCH 2/2] tcg/ppc*: Move cache initialization to ppc specific code

2011-10-04 Thread Peter Maydell
On 4 October 2011 07:29, Paolo Bonzini pbonz...@redhat.com wrote: On 10/04/2011 07:55 AM, Stefan Weil wrote: I learned now that ppc will need flush_icache_range() for kvm, too. So it won't be possible to implement a uniform handling of flush_icache_range() for all host architectures. x86 and

Re: [Qemu-devel] buildbot failure in qemu on default_openbsd_4.9

2011-10-04 Thread Daniel Gollub
Hi Stefan, On Tuesday, October 04, 2011 08:45:28 AM Stefan Hajnoczi wrote: Looking at the buildbot documentation there is a 'retry' parameter for version control which specifies a tuple of (delay, repeats) which means that when a full VC checkout fails, it should be retried up to repeats

Re: [Qemu-devel] New option for snapshot_blkdev to avoid image creation

2011-10-04 Thread Federico Simoncelli
- Original Message - From: Stefan Hajnoczi stefa...@gmail.com To: Federico Simoncelli fsimo...@redhat.com Cc: qemu-devel@nongnu.org, aba...@redhat.com, dl...@redhat.com Sent: Tuesday, October 4, 2011 9:33:48 AM Subject: Re: [Qemu-devel] New option for snapshot_blkdev to avoid image

Re: [Qemu-devel] [PATCH V4] Add stdio char device on windows

2011-10-04 Thread Yann Quelen
Hello, 2011/10/3 Fabien Chouteau chout...@adacore.com: Simple implementation of an stdio char device on Windows. Signed-off-by: Fabien Chouteau chout...@adacore.com ---  qemu-char.c |  227 ++-  1 files changed, 225 insertions(+), 2

Re: [Qemu-devel] buildbot failure in qemu on default_x86_64_rhel5

2011-10-04 Thread Aneesh Kumar K.V
On Tue, 4 Oct 2011 08:18:07 +0100, Stefan Hajnoczi stefa...@gmail.com wrote: On Mon, Oct 03, 2011 at 04:10:50PM +0530, Aneesh Kumar K.V wrote: On Mon, 3 Oct 2011 08:37:52 +0100, Stefan Hajnoczi stefa...@gmail.com wrote: On Sat, Oct 01, 2011 at 03:03:23PM +0530, Aneesh Kumar K.V wrote:

Re: [Qemu-devel] buildbot failure in qemu on default_openbsd_4.9

2011-10-04 Thread Stefan Hajnoczi
On Tue, Oct 04, 2011 at 10:12:15AM +0200, Daniel Gollub wrote: Daniel: In the buildbot 0.8.3p1-1 docs I found the 'retry' parameter under 4.11.3 Source Checkout. Is it possible to add this parameter? I applied this for the qemu buildbot master instance for all Git checkouts. Hopefully

Re: [Qemu-devel] buildbot failure in qemu on default_x86_64_rhel5

2011-10-04 Thread Stefan Hajnoczi
On Tue, Oct 04, 2011 at 02:18:20PM +0530, Aneesh Kumar K.V wrote: On Tue, 4 Oct 2011 08:18:07 +0100, Stefan Hajnoczi stefa...@gmail.com wrote: On Mon, Oct 03, 2011 at 04:10:50PM +0530, Aneesh Kumar K.V wrote: On Mon, 3 Oct 2011 08:37:52 +0100, Stefan Hajnoczi stefa...@gmail.com wrote:

Re: [Qemu-devel] New option for snapshot_blkdev to avoid image creation

2011-10-04 Thread Stefan Hajnoczi
On Tue, Oct 04, 2011 at 04:27:42AM -0400, Federico Simoncelli wrote: - Original Message - From: Stefan Hajnoczi stefa...@gmail.com To: Federico Simoncelli fsimo...@redhat.com Cc: qemu-devel@nongnu.org, aba...@redhat.com, dl...@redhat.com Sent: Tuesday, October 4, 2011 9:33:48 AM

Re: [Qemu-devel] [RFC] Adding new filesystem 'proxy' to 9p

2011-10-04 Thread M. Mohan Kumar
That is the case if the proxy helper code is perfectly written. I am trying to think about the scenario where there is a bug (eg heap corruption / stack overflow) which allows a malicious non-root QEMU process to exploit the proxy helper to run code that it was *not* intended to run. If

[Qemu-devel] [PATCH 1/2] ACPI: Update cpu hotplug event for guest

2011-10-04 Thread pingfank
From: Liu Ping Fan pingf...@linux.vnet.ibm.com Need to update cpu hotplug event for guest when updating SCI event Signed-off-by: Liu Ping Fan pingf...@linux.vnet.ibm.com --- hw/acpi_piix4.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/hw/acpi_piix4.c

[Qemu-devel] [PATCH] ACPI: Call ACPI remove handler when handling ACPI eject event

2011-10-04 Thread pingfank
From: Liu Ping Fan pingf...@linux.vnet.ibm.com Call the remove handler for ACPI_NOTIFY_EJECT_REQUEST Signed-off-by: Liu Ping Fan pingf...@linux.vnet.ibm.com --- drivers/acpi/bus.c |2 +- drivers/acpi/scan.c |2 +- include/acpi/acpi_bus.h |2 ++ 3 files changed, 4

[Qemu-devel] [PATCH 2/2] LAPIC: make lapic support cpu hotplug

2011-10-04 Thread pingfank
From: Liu Ping Fan pingf...@linux.vnet.ibm.com Separate apic from qbus to icc bus which supports hotplug feature. And make the creation of apic as part of cpu initialization, so apic's state has been ready, before setting kvm_apic. Signed-off-by: Liu Ping Fan pingf...@linux.vnet.ibm.com ---

[Qemu-devel] Enable x86 linux guest with cpu hotplug feature.

2011-10-04 Thread pingfank
From: Liu Ping Fan pingf...@linux.vnet.ibm.com A bunch of patches, which are applied separately for kernel and qemu-kvm, and make x86 based linux guest with cpu hotplug feature. For kernel: 0001-ACPI-Call-ACPI-remove-handler-when-handling-ACPI-eje.patch --call acpi eject event handler in

[Qemu-devel] [PATCH] ui/spice-core: fix segfault in monitor

2011-10-04 Thread Alon Levy
Fix segfault if a qxl device is present but no spice command line argument is given. RHBZ 743251. Signed-off-by: Alon Levy al...@redhat.com --- ui/spice-core.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/ui/spice-core.c b/ui/spice-core.c index 3cbc721..b14d1d9

[Qemu-devel] s390: Fix cpu shutdown for KVM

2011-10-04 Thread Christian Borntraeger
qemu/kvm on s390 currently hangs on panic (doesnt exit on disabled wait) and also shuts down on cpu hot-unplug (SIGP stop). This patch tries to fix these simple cases. On s390 a shutdown is the state of all CPUs being either stopped or disabled (for interrupts) waiting. We have to track this

[Qemu-devel] [PATCH] runstate: do not discard runstate changes when paused

2011-10-04 Thread Paolo Bonzini
Trying to migrate a paused machine fails. The reason is that the RSTATE_PRE_MIGRATE is reached with vm_stop, and this transition is eaten when the vm is already paused. This patch fixes the problem by always going through runstate_set and always notifying the new state. Signed-off-by: Paolo

Re: [Qemu-devel] [PATCH] s390: fix short kernel command lines

2011-10-04 Thread Alexander Graf
On 09/23/2011 03:38 PM, Christian Borntraeger wrote: The default kernel command line for s390 is root=/dev/ram0 ro When overriding this line, we have to ensure to also copy the \0 to avoid false lines, for example, -append root=/dev/vda will result in root=/dev/vda0 ro with the current code.

[Qemu-devel] build errors on s390 tcg

2011-10-04 Thread Christian Borntraeger
With todays qemu git I get the following error when compiling for s390: In file included from /home/cborntra/REPOS/qemu/tcg/tcg.c:175:0: /home/cborntra/REPOS/qemu/tcg/s390/tcg-target.c:677:13: error: conflicting types for ‘tcg_out_mov’ /home/cborntra/REPOS/qemu/tcg/tcg.c:76:13: note: previous

Re: [Qemu-devel] s390: Fix cpu shutdown for KVM

2011-10-04 Thread Alexander Graf
On 10/04/2011 01:28 PM, Christian Borntraeger wrote: qemu/kvm on s390 currently hangs on panic (doesnt exit on disabled wait) and also shuts down on cpu hot-unplug (SIGP stop). This patch tries to fix these simple cases. On s390 a shutdown is the state of all CPUs being either stopped or

Re: [Qemu-devel] [PATCH 11/22] i8259: Update IRQ state after reset

2011-10-04 Thread Avi Kivity
On 10/02/2011 10:36 PM, Blue Swirl wrote: On Sun, Oct 2, 2011 at 8:31 PM, Avi Kivitya...@redhat.com wrote: In fact these aren't problems. The packet may be sent or data written, as long as they aren't corrupted. A device is allowed to delay a reset (but not indefinitely).

Re: [Qemu-devel] build errors on s390 tcg

2011-10-04 Thread Alexander Graf
On 10/04/2011 01:54 PM, Christian Borntraeger wrote: With todays qemu git I get the following error when compiling for s390: In file included from /home/cborntra/REPOS/qemu/tcg/tcg.c:175:0: /home/cborntra/REPOS/qemu/tcg/s390/tcg-target.c:677:13: error: conflicting types for ‘tcg_out_mov’

Re: [Qemu-devel] build errors on s390 tcg

2011-10-04 Thread Peter Maydell
On 4 October 2011 13:23, Alexander Graf ag...@suse.de wrote: The problem is that tcg.c defines the functions with int arguments for TCG register indexes, while s390/tcg-target.c takes TCGReg parameters. I'm not sure which way is better, but using TCGReg feels more type safe to me. You're not

Re: [Qemu-devel] [PATCH 2/2] LAPIC: make lapic support cpu hotplug

2011-10-04 Thread Anthony Liguori
On 10/04/2011 06:13 AM, pingf...@linux.vnet.com wrote: From: Liu Ping Fanpingf...@linux.vnet.ibm.com Separate apic from qbus to icc bus which supports hotplug feature. And make the creation of apic as part of cpu initialization, so apic's state has been ready, before setting kvm_apic.

[Qemu-devel] [PATCH] runstate: add more valid transitions

2011-10-04 Thread Paolo Bonzini
This patch adds more valid transitions to the table, and avoids that the VM remains stuck in RSTATE_SAVEVM state when savevm is done on a paused virtual machine. Signed-off-by: Paolo Bonzini pbonz...@redhat.com --- savevm.c | 11 --- vl.c |5 + 2 files changed, 13

[Qemu-devel] [PATCH v2] runstate: add more valid transitions

2011-10-04 Thread Paolo Bonzini
This patch adds more valid transitions to the table, and avoids that the VM remains stuck in RSTATE_SAVEVM state when savevm is done on a paused virtual machine. Signed-off-by: Paolo Bonzini pbonz...@redhat.com --- savevm.c |9 +++-- vl.c |5 + 2 files changed, 12

Re: [Qemu-devel] KVM call agenda for October 4th

2011-10-04 Thread Juan Quintela
Juan Quintela quint...@redhat.com wrote: Hi Please send in any agenda items you are interested in covering. As there is no agenda, this week call gets cancelled. Happy hacking, Juan.

Re: [Qemu-devel] s390: Fix cpu shutdown for KVM

2011-10-04 Thread Christian Borntraeger
Something like the following? s390: Fix cpu shutdown for KVM On s390 a shutdown is the state of all CPUs being either stopped or disabled (for interrupts) waiting. We have to track this number to call the shutdown sequence accordingly. This patch implements the counting and shutdown handling

Re: [Qemu-devel] [PATCH] runstate: do not discard runstate changes when paused

2011-10-04 Thread Luiz Capitulino
On Tue, 4 Oct 2011 14:04:45 +0200 Paolo Bonzini pbonz...@redhat.com wrote: Trying to migrate a paused machine fails. The reason is that the RSTATE_PRE_MIGRATE is reached with vm_stop, and this transition is eaten when the vm is already paused. This patch fixes the problem by always going

Re: [Qemu-devel] [PATCH 0/1] Make the help info more friendly in monitor

2011-10-04 Thread Luiz Capitulino
On Wed, 28 Sep 2011 10:16:19 +0100 Stefan Hajnoczi stefa...@gmail.com wrote: On Wed, Sep 28, 2011 at 10:00 AM, Wayne Xia xiaw...@linux.vnet.ibm.com wrote: During my test, I found it inconvenient when I type help or help info, because the information was shown without orderliness. This

Re: [Qemu-devel] s390: Fix cpu shutdown for KVM

2011-10-04 Thread Peter Maydell
On 4 October 2011 14:47, Christian Borntraeger borntrae...@de.ibm.com wrote: +     * We can only deliver interrupts to (interrupt) enabled CPUs. +     * We dont call kvm_s390_add_running_cpu here, since CPUs in enabled wait +     * will wait inside the kernel (no exit). Therefore, the targeted

Re: [Qemu-devel] [PATCH] runstate: do not discard runstate changes when paused

2011-10-04 Thread Paolo Bonzini
On 10/04/2011 03:49 PM, Luiz Capitulino wrote: There's a semantic change which I'm not completely sure it won't generate unexpected side-effects: today vm_stop() will only carry any action if the machine is running, otherwise it's no-op. This patch changes that. More or less, yes. I tried to

Re: [Qemu-devel] s390: Fix cpu shutdown for KVM

2011-10-04 Thread Christian Borntraeger
On 04/10/11 15:56, Peter Maydell wrote: On 4 October 2011 14:47, Christian Borntraeger borntrae...@de.ibm.com wrote: + * We can only deliver interrupts to (interrupt) enabled CPUs. + * We dont call kvm_s390_add_running_cpu here, since CPUs in enabled wait + * will wait inside the

Re: [Qemu-devel] [PATCH 05/23] migration: Refactor MigrationState creation

2011-10-04 Thread Anthony Liguori
On 09/23/2011 07:56 AM, Juan Quintela wrote: Signed-off-by: Juan Quintelaquint...@redhat.com --- migration-exec.c | 16 +--- migration-fd.c | 16 +--- migration-tcp.c | 15 +-- migration-unix.c | 15 +-- migration.c | 29

Re: [Qemu-devel] [PATCH 14/23] migration: Move exported functions to the end of the file

2011-10-04 Thread Anthony Liguori
On 09/23/2011 07:57 AM, Juan Quintela wrote: This means we can remove the two forward declarations. Signed-off-by: Juan Quintelaquint...@redhat.com Reviewed-by: Anthony Liguori aligu...@us.ibm.com Regards, Anthony Liguori --- migration.c | 188

[Qemu-devel] [PATCH] i386: wire up MSR_IA32_MISC_ENABLE

2011-10-04 Thread Avi Kivity
It's needed for its default value - bit 0 specifies that rep movs is good enough for memcpy, and Linux may use a slower memcpu if it is not set, depending on cpu family/model. Signed-off-by: Avi Kivity a...@redhat.com --- target-i386/cpu.h |5 + target-i386/helper.c|1 +

Re: [Qemu-devel] [PATCH 15/23] migration: use global variable directly

2011-10-04 Thread Anthony Liguori
On 09/23/2011 07:57 AM, Juan Quintela wrote: We are setting a pointer to a local variable in the previous line, just use the global variable directly. We remove the -file test because it is already done inside qemu_file_set_rate_limit() function. Signed-off-by: Juan Quintelaquint...@redhat.com

Re: [Qemu-devel] [PATCH 17/23] migration: make sure we always have a migration state

2011-10-04 Thread Anthony Liguori
On 09/23/2011 07:57 AM, Juan Quintela wrote: This cleans up a lot the code as we don't have to check anymore if the variable is NULL or not. We don't make it static, because when we integrate fault tolerance, we can have several migrations at once. Signed-off-by: Juan

Re: [Qemu-devel] [PATCH 18/23] migration: Use bandwidth_limit directly

2011-10-04 Thread Anthony Liguori
On 09/23/2011 07:57 AM, Juan Quintela wrote: Now that current_migration always exist, there is no reason for max_throotle variable. Signed-off-by: Juan Quintelaquint...@redhat.com If we can have multiple MigrationStates, this doesn't really make sense. Regards, Anthony Liguori ---

Re: [Qemu-devel] [PATCH] runstate: do not discard runstate changes when paused

2011-10-04 Thread Luiz Capitulino
On Tue, 04 Oct 2011 16:09:03 +0200 Paolo Bonzini pbonz...@redhat.com wrote: On 10/04/2011 03:49 PM, Luiz Capitulino wrote: There's a semantic change which I'm not completely sure it won't generate unexpected side-effects: today vm_stop() will only carry any action if the machine is

Re: [Qemu-devel] [PATCH 19/23] migration: Export a function that tells if the migration has finished correctly

2011-10-04 Thread Anthony Liguori
On 09/23/2011 07:57 AM, Juan Quintela wrote: This will allows us to hide the status values. Signed-off-by: Juan Quintelaquint...@redhat.com --- migration.c |4 ++-- migration.h |2 +- ui/spice-core.c |4 +--- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git

Re: [Qemu-devel] [PATCH 21/23] migration: Don't use callback on file defining it

2011-10-04 Thread Anthony Liguori
On 09/23/2011 07:57 AM, Juan Quintela wrote: Signed-off-by: Juan Quintelaquint...@redhat.com I don't think this is better. It just eliminates the possibility of having useful trace points in get_error. Regards, Anthony Liguori --- migration-tcp.c |4 ++-- migration-unix.c |6

Re: [Qemu-devel] [PATCH 22/23] migration: propagate error correctly

2011-10-04 Thread Anthony Liguori
On 09/23/2011 07:57 AM, Juan Quintela wrote: unix and tcp outgoing migration have error values, but didn't returned it. Make them return the error. Notice that EINPROGRESS EWOULDBLOCK are not considered errors as callwill be retry later. Signed-off-by: Juan Quintelaquint...@redhat.com

Re: [Qemu-devel] [PATCH 23/23] migration: make migration-{tcp, unix} consistent

2011-10-04 Thread Anthony Liguori
On 09/23/2011 07:57 AM, Juan Quintela wrote: Files are almost identical in functionality, just remove the differences that make no sense. Signed-off-by: Juan Quintelaquint...@redhat.com Reviewed-by: Anthony Liguori aligu...@us.ibm.com Regards, Anthony Liguori --- migration-tcp.c | 15

Re: [Qemu-devel] [PATCH v3 00/23] Refactor and cleanup migration code

2011-10-04 Thread Anthony Liguori
I peeled off the first 4 patches to apply. Once I finish testing I'll push them. Most of the rest of the series looks good. I really don't like making MigrationState nullable with MIG_STATE_NONE. I don't think it makes sense with multiple MigrationStates. The direct use of globals is not

Re: [Qemu-devel] s390: Fix cpu shutdown for KVM

2011-10-04 Thread Alexander Graf
On 10/04/2011 03:47 PM, Christian Borntraeger wrote: Something like the following? s390: Fix cpu shutdown for KVM On s390 a shutdown is the state of all CPUs being either stopped or disabled (for interrupts) waiting. We have to track this number to call the shutdown sequence accordingly. This

[Qemu-devel] [PATCH 1/4] savevm: teach qemu_fill_buffer to do partial refills

2011-10-04 Thread Juan Quintela
We will need on next patch to be able to lookahead on next patch Signed-off-by: Juan Quintela quint...@redhat.com --- savevm.c | 14 +++--- 1 files changed, 11 insertions(+), 3 deletions(-) diff --git a/savevm.c b/savevm.c index 46f2447..31131df 100644 --- a/savevm.c +++ b/savevm.c @@

[Qemu-devel] [PATCH 2/4] savevm: some coding style cleanups

2011-10-04 Thread Juan Quintela
This patch will make moving code on next patches and having checkpatch happy easier. Signed-off-by: Juan Quintela quint...@redhat.com --- savevm.c | 21 ++--- 1 files changed, 14 insertions(+), 7 deletions(-) diff --git a/savevm.c b/savevm.c index 31131df..5fee4e2 100644 ---

[Qemu-devel] [PATCH 4/4] Revert savevm: fix corruption in vmstate_subsection_load().

2011-10-04 Thread Juan Quintela
This reverts commit eb60260de0b050a5e8ab725e84d377d0b44c43ae. Conflicts: savevm.c We changed qemu_peek_byte() prototype, just fixed the rejects. Signed-off-by: Juan Quintela quint...@redhat.com --- savevm.c | 10 +- 1 files changed, 1 insertions(+), 9 deletions(-) diff

[Qemu-devel] [PATCH 0/4] migration: Improve subsections detection

2011-10-04 Thread Juan Quintela
Hi This series move the subsections detection code form: - Look that it starts form 5 To: - Look that it starts form 5 (SUBSECTION) - Look at the length - Look that length is bigger than section name - Look at the idstr and see that it starts with the subsection name. Please review. Later,

Re: [Qemu-devel] [PATCH 05/23] migration: Refactor MigrationState creation

2011-10-04 Thread Juan Quintela
Anthony Liguori anth...@codemonkey.ws wrote: On 09/23/2011 07:56 AM, Juan Quintela wrote: Signed-off-by: Juan Quintelaquint...@redhat.com I think this would fit better if it were migrate_new() or migrate_open(). It definitely should be in the form noun_verb and not noun_verb_noun().

Re: [Qemu-devel] [PATCH 15/23] migration: use global variable directly

2011-10-04 Thread Juan Quintela
Anthony Liguori anth...@codemonkey.ws wrote: How about we compromise and add a: MigrationState *migrate_get_current(void); I can agree with this one. I'm strongly opposed to propagating direct usage of a global. If it's at least a function call, that's a bit nicer. What I am against is

Re: [Qemu-devel] [PATCH 17/23] migration: make sure we always have a migration state

2011-10-04 Thread Juan Quintela
Anthony Liguori anth...@codemonkey.ws wrote: On 09/23/2011 07:57 AM, Juan Quintela wrote: This cleans up a lot the code as we don't have to check anymore if the variable is NULL or not. We don't make it static, because when we integrate fault tolerance, we can have several migrations at

[Qemu-devel] [PATCH RFC V1 02/11] qemu-timer: Introduce qemu_run_one_timer

2011-10-04 Thread Anthony PERARD
Used by the Xen PCI Passthrough code to run the timer about the power state transition. Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- qemu-timer.c | 15 +++ qemu-timer.h |3 +++ 2 files changed, 18 insertions(+), 0 deletions(-) diff --git a/qemu-timer.c

[Qemu-devel] [PATCH RFC V1 01/11] Introduce HostPCIDevice to access a pci device on the host.

2011-10-04 Thread Anthony PERARD
Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- hw/host-pci-device.c | 192 ++ hw/host-pci-device.h | 36 + 2 files changed, 228 insertions(+), 0 deletions(-) create mode 100644 hw/host-pci-device.c create mode 100644

[Qemu-devel] [PATCH RFC V1 11/11] config/make: Introduce --enable-xen-pci-passthrough, built it.

2011-10-04 Thread Anthony PERARD
Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- Makefile.target |7 +++ configure | 21 + 2 files changed, 28 insertions(+), 0 deletions(-) diff --git a/Makefile.target b/Makefile.target index f708453..b5fbc18 100644 --- a/Makefile.target +++

[Qemu-devel] [PATCH RFC V1 10/11] Introduce Xen PCI Passthrough, MSI (3/3)

2011-10-04 Thread Anthony PERARD
Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- hw/xen_pci_passthrough_msi.c | 674 ++ 1 files changed, 674 insertions(+), 0 deletions(-) create mode 100644 hw/xen_pci_passthrough_msi.c diff --git a/hw/xen_pci_passthrough_msi.c

[Qemu-devel] [PATCH RFC V1 08/11] Introduce Xen PCI Passthrough, qdevice (1/3)

2011-10-04 Thread Anthony PERARD
Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- hw/xen_pci_passthrough.c | 763 ++ hw/xen_pci_passthrough.h | 335 + hw/xen_pci_passthrough_helpers.c | 46 +++ 3 files changed, 1144 insertions(+), 0 deletions(-)

[Qemu-devel] [PATCH RFC V1 06/11] pci.c: Add pci_check_bar_overlap

2011-10-04 Thread Anthony PERARD
This function help Xen PCI Passthrough device to check for overlap. Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- hw/pci.c | 46 ++ hw/pci.h |3 +++ 2 files changed, 49 insertions(+), 0 deletions(-) diff --git a/hw/pci.c b/hw/pci.c

Re: [Qemu-devel] [PATCH 05/23] migration: Refactor MigrationState creation

2011-10-04 Thread Anthony Liguori
On 10/04/2011 09:44 AM, Juan Quintela wrote: Anthony Liguorianth...@codemonkey.ws wrote: On 09/23/2011 07:56 AM, Juan Quintela wrote: Signed-off-by: Juan Quintelaquint...@redhat.com I think this would fit better if it were migrate_new() or migrate_open(). It definitely should be in the

Re: [Qemu-devel] [Xen-devel] [PATCH RFC V1 00/11] Xen PCI Passthrough

2011-10-04 Thread Avi Kivity
On 10/04/2011 04:51 PM, Anthony PERARD wrote: Hi all, This patch series introduce the PCI passthrough for Xen. First, we have HostPCIDevice that help to access one PCI device of the host. Then, there are several additions in the QEMU code. One is qemu_run_one_timer to run a specific timer. It

Re: [Qemu-devel] [Xen-devel] [PATCH RFC V1 00/11] Xen PCI Passthrough

2011-10-04 Thread Anthony Liguori
On 10/04/2011 09:58 AM, Avi Kivity wrote: On 10/04/2011 04:51 PM, Anthony PERARD wrote: Hi all, This patch series introduce the PCI passthrough for Xen. First, we have HostPCIDevice that help to access one PCI device of the host. Then, there are several additions in the QEMU code. One is

Re: [Qemu-devel] [Xen-devel] [PATCH RFC V1 00/11] Xen PCI Passthrough

2011-10-04 Thread Stefano Stabellini
On Tue, 4 Oct 2011, Anthony Liguori wrote: On 10/04/2011 09:58 AM, Avi Kivity wrote: On 10/04/2011 04:51 PM, Anthony PERARD wrote: Hi all, This patch series introduce the PCI passthrough for Xen. First, we have HostPCIDevice that help to access one PCI device of the host. Then,

Re: [Qemu-devel] [PATCH] Make cpu_single_env thread local (Linux only for now)

2011-10-04 Thread Lluís Vilanova
Jan Kiszka writes: On 2011-10-03 18:33, Dr. David Alan Gilbert wrote: Make cpu_single_env thread local (Linux only for now) * Fixes some user space threading issues (esp those triggered by bug 823902) Against rev d11cf8cc..., tested on ARM user mode, and ARM Vexpress system mode (with

Re: [Qemu-devel] [PATCH 0/4] migration: Improve subsections detection

2011-10-04 Thread Paolo Bonzini
On 10/04/2011 04:38 PM, Juan Quintela wrote: Hi This series move the subsections detection code form: - Look that it starts form 5 To: - Look that it starts form 5 (SUBSECTION) - Look at the length - Look that length is bigger than section name - Look at the idstr and see that it starts with

[Qemu-devel] [PATCH] ppc64: Fix linker script

2011-10-04 Thread Andreas Färber
Since commit 8733f609 (Fix linker scripts) linking on Linux/ppc64 fails: LINK ppc64-linux-user/qemu-ppc64 /usr/lib64/gcc/powerpc64-suse-linux/4.3/../../../../powerpc64-suse-linux/bin/ld:/home/afaerber/qemu/ppc64.ld:84: syntax error collect2: ld gab 1 als Ende-Status zurück make[1]: ***

Re: [Qemu-devel] [Qemu-ppc] [PATCH] ppc64: Fix linker script

2011-10-04 Thread Alexander Graf
On 10/04/2011 05:14 PM, Andreas Färber wrote: Since commit 8733f609 (Fix linker scripts) linking on Linux/ppc64 fails: LINK ppc64-linux-user/qemu-ppc64 /usr/lib64/gcc/powerpc64-suse-linux/4.3/../../../../powerpc64-suse-linux/bin/ld:/home/afaerber/qemu/ppc64.ld:84: syntax error collect2: ld

[Qemu-devel] [PATCH RFC V1 04/11] pci_regs: Fix value of PCI_EXP_TYPE_RC_EC.

2011-10-04 Thread Anthony PERARD
Value check in PCI Express Base Specification rev 1.1 Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- hw/pci_regs.h |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/hw/pci_regs.h b/hw/pci_regs.h index e884096..dad7d9a 100644 --- a/hw/pci_regs.h +++

[Qemu-devel] [PATCH RFC V1 00/11] Xen PCI Passthrough

2011-10-04 Thread Anthony PERARD
Hi all, This patch series introduce the PCI passthrough for Xen. First, we have HostPCIDevice that help to access one PCI device of the host. Then, there are several additions in the QEMU code. One is qemu_run_one_timer to run a specific timer. It is used by PCI passthrough to run a timer about

[Qemu-devel] [PATCH RFC V1 05/11] pci_regs: Add PCI_EXP_TYPE_PCIE_BRIDGE

2011-10-04 Thread Anthony PERARD
Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- hw/pci_regs.h |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/hw/pci_regs.h b/hw/pci_regs.h index dad7d9a..091a749 100644 --- a/hw/pci_regs.h +++ b/hw/pci_regs.h @@ -391,6 +391,7 @@ #define

[Qemu-devel] [PATCH RFC V1 07/11] host-pci-device: Add host_pci_find_ext_cap_offset

2011-10-04 Thread Anthony PERARD
Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- hw/host-pci-device.c | 31 +++ hw/host-pci-device.h |2 ++ 2 files changed, 33 insertions(+), 0 deletions(-) diff --git a/hw/host-pci-device.c b/hw/host-pci-device.c index b3f2899..2a889d5 100644 ---

Re: [Qemu-devel] [PATCH] ppc64: Fix linker script

2011-10-04 Thread Richard Henderson
On 10/04/2011 08:14 AM, Andreas Färber wrote: Since commit 8733f609 (Fix linker scripts) linking on Linux/ppc64 fails: It occurs to me to wonder if we ought to simply auto-detect the presence of the -Ttext-segment ADDR option. If that's present, don't override the linker script and all the

[Qemu-devel] [PATCH RFC V1 03/11] pci_ids: Add INTEL_82599_VF id.

2011-10-04 Thread Anthony PERARD
Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- hw/pci_ids.h |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/hw/pci_ids.h b/hw/pci_ids.h index 83f3893..2ea5ec2 100644 --- a/hw/pci_ids.h +++ b/hw/pci_ids.h @@ -117,6 +117,7 @@ #define

[Qemu-devel] [PATCH 3/4] savevm: improve subsections detection on load

2011-10-04 Thread Juan Quintela
We add qemu_peek_buffer, that is identical to qemu_get_buffer, just that it don't update f-buf_index. We add a paramenter to qemu_peek_byte() to be able to peek more than one byte. Once this is done, to see if we have a subsection we look: - 1st byte is QEMU_VM_SUBSECTION - 2nd byte is a length,

Re: [Qemu-devel] [PATCHv3] s390: Fix cpu shutdown for KVM

2011-10-04 Thread Alexander Graf
On 10/04/2011 05:20 PM, Christian Borntraeger wrote: On s390 a shutdown is the state of all CPUs being either stopped or disabled (for interrupts) waiting. We have to track the overall number of running CPUs to call the shutdown sequence accordingly. This patch implements the counting and

Re: [Qemu-devel] [Qemu-ppc] [PATCH 2/2] tcg/ppc*: Move cache initialization to ppc specific code

2011-10-04 Thread Scott Wood
On 10/04/2011 12:55 AM, Stefan Weil wrote: Am 03.10.2011 23:40, schrieb Scott Wood: The interface isn't powerpc-specific. It just happens to be the only arch so far that qemu supports that needs the implementation to do something (or possibly just the only one where that need has been

Re: [Qemu-devel] [PATCH] i386: wire up MSR_IA32_MISC_ENABLE

2011-10-04 Thread Jan Kiszka
On 2011-10-04 16:26, Avi Kivity wrote: It's needed for its default value - bit 0 specifies that rep movs is good enough for memcpy, and Linux may use a slower memcpu if it is not set, depending on cpu family/model. Signed-off-by: Avi Kivity a...@redhat.com --- target-i386/cpu.h |

[Qemu-devel] [PATCH 1/2] hda: do not mix output and input streams, RHBZ #740493

2011-10-04 Thread Marc-André Lureau
Windows 7 may use the same stream number for input and output. That will result in lot of garbage on playback. The hardcoded value of 4 needs to be in sync with GCAP streams description and IN/OUT registers. --- hw/intel-hda.c |9 + 1 files changed, 5 insertions(+), 4 deletions(-)

[Qemu-devel] [PATCH 2/2] hda: do not mix output and input stream states, RHBZ #740493

2011-10-04 Thread Marc-André Lureau
Windows 7 may use the same stream number for input and output. Current code will confuse streams. NB: I wonder if this patch breaks migration code because of this change: -VMSTATE_BOOL_ARRAY(running, HDAAudioState, 16), +VMSTATE_BOOL_ARRAY(running, HDAAudioState, 2 * 16), ---

Re: [Qemu-devel] [Xen-devel] [PATCH RFC V1 00/11] Xen PCI Passthrough

2011-10-04 Thread Alex Williamson
On Tue, 2011-10-04 at 16:05 +0100, Stefano Stabellini wrote: On Tue, 4 Oct 2011, Anthony Liguori wrote: On 10/04/2011 09:58 AM, Avi Kivity wrote: On 10/04/2011 04:51 PM, Anthony PERARD wrote: Hi all, This patch series introduce the PCI passthrough for Xen. First, we have

Re: [Qemu-devel] build errors on s390 tcg

2011-10-04 Thread Stefan Weil
Am 04.10.2011 14:44, schrieb Peter Maydell: On 4 October 2011 13:23, Alexander Graf ag...@suse.de wrote: The problem is that tcg.c defines the functions with int arguments for TCG register indexes, while s390/tcg-target.c takes TCGReg parameters. I'm not sure which way is better, but using

Re: [Qemu-devel] [PATCH 2/2] LAPIC: make lapic support cpu hotplug

2011-10-04 Thread Jan Kiszka
On 2011-10-04 13:13, pingf...@linux.vnet.com wrote: From: Liu Ping Fan pingf...@linux.vnet.ibm.com Separate apic from qbus to icc bus which supports hotplug feature. Modeling the ICC bus looks like a step in the right direction. The IOAPIC could be attached to it as well to get rid of

Re: [Qemu-devel] [Xen-devel] [PATCH RFC V1 00/11] Xen PCI Passthrough

2011-10-04 Thread Stefano Stabellini
On Tue, 4 Oct 2011, Alex Williamson wrote: On Tue, 2011-10-04 at 16:05 +0100, Stefano Stabellini wrote: On Tue, 4 Oct 2011, Anthony Liguori wrote: On 10/04/2011 09:58 AM, Avi Kivity wrote: On 10/04/2011 04:51 PM, Anthony PERARD wrote: Hi all, This patch series introduce the

Re: [Qemu-devel] [Xen-devel] [PATCH RFC V1 00/11] Xen PCI Passthrough

2011-10-04 Thread Avi Kivity
On 10/04/2011 06:33 PM, Alex Williamson wrote: I thought we were potentially looking at vfio as a convergence point. I'm still a bit off from having a vfio re-write ready to submit, but is this still a possibility? Thanks, vfio leaves out users of current and past kernels; relying on it

Re: [Qemu-devel] [Xen-devel] [PATCH RFC V1 00/11] Xen PCI Passthrough

2011-10-04 Thread Avi Kivity
On 10/04/2011 05:01 PM, Anthony Liguori wrote: We also have pci passthrough in qemu-kvm (I think based on the same Neocleus code). Rather than having two pci assignment implementations, I think we should have just one, with the differences (programming the hypervisor) abstracted at that

Re: [Qemu-devel] [PATCH] i386: wire up MSR_IA32_MISC_ENABLE

2011-10-04 Thread Avi Kivity
On 10/04/2011 06:05 PM, Jan Kiszka wrote: On 2011-10-04 16:26, Avi Kivity wrote: It's needed for its default value - bit 0 specifies that rep movs is good enough for memcpy, and Linux may use a slower memcpu if it is not set, depending on cpu family/model. Signed-off-by: Avi

Re: [Qemu-devel] [PATCH] i386: wire up MSR_IA32_MISC_ENABLE

2011-10-04 Thread Jan Kiszka
On 2011-10-04 19:08, Avi Kivity wrote: On 10/04/2011 06:05 PM, Jan Kiszka wrote: On 2011-10-04 16:26, Avi Kivity wrote: It's needed for its default value - bit 0 specifies that rep movs is good enough for memcpy, and Linux may use a slower memcpu if it is not set, depending on cpu

Re: [Qemu-devel] [PATCH] i386: wire up MSR_IA32_MISC_ENABLE

2011-10-04 Thread Avi Kivity
On 10/04/2011 07:14 PM, Jan Kiszka wrote: + +static const VMStateDescription vmstate_msr_ia32_misc_enable = { +.name = cpu/msr_ia32_misc_enable, +.version_id = 1, +.minimum_version_id = 1, +.minimum_version_id_old = 1, +.fields =

Re: [Qemu-devel] [Xen-devel] [PATCH RFC V1 00/11] Xen PCI Passthrough

2011-10-04 Thread Jan Kiszka
On 2011-10-04 17:01, Anthony Liguori wrote: On 10/04/2011 09:58 AM, Avi Kivity wrote: On 10/04/2011 04:51 PM, Anthony PERARD wrote: Hi all, This patch series introduce the PCI passthrough for Xen. First, we have HostPCIDevice that help to access one PCI device of the host. Then, there

Re: [Qemu-devel] [PATCH 2/2] hda: do not mix output and input stream states, RHBZ #740493

2011-10-04 Thread Juan Quintela
Marc-André Lureau marcandre.lur...@gmail.com wrote: Windows 7 may use the same stream number for input and output. Current code will confuse streams. NB: I wonder if this patch breaks migration code because of this change: -VMSTATE_BOOL_ARRAY(running, HDAAudioState, 16), +

Re: [Qemu-devel] [PATCH] i386: wire up MSR_IA32_MISC_ENABLE

2011-10-04 Thread Jan Kiszka
On 2011-10-04 19:21, Avi Kivity wrote: On 10/04/2011 07:14 PM, Jan Kiszka wrote: + +static const VMStateDescription vmstate_msr_ia32_misc_enable = { +.name = cpu/msr_ia32_misc_enable, +.version_id = 1, +.minimum_version_id = 1, +

Re: [Qemu-devel] [PATCH] Make cpu_single_env thread local (Linux only for now)

2011-10-04 Thread Jan Kiszka
On 2011-10-04 17:10, Lluís Vilanova wrote: Jan Kiszka writes: On 2011-10-03 18:33, Dr. David Alan Gilbert wrote: Make cpu_single_env thread local (Linux only for now) * Fixes some user space threading issues (esp those triggered by bug 823902) Against rev d11cf8cc..., tested on ARM user

Re: [Qemu-devel] [PATCH RFC V1 02/11] qemu-timer: Introduce qemu_run_one_timer

2011-10-04 Thread Jan Kiszka
On 2011-10-04 16:51, Anthony PERARD wrote: Used by the Xen PCI Passthrough code to run the timer about the power state transition. Signed-off-by: Anthony PERARD anthony.per...@citrix.com --- qemu-timer.c | 15 +++ qemu-timer.h |3 +++ 2 files changed, 18 insertions(+),

Re: [Qemu-devel] [PATCH] i386: wire up MSR_IA32_MISC_ENABLE

2011-10-04 Thread Avi Kivity
On 10/04/2011 07:24 PM, Jan Kiszka wrote: Given that, when in conflict, we rather model after AMD than Intel for TCG, I would hesitate to expose this by default. Or are there precedences already? Practically all MSRs. i486 doesn't have any, IIRC, for example. Pre-Pentiums don't have

  1   2   >