Re: [Qemu-devel] [PATCH 2/2] qtest: use synchronous I/O for char device

2013-03-27 Thread Wenchao Xia
Reviewed-by: Wenchao Xia > Peter reported that rtc-test would periodically hang. It turns out > this was due to an EAGAIN occurring on qemu_chr_fe_write. > > Instead of heavily refactoring qtest, just use a synchronous version > of the write operation for qemu_chr_fe_write to address this probl

Re: [Qemu-devel] [PATCH 1/2] char: introduce a blocking version of qemu_chr_fe_write

2013-03-27 Thread Wenchao Xia
于 2013-3-26 23:21, Peter Maydell 写道: On 26 March 2013 15:11, Anthony Liguori wrote: +int qemu_chr_fe_write_all(CharDriverState *s, const uint8_t *buf, int len) +{ +int offset = 0; +int res; + +while (offset < len) { +do { +res = s->chr_write(s, buf + offset, len

Re: [Qemu-devel] [RFC PATCH v4 00/30] ACPI memory hotplug

2013-03-27 Thread li guang
在 2013-03-26二的 11:20 -0300,Eduardo Habkost写道: > On Wed, Mar 20, 2013 at 02:18:00PM +0800, li guang wrote: > > 在 2013-01-09三的 01:08 +0100,Andreas Färber写道: > > > Am 18.12.2012 13:41, schrieb Vasilis Liaskovitis: > > > > Because dimm layout needs to be configured on machine-boot, all dimm > > > > de

Re: [Qemu-devel] Qemu-devel Digest, Vol 120, Issue 887

2013-03-27 Thread Haitham Zuriq
Sent from Samsung tablet Original message From: qemu-devel-requ...@nongnu.org Date: 27/03/2013 9:12 AM (GMT+03:00) To: qemu-devel@nongnu.org Subject: Qemu-devel Digest, Vol 120, Issue 887 Send Qemu-devel mailing list submissions to qemu-devel@nongnu.org To subscribe

Re: [Qemu-devel] [patch]Make GTK build on OS X

2013-03-27 Thread Paolo Bonzini
Il 26/03/2013 23:16, C.W. Betts ha scritto: > This patch makes the GTK UI build on OS X by including the right headers. > > > > From b5cc84343f479d4870961c82fc7b384637e9616c Mon Sep 17 00:00:00 2001 > From: "C.W. Betts" > Date: Sun, 24 Mar 2013 11:24:05 -0600 > Subject: [PATCH 1/3] Make the GTK

Re: [Qemu-devel] [PATCH 0/4] monitor: do not rely on O_NONBLOCK for passed file descriptors

2013-03-27 Thread liu ping fan
On Wed, Mar 27, 2013 at 12:07 AM, Stefan Hajnoczi wrote: > There are several places where QEMU accidentally relies on the O_NONBLOCK > state > of passed file descriptors. Exposing O_NONBLOCK state makes it part of the > QMP If in future, we push more backend on their dedicated thread, will the

Re: [Qemu-devel] [PATCH 0/5] Add some tracepoints for clarification of the cause of troubles

2013-03-27 Thread Paolo Bonzini
> > Wouldn't you get the same information from the command line? > > I think the information you said is different from what I meant. The > information I wanted to know is whether QEMU creates/deletes a device > successfully or not. Failing to create a device will always exit QEMU. If you canno

Re: [Qemu-devel] [RFC 1/4] block: fix I/O throttling accounting blind spot

2013-03-27 Thread Zhi Yong Wu
On Thu, Mar 21, 2013 at 10:49 PM, Stefan Hajnoczi wrote: > I/O throttling relies on bdrv_acct_done() which is called when a request > completes. This leaves a blind spot since we only charge for completed > requests, not submitted requests. > > For example, if there is 1 operation remaining in th

Re: [Qemu-devel] [PATCH 0/4] monitor: do not rely on O_NONBLOCK for passed file descriptors

2013-03-27 Thread Stefan Hajnoczi
On Wed, Mar 27, 2013 at 04:37:52PM +0800, liu ping fan wrote: > On Wed, Mar 27, 2013 at 12:07 AM, Stefan Hajnoczi wrote: > > There are several places where QEMU accidentally relies on the O_NONBLOCK > > state > > of passed file descriptors. Exposing O_NONBLOCK state makes it part of the > > QMP

[Qemu-devel] [PATCH v2 0/4] monitor: do not rely on O_NONBLOCK for passed file descriptors

2013-03-27 Thread Stefan Hajnoczi
There are several places where QEMU accidentally relies on the O_NONBLOCK state of passed file descriptors. Exposing O_NONBLOCK state makes it part of the QMP API whenever getfd or fdset_add_fd are used! Whether or not QEMU will use O_NONBLOCK is an implementation detail and should be hidden from

[Qemu-devel] [PATCH v2 1/4] oslib-posix: rename socket_set_nonblock() to qemu_set_nonblock()

2013-03-27 Thread Stefan Hajnoczi
The fcntl(fd, F_SETFL, O_NONBLOCK) flag is not specific to sockets. Rename to qemu_set_nonblock() just like qemu_set_cloexec(). Signed-off-by: Stefan Hajnoczi --- block/nbd.c| 2 +- block/sheepdog.c | 2 +- include/qemu/sockets.h | 4 ++-- migration.c| 2 +- nbd.c

[Qemu-devel] [PATCH v2 3/4] qemu-socket: set passed fd non-blocking in socket_connect()

2013-03-27 Thread Stefan Hajnoczi
socket_connect() sets non-blocking on TCP or UNIX domain sockets if a callback function is passed. Do the same for file descriptor passing, otherwise we could unexpectedly be using a blocking file descriptor. Signed-off-by: Stefan Hajnoczi --- util/qemu-sockets.c | 1 + 1 file changed, 1 insert

[Qemu-devel] [PATCH v2 4/4] chardev: clear O_NONBLOCK on SCM_RIGHTS file descriptors

2013-03-27 Thread Stefan Hajnoczi
When we receive a file descriptor over a UNIX domain socket the O_NONBLOCK flag is preserved. Clear the O_NONBLOCK flag and rely on QEMU file descriptor users like migration, SPICE, VNC, block layer, and others to set non-blocking only when necessary. This change ensures we don't accidentally exp

[Qemu-devel] [PATCH v2 2/4] net: ensure "socket" backend uses non-blocking fds

2013-03-27 Thread Stefan Hajnoczi
There are several code paths in net_init_socket() depending on how the socket is created: file descriptor passing, UDP multicast, TCP, or UDP. Some of these support both listen and connect. Not all code paths set the socket to non-blocking. This patch addresses the file descriptor passing and UDP

Re: [Qemu-devel] [RFC 1/4] block: fix I/O throttling accounting blind spot

2013-03-27 Thread Stefan Hajnoczi
On Wed, Mar 27, 2013 at 9:50 AM, Zhi Yong Wu wrote: > On Thu, Mar 21, 2013 at 10:49 PM, Stefan Hajnoczi wrote: >> I/O throttling relies on bdrv_acct_done() which is called when a request >> completes. This leaves a blind spot since we only charge for completed >> requests, not submitted requests

[Qemu-devel] [PATCH v3 1/6] virtio-balloon: add the virtio-balloon device.

2013-03-27 Thread fred . konrad
From: KONRAD Frederic Create virtio-balloon which extends virtio-device, so it can be connected on virtio-bus. Signed-off-by: KONRAD Frederic --- hw/virtio-balloon.c | 95 + hw/virtio-balloon.h | 4 +++ 2 files changed, 93 insertions(+), 6 d

[Qemu-devel] [PATCH v3 0/6] virtio-balloon refactoring.

2013-03-27 Thread fred . konrad
From: KONRAD Frederic This is the next part of virtio-refactoring. Basically it creates virtio-balloon device which extends virtio-device. Then a virtio-balloon can be connected on a virtio-bus. virtio-balloon-pci, virtio-balloon-ccw are created too, they extend respectively virtio-pci, virtio-c

[Qemu-devel] [PATCH v3 2/6] virtio-balloon-pci: switch to the new API.

2013-03-27 Thread fred . konrad
From: KONRAD Frederic Here the virtio-balloon-pci is modified for the new API. The device virtio-balloon-pci extends virtio-pci. It creates and connects a virtio-balloon during the init. The properties are not changed. Signed-off-by: KONRAD Frederic --- hw/virtio-pci.c | 111 ++

[Qemu-devel] [PATCH v3 5/6] virtio-balloon: cleanup: QOM casts.

2013-03-27 Thread fred . konrad
From: KONRAD Frederic As the virtio-balloon-pci is switched to the new API, we can use QOM casts. Signed-off-by: KONRAD Frederic --- hw/virtio-balloon.c | 43 --- hw/virtio-balloon.h | 2 +- 2 files changed, 21 insertions(+), 24 deletions(-) diff --git

[Qemu-devel] [PATCH v3 3/6] virtio-balloon-ccw: switch to the new API.

2013-03-27 Thread fred . konrad
From: KONRAD Frederic Here the virtio-balloon-ccw is modified for the new API. The device virtio-balloon-ccw extends virtio-ccw-device as before. It creates and connects a virtio-balloon during the init. The properties are not modified. Signed-off-by: KONRAD Frederic --- hw/s390x/virtio-ccw.c

[Qemu-devel] [PATCH v3 6/6] virtio-balloon: cleanup: remove qdev field.

2013-03-27 Thread fred . konrad
From: KONRAD Frederic The qdev field is no longer needed, just drop it. Signed-off-by: KONRAD Frederic --- hw/virtio-balloon.c | 1 - hw/virtio-balloon.h | 1 - 2 files changed, 2 deletions(-) diff --git a/hw/virtio-balloon.c b/hw/virtio-balloon.c index 38d2ee3..b382bd4 100644 --- a/hw/virtio

[Qemu-devel] [PATCH v3 4/6] virtio-balloon: cleanup: init and exit function.

2013-03-27 Thread fred . konrad
From: KONRAD Frederic This remove old init and exit function as they are no longer needed. Signed-off-by: KONRAD Frederic --- hw/virtio-balloon.c | 73 ++--- 1 file changed, 13 insertions(+), 60 deletions(-) diff --git a/hw/virtio-balloon.c b/hw

Re: [Qemu-devel] [PATCH 01/12] target-i386: consolidate error propagation in x86_cpu_realizefn()

2013-03-27 Thread Paolo Bonzini
Il 21/03/2013 15:28, Igor Mammedov ha scritto: > Signed-off-by: Igor Mammedov > --- > target-i386/cpu.c | 17 ++--- > 1 files changed, 10 insertions(+), 7 deletions(-) > > diff --git a/target-i386/cpu.c b/target-i386/cpu.c > index a0640db..e905bcf 100644 > --- a/target-i386/cpu.c >

Re: [Qemu-devel] [PATCH 06/12] target-i386: replace FROM_SYSBUS() with QOM type cast

2013-03-27 Thread Paolo Bonzini
Il 21/03/2013 15:28, Igor Mammedov ha scritto: > ... and define type name and type cast macro for kvmvapic according > to accepted convention. > > Signed-off-by: Igor Mammedov > --- > hw/i386/kvmvapic.c |7 +-- > 1 files changed, 5 insertions(+), 2 deletions(-) > > diff --git a/hw/i386/

Re: [Qemu-devel] [PATCH v2 21/21] qcow2: Gather clusters in a looping loop

2013-03-27 Thread Stefan Hajnoczi
On Tue, Mar 26, 2013 at 05:50:13PM +0100, Kevin Wolf wrote: > @@ -793,6 +793,13 @@ static int handle_dependencies(BlockDriverState *bs, > uint64_t guest_offset, > bytes = 0; > } > > +/* Stop if already an l2meta exists. We would have to consider > +

Re: [Qemu-devel] [PATCH v2 00/21] qcow2: Rework cluster allocation even more

2013-03-27 Thread Stefan Hajnoczi
On Tue, Mar 26, 2013 at 05:49:52PM +0100, Kevin Wolf wrote: > This is the start of the latest Delayed COW series. As there seem to be > serious > problems with the actual Delayed COW (which in fact exist today, but would > become a bit easier to hit) and I don't have the time to complete this at t

Re: [Qemu-devel] [PATCH 11/12] qmp: add cpu_set qmp command

2013-03-27 Thread Paolo Bonzini
Il 21/03/2013 15:28, Igor Mammedov ha scritto: > Signed-off-by: Igor Mammedov > --- > include/sysemu/sysemu.h |2 ++ > qapi-schema.json|9 + > qmp-commands.hx | 26 ++ > qmp.c | 12 > stubs/Makefile.objs

[Qemu-devel] [PATCH v3 21/21] qcow2: Gather clusters in a looping loop

2013-03-27 Thread Kevin Wolf
Instead of just checking once in exactly this order if there are dependendies, non-COW clusters and new allocation, this starts looping around these. This way we can, for example, gather non-COW clusters after new allocations as long as the host cluster offsets stay contiguous. Once handle_depende

Re: [Qemu-devel] [PATCH 10/12] acpi_piix4: add infrastructure to send CPU hot-plug GPE to guest

2013-03-27 Thread Paolo Bonzini
Il 21/03/2013 15:28, Igor Mammedov ha scritto: > * introduce processor status bitmask visible to guest at 0xaf00 addr, > where Seabios expects it > * set bit corresponding to APIC ID in processor status bitmask on > receiving CPU hot-plug notification > * trigger CPU hot-plug SCI, expected by S

Re: [Qemu-devel] [PATCH 07/12] target-i386: Add ICC_BUS and attach apic, kvmvapic and cpu to it

2013-03-27 Thread Paolo Bonzini
Il 21/03/2013 15:28, Igor Mammedov ha scritto: > Introduce hot-pluggable ICC_BUS and convert APIC devices from SysBusDevice > to ICCDevice wich has ICC_BUS as default one. > > * attach APIC and kvmvapic to ICC_BUS during creation > * use memory API directly instead of using SysBus proxy function

Re: [Qemu-devel] [PATCH 05/12] target-i386: push hot-plugged VCPU state to KVM and unstop it

2013-03-27 Thread Paolo Bonzini
Il 21/03/2013 15:28, Igor Mammedov ha scritto: > * synchronize CPU state to KVM > * resume CPU, it makes CPU be able to handle interrupts in TCG mode >and/or with user-space APIC. > > Signed-off-by: Igor Mammedov > --- > cpus.c| 11 --- > include/sysemu/cpus.h |

Re: [Qemu-devel] [PATCH 4/5] qdev: add qdev_{create, free} tracepoints

2013-03-27 Thread Andreas Färber
Am 22.03.2013 09:29, schrieb Kazuya Saito: > This patch adds tracepoints at creating and removing virtual > devices. It is useful for investigation of trouble related to virtual > devices. > > Signed-off-by: Kazuya Saito I would prefer not to do this. I had previously posted a patch to remove qd

Re: [Qemu-devel] [PATCH 08/12] introduce CPU hot-plug notifier

2013-03-27 Thread Paolo Bonzini
Il 21/03/2013 15:28, Igor Mammedov ha scritto: > hot-added CPU id (APIC ID) will be distributed to acpi_piix4 and rtc_cmos > > Signed-off-by: Igor Mammedov > --- > include/sysemu/sysemu.h |4 > stubs/Makefile.objs |1 + > stubs/qemu_system_cpu_hot

Re: [Qemu-devel] [PATCH 12/12] target-i386: implement CPU hot-add

2013-03-27 Thread Paolo Bonzini
Il 21/03/2013 15:28, Igor Mammedov ha scritto: > ... via do_cpu_hot_add() hook called by cpu_set QMP command, > for x86 target. > > * add extra check that APIC ID is in allowed range > * return error if CPU with requested APIC ID exists before creating > a new instance. (CPU removal is broken no

Re: [Qemu-devel] [RFC PATCH 04/10] qemu-ga: Add Windows VSS provider to quiesce applications on fsfreeze

2013-03-27 Thread Vadim Rozenfeld
On Tue, 2013-03-26 at 16:30 +, Tomoki Sekiyama wrote: > On 3/26/13 4:44 , "Vadim Rozenfeld" wrote: > > >On Tue, 2013-03-26 at 08:09 +0100, Paolo Bonzini wrote: > >> Il 25/03/2013 21:50, Tomoki Sekiyama ha scritto: > >>> Unfortunately, if I remove importlib("stdole2.tlb"), generated .tlb > >>>

Re: [Qemu-devel] Testing Linux user-mode with LTP

2013-03-27 Thread Peter Maydell
On 14 February 2013 11:22, Peter Maydell wrote: > On 8 February 2013 12:32, Peter Maydell wrote: >> Hi; I spent yesterday working out how to run the Linux Test >> Project's syscall test suite under QEMU's linux-user mode, >> and I wrote up the instructions here for other peoples' >> benefit: >>

Re: [Qemu-devel] [PATCH v2 0/4] monitor: do not rely on O_NONBLOCK for passed file descriptors

2013-03-27 Thread Eric Blake
On 03/27/2013 03:10 AM, Stefan Hajnoczi wrote: > There are several places where QEMU accidentally relies on the O_NONBLOCK > state > of passed file descriptors. Exposing O_NONBLOCK state makes it part of the > QMP > API whenever getfd or fdset_add_fd are used! > > Whether or not QEMU will use O

Re: [Qemu-devel] [PATCH v2] QOM-ify the TPM support

2013-03-27 Thread Paolo Bonzini
Il 26/03/2013 17:28, Stefan Berger ha scritto: > QOM-ified the TPM support with much code borrowed from the rng implementation. > > What's missing may be that the tpm/tpm_passthrough.c be moved into backends/ . > > Signed-off-by: Stefan Berger > > --- > v1->v2: > - followed to git revision e

Re: [Qemu-devel] [PATCH 05/12] target-i386: push hot-plugged VCPU state to KVM and unstop it

2013-03-27 Thread Igor Mammedov
On Wed, 27 Mar 2013 12:01:20 +0100 Paolo Bonzini wrote: > Il 21/03/2013 15:28, Igor Mammedov ha scritto: > > * synchronize CPU state to KVM > > * resume CPU, it makes CPU be able to handle interrupts in TCG mode > >and/or with user-space APIC. > > > > Signed-off-by: Igor Mammedov > > ---

Re: [Qemu-devel] [PATCH 05/12] target-i386: push hot-plugged VCPU state to KVM and unstop it

2013-03-27 Thread Andreas Färber
Am 27.03.2013 13:12, schrieb Igor Mammedov: > On Wed, 27 Mar 2013 12:01:20 +0100 > Paolo Bonzini wrote: > >> Il 21/03/2013 15:28, Igor Mammedov ha scritto: >>> diff --git a/target-i386/cpu.c b/target-i386/cpu.c >>> index d03ff73..631bcd8 100644 >>> --- a/target-i386/cpu.c >>> +++ b/target-i386/cp

Re: [Qemu-devel] [PATCH v2] QOM-ify the TPM support

2013-03-27 Thread Stefan Berger
On 03/27/2013 08:06 AM, Paolo Bonzini wrote: Il 26/03/2013 17:28, Stefan Berger ha scritto: QOM-ified the TPM support with much code borrowed from the rng implementation. What's missing may be that the tpm/tpm_passthrough.c be moved into backends/ . Signed-off-by: Stefan Berger --- v1->v2:

Re: [Qemu-devel] [PATCH 2/2] Monitor: Make output buffer dynamic

2013-03-27 Thread Luiz Capitulino
On Wed, 27 Mar 2013 14:45:53 +0800 Wenchao Xia wrote: > Hi, Luiz > Personally I hope reduce the dynamic allocated buffer which brings > fragments and unexpected memory grow. Instead, how about sacrifice > some time to wait output complete, since monitor is not time critical? > in this case stat

Re: [Qemu-devel] [PATCH v2 00/21] qcow2: Rework cluster allocation even more

2013-03-27 Thread Stefan Hajnoczi
On Tue, Mar 26, 2013 at 05:49:52PM +0100, Kevin Wolf wrote: > This is the start of the latest Delayed COW series. As there seem to be > serious > problems with the actual Delayed COW (which in fact exist today, but would > become a bit easier to hit) and I don't have the time to complete this at t

Re: [Qemu-devel] [PATCH v3 0/6] virtio-balloon refactoring.

2013-03-27 Thread Cornelia Huck
On Wed, 27 Mar 2013 10:49:09 +0100 fred.kon...@greensocs.com wrote: > From: KONRAD Frederic > > This is the next part of virtio-refactoring. > > Basically it creates virtio-balloon device which extends virtio-device. > Then a virtio-balloon can be connected on a virtio-bus. > virtio-balloon-pci

Re: [Qemu-devel] [RFC 1/4] block: fix I/O throttling accounting blind spot

2013-03-27 Thread Zhi Yong Wu
On Wed, Mar 27, 2013 at 5:14 PM, Stefan Hajnoczi wrote: > On Wed, Mar 27, 2013 at 9:50 AM, Zhi Yong Wu wrote: >> On Thu, Mar 21, 2013 at 10:49 PM, Stefan Hajnoczi >> wrote: >>> I/O throttling relies on bdrv_acct_done() which is called when a request >>> completes. This leaves a blind spot sinc

Re: [Qemu-devel] [RFC 0/4] block: fix I/O throttling oscillations

2013-03-27 Thread Zhi Yong Wu
They look good to me, but i have not done any test on my dev box, thanks for your fix. On Thu, Mar 21, 2013 at 10:49 PM, Stefan Hajnoczi wrote: > Benoît Canet reported that QEMU I/O throttling can > oscillate under continuous I/O. The test case runs 50 threads performing > random writes and a -

Re: [Qemu-devel] [PATCH 11/12 v3] qmp: add cpu-add qmp command

2013-03-27 Thread Luiz Capitulino
On Tue, 26 Mar 2013 17:47:42 +0100 Igor Mammedov wrote: > Signed-off-by: Igor Mammedov > --- > v3: > * it appears that 'online/offline' in cpu-set are confusing people > with what command actually does and users might have to distinguish > if 'offline' is not implemented by parsing err

Re: [Qemu-devel] [PATCH 0/4] monitor: do not rely on O_NONBLOCK for passed file descriptors

2013-03-27 Thread Juan Quintela
Stefan Hajnoczi wrote: > On Wed, Mar 27, 2013 at 04:37:52PM +0800, liu ping fan wrote: >> On Wed, Mar 27, 2013 at 12:07 AM, Stefan Hajnoczi >> wrote: >> > There are several places where QEMU accidentally relies on the >> > O_NONBLOCK state >> > of passed file descriptors. Exposing O_NONBLOCK st

[Qemu-devel] QCOW2 deduplication key value store

2013-03-27 Thread Benoît Canet
Hello, I am starting this thread so we can discuss of the choice of a good key/value store for the QCOW2 deduplication. One of the main goal is to keep the ratio between the number of cluster written and the number of dedup metadata io high. I initially though about taking the first two stages

Re: [Qemu-devel] [PATCH] VMXNET3: initialize rx_ridx to eliminate compile warning

2013-03-27 Thread Dmitry Fleytman
Hi, Wenchao Thanks for fixing this! Dmitry. On Tue, Mar 26, 2013 at 4:24 AM, Wenchao Xia wrote: > Gcc report "hw/vmxnet3.c:972: error: ‘rx_ridx’ may be used > uninitialized in this function", so fix it. > > Signed-off-by: Wenchao Xia > --- > hw/vmxnet3.c |2 +- > 1 files changed, 1 ins

Re: [Qemu-devel] [PATCH v2 0/4] monitor: do not rely on O_NONBLOCK for passed file descriptors

2013-03-27 Thread Luiz Capitulino
On Wed, 27 Mar 2013 10:10:42 +0100 Stefan Hajnoczi wrote: > There are several places where QEMU accidentally relies on the O_NONBLOCK > state > of passed file descriptors. Exposing O_NONBLOCK state makes it part of the > QMP > API whenever getfd or fdset_add_fd are used! > > Whether or not QE

Re: [Qemu-devel] [PATCH 05/12] target-i386: push hot-plugged VCPU state to KVM and unstop it

2013-03-27 Thread Igor Mammedov
On Wed, 27 Mar 2013 13:17:45 +0100 Andreas Färber wrote: > > Then I should move following parts to superclass: > > > > if (dev->hotplugged) { > > cpu_synchronize_post_init(env); > > resume_vcpu(CPU(cpu)); > > } > > > > because in case of KVM we should make sure that CPU i

[Qemu-devel] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Fabien Chouteau
From: gingold According to the PowePC 750 user's manual, the vector offset for system reset (both /HRESET and /SRESET) is 0x00100. Signed-off-by: Fabien Chouteau --- target-ppc/translate_init.c |8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/target-ppc/translate_

Re: [Qemu-devel] dataplane bug: fail to start Windows VM with dataplane enable

2013-03-27 Thread Stefan Hajnoczi
On Tue, Mar 26, 2013 at 11:10:35PM +0800, 张磊强 wrote: > Hi, Paolo && Stefan: > > When I test the dataplane feature with qemu master, I find that > Windows (Windows 7 and Windows 2003) VM will hang if dataplane is > enabled. But if I try to start a Fedora VM, it can start normally. > > The command

Re: [Qemu-devel] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Alexander Graf
On 27.03.2013, at 14:32, Fabien Chouteau wrote: > From: gingold What is this? :) Alex > > According to the PowePC 750 user's manual, the vector offset for system > reset (both /HRESET and /SRESET) is 0x00100. > > Signed-off-by: Fabien Chouteau > --- > target-ppc/translate_init.c |8 ++

[Qemu-devel] [PATCH] compiler: fix warning with GCC 4.8.0

2013-03-27 Thread Paolo Bonzini
GCC 4.8.0 introduces a new warning: block/qcow2-snapshot.c: In function 'qcow2_write_snapshots’: block/qcow2-snapshot.c:252:18: error: typedef 'qemu_build_bug_on__253' locally defined but not used [-Werror=unused-local-typedefs] QEMU_BUILD_BUG_ON(offsetof(QCowHeader,

Re: [Qemu-devel] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Fabien Chouteau
On 03/27/2013 02:34 PM, Alexander Graf wrote: > > On 27.03.2013, at 14:32, Fabien Chouteau wrote: > >> From: gingold > > What is this? :) > Oups :) Tristan Gingold is a colleague of mine. I'll fix this. -- Fabien Chouteau

Re: [Qemu-devel] [PATCH 0/4] monitor: do not rely on O_NONBLOCK for passed file descriptors

2013-03-27 Thread Stefan Hajnoczi
On Wed, Mar 27, 2013 at 02:06:36PM +0100, Juan Quintela wrote: > Stefan Hajnoczi wrote: > > On Wed, Mar 27, 2013 at 04:37:52PM +0800, liu ping fan wrote: > >> On Wed, Mar 27, 2013 at 12:07 AM, Stefan Hajnoczi > >> wrote: > >> > There are several places where QEMU accidentally relies on the > >>

[Qemu-devel] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Fabien Chouteau
According to the PowePC 750 user's manual, the vector offset for system reset (both /HRESET and /SRESET) is 0x00100. Signed-off-by: Fabien Chouteau --- target-ppc/translate_init.c |8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/target-ppc/translate_init.c b/target-

Re: [Qemu-devel] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Alexander Graf
On 27.03.2013, at 14:50, Fabien Chouteau wrote: > According to the PowePC 750 user's manual, the vector offset for system PowerPC? > reset (both /HRESET and /SRESET) is 0x00100. > > Signed-off-by: Fabien Chouteau > --- > target-ppc/translate_init.c |8 > 1 file changed, 4 insertio

Re: [Qemu-devel] [Qemu-ppc] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Alexander Graf
On 27.03.2013, at 14:54, Alexander Graf wrote: > > On 27.03.2013, at 14:50, Fabien Chouteau wrote: > >> According to the PowePC 750 user's manual, the vector offset for system > > PowerPC? > >> reset (both /HRESET and /SRESET) is 0x00100. >> >> Signed-off-by: Fabien Chouteau >> --- >> targe

Re: [Qemu-devel] dataplane bug: fail to start Windows VM with dataplane enable

2013-03-27 Thread Stefan Hajnoczi
On Wed, Mar 27, 2013 at 02:32:19PM +0100, Stefan Hajnoczi wrote: > On Tue, Mar 26, 2013 at 11:10:35PM +0800, 张磊强 wrote: > > Hi, Paolo && Stefan: > > > > When I test the dataplane feature with qemu master, I find that > > Windows (Windows 7 and Windows 2003) VM will hang if dataplane is > > enable

Re: [Qemu-devel] [Qemu-ppc] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Alexander Graf
On 27.03.2013, at 15:00, Alexander Graf wrote: > > On 27.03.2013, at 14:54, Alexander Graf wrote: > >> >> On 27.03.2013, at 14:50, Fabien Chouteau wrote: >> >>> According to the PowePC 750 user's manual, the vector offset for system >> >> PowerPC? >> >>> reset (both /HRESET and /SRESET) is

[Qemu-devel] [PATCH] chardev-frontends: Explicitly check, inc and dec avail_connections

2013-03-27 Thread Hans de Goede
chardev-frontends need to explictly check, increase and decrement the avail_connections "property" of the chardev when they are not using a qdev-chardev-property for the chardev. This fixes things like: qemu-kvm -chardev stdio,id=foo -device isa-serial,chardev=foo \ -mon chardev=foo Working, wh

Re: [Qemu-devel] [PATCH 07/11] qemu-char: Move incrementing of avail_connections to qdev-properties-system

2013-03-27 Thread Hans de Goede
Hi, On 03/26/2013 02:50 PM, Paolo Bonzini wrote: 1) For most problematic devices, the proper fix would be to make them use a chardev qdev property for there chardev usage, and then this would be automatically fixed, agreed? At least on x86, all devices already use a chardev qdev property.

Re: [Qemu-devel] [PATCH 05/12] target-i386: push hot-plugged VCPU state to KVM and unstop it

2013-03-27 Thread Andreas Färber
Am 27.03.2013 14:27, schrieb Igor Mammedov: > On Wed, 27 Mar 2013 13:17:45 +0100 > Andreas Färber wrote: >>> Then I should move following parts to superclass: >>> >>> if (dev->hotplugged) { >>> cpu_synchronize_post_init(env); >>> resume_vcpu(CPU(cpu)); >>> } >>> >>> because

Re: [Qemu-devel] [RFC PATCH 04/10] qemu-ga: Add Windows VSS provider to quiesce applications on fsfreeze

2013-03-27 Thread Tomoki Sekiyama
On Tue, 2013-03-26 at 16:30 +, Tomoki Sekiyama wrote: > On 3/26/13 4:44 , "Vadim Rozenfeld" wrote: > >>On Tue, 2013-03-26 at 08:09 +0100, Paolo Bonzini wrote: >>> Il 25/03/2013 21:50, Tomoki Sekiyama ha scritto: Unfortunately, if I remove importlib("stdole2.tlb"), generated .tlb seems

Re: [Qemu-devel] selecting a sparc framebuffer from command line

2013-03-27 Thread Bob Breuer
On 3/26/2013 12:24 PM, Artyom Tarasenko wrote: > On Tue, Mar 26, 2013 at 4:08 PM, Bob Breuer wrote: >> On 3/26/2013 6:13 AM, Artyom Tarasenko wrote: >>> It looks like we will have more framebuffers beside TCX in the near future. >>> One way to use them would be to make new machines combining a bas

Re: [Qemu-devel] [PATCH 07/11] qemu-char: Move incrementing of avail_connections to qdev-properties-system

2013-03-27 Thread Paolo Bonzini
Il 27/03/2013 15:09, Hans de Goede ha scritto: > Hi, > > On 03/26/2013 02:50 PM, Paolo Bonzini wrote: > > > >>> 1) For most problematic devices, the proper fix would be to make them >>> use a chardev qdev property for there chardev usage, and then this >>> would be automatically fixed, agreed?

Re: [Qemu-devel] [Qemu-ppc] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Fabien Chouteau
On 03/27/2013 03:04 PM, Alexander Graf wrote: > On 27.03.2013, at 15:00, Alexander Graf wrote: >> On 27.03.2013, at 14:54, Alexander Graf wrote: >>> On 27.03.2013, at 14:50, Fabien Chouteau wrote: diff --git a/target-ppc/translate_init.c b/target-ppc/translate_init.c index 781170f..a5bae1

Re: [Qemu-devel] [PATCH 18/26] hw/usb/dev-smartcard-reader.c: copy atr's protocol to ccid's parameters (adds todo's)

2013-03-27 Thread Alon Levy
On Fri, Mar 22, 2013 at 03:23:15PM +0100, Marc-André Lureau wrote: > Hi, > > > On Mon, Mar 18, 2013 at 2:11 PM, Alon Levy wrote: > > +if (atr_protocol_num == 0) { > > +DPRINTF(s, D_WARN, "%s: error: unimplemented ATR T0 parameters" > > +" setting\n", __func__); > > +

Re: [Qemu-devel] [Qemu-ppc] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Fabien Chouteau
On 03/27/2013 03:59 PM, Fabien Chouteau wrote: > It's actually already implemented (helper_regs.h:96). The question is: > what is the value of MSR[IP] at reset? > Right now in QEMU, MSR[IP] is always set at reset (MSR_EP == MSR_IP): translate_init.c:8174: msr |= (target_ulong)1 << MSR_EP;

Re: [Qemu-devel] [Qemu-ppc] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Alexander Graf
On 27.03.2013, at 15:59, Fabien Chouteau wrote: > On 03/27/2013 03:04 PM, Alexander Graf wrote: >> On 27.03.2013, at 15:00, Alexander Graf wrote: >>> On 27.03.2013, at 14:54, Alexander Graf wrote: On 27.03.2013, at 14:50, Fabien Chouteau wrote: > diff --git a/target-ppc/translate_init.c

Re: [Qemu-devel] [PATCH] chardev-frontends: Explicitly check, inc and dec avail_connections

2013-03-27 Thread Paolo Bonzini
Il 27/03/2013 15:10, Hans de Goede ha scritto: > chardev-frontends need to explictly check, increase and decrement the > avail_connections "property" of the chardev when they are not using a > qdev-chardev-property for the chardev. > > This fixes things like: > qemu-kvm -chardev stdio,id=foo -devi

Re: [Qemu-devel] [PATCH v3] block: Add support for Secure Shell (ssh) block device.

2013-03-27 Thread Anthony Liguori
"Richard W.M. Jones" writes: > From: "Richard W.M. Jones" > > qemu-system-x86_64 -drive file=ssh://hostname/some/image > > QEMU will ssh into 'hostname' and open '/some/image' which is made > available as a standard block device. > > You can specify a username (ssh://user@host/...) and/or a po

Re: [Qemu-devel] [PATCH 07/11] qemu-char: Move incrementing of avail_connections to qdev-properties-system

2013-03-27 Thread Hans de Goede
Hi, On 03/27/2013 03:58 PM, Paolo Bonzini wrote: Il 27/03/2013 15:09, Hans de Goede ha scritto: Hi, On 03/26/2013 02:50 PM, Paolo Bonzini wrote: 1) For most problematic devices, the proper fix would be to make them use a chardev qdev property for there chardev usage, and then this would be

Re: [Qemu-devel] dataplane bug: fail to start Windows VM with dataplane enable

2013-03-27 Thread Stefan Hajnoczi
On Wed, Mar 27, 2013 at 03:02:01PM +0100, Stefan Hajnoczi wrote: > On Wed, Mar 27, 2013 at 02:32:19PM +0100, Stefan Hajnoczi wrote: > > On Tue, Mar 26, 2013 at 11:10:35PM +0800, 张磊强 wrote: > > > Hi, Paolo && Stefan: > > > > > > When I test the dataplane feature with qemu master, I find that > > >

Re: [Qemu-devel] [PATCH 05/12] target-i386: push hot-plugged VCPU state to KVM and unstop it

2013-03-27 Thread Igor Mammedov
On Wed, 27 Mar 2013 15:30:30 +0100 Andreas Färber wrote: > Am 27.03.2013 14:27, schrieb Igor Mammedov: > > On Wed, 27 Mar 2013 13:17:45 +0100 > > Andreas Färber wrote: > >>> Then I should move following parts to superclass: > >>> > >>> if (dev->hotplugged) { > >>> cpu_synchronize_pos

Re: [Qemu-devel] [PATCH 07/11] blockdev: flip default cache mode from writethrough to writeback

2013-03-27 Thread Artyom Tarasenko
On Fri, Aug 10, 2012 at 6:47 PM, Kevin Wolf wrote: > From: Paolo Bonzini > > Now all major device models (IDE, SCSI, virtio) can choose between > writethrough and writeback at run-time, and virtio will even revert > to writethrough if the guest is not capable of sending flushes. So > we can chan

Re: [Qemu-devel] [PATCH v4] Add option to mlock qemu and guest memory

2013-03-27 Thread Anthony Liguori
Satoru Moriya writes: > In certain scenario, latency induced by paging is significant and > memory locking is needed. Also, in the scenario with untrusted > guests, latency improvement due to mlock is desired. > > This patch introduces a following new option to mlock guest and > qemu memory: > >

Re: [Qemu-devel] [PATCH 07/11] blockdev: flip default cache mode from writethrough to writeback

2013-03-27 Thread Paolo Bonzini
Il 27/03/2013 16:16, Artyom Tarasenko ha scritto: > This patch breaks shutting down of a sparc32 guest (or at least the > Debian-4 image I have): > > $ sparc-softmmu/qemu-system-sparc -M SS-5 -nographic -hda ../disk-debian-4 > [...] > Debian GNU/Linux 4.0 debian ttyS0 > > debian login: root > Pa

Re: [Qemu-devel] vNVRAM / blobstore design

2013-03-27 Thread Corey Bryant
On 03/25/2013 06:20 PM, Stefan Berger wrote: On 03/25/2013 06:05 PM, Anthony Liguori wrote: Stefan Berger writes: [argh, just posted this to qemu-trivial -- it's not trivial] Hello! I am posting this message to revive the previous discussions about the design of vNVRAM / blobstore cc'ing

Re: [Qemu-devel] [PATCH 05/12] target-i386: push hot-plugged VCPU state to KVM and unstop it

2013-03-27 Thread Paolo Bonzini
Il 27/03/2013 16:16, Igor Mammedov ha scritto: > yep, I re-factored every *cpu_synchronize_post*() call, > > but considering an intention to call cpu_synchronize_post_init() from > qom/cpu.c this patch won't work nice since it will pull with itself > kvm-stub.o to *-user target. > > Due to qom/cp

Re: [Qemu-devel] vNVRAM / blobstore design

2013-03-27 Thread Corey Bryant
On 03/27/2013 11:17 AM, Corey Bryant wrote: On 03/25/2013 06:20 PM, Stefan Berger wrote: On 03/25/2013 06:05 PM, Anthony Liguori wrote: Stefan Berger writes: [argh, just posted this to qemu-trivial -- it's not trivial] Hello! I am posting this message to revive the previous discussion

Re: [Qemu-devel] [PATCH 08/12] introduce CPU hot-plug notifier

2013-03-27 Thread Igor Mammedov
On Wed, 27 Mar 2013 12:06:10 +0100 Paolo Bonzini wrote: > Il 21/03/2013 15:28, Igor Mammedov ha scritto: > > hot-added CPU id (APIC ID) will be distributed to acpi_piix4 and rtc_cmos > > > > Signed-off-by: Igor Mammedov > > --- > > include/sysemu/sysemu.h |4 > > stubs

Re: [Qemu-devel] [PATCH v2] QOM-ify the TPM support

2013-03-27 Thread Paolo Bonzini
Il 27/03/2013 13:21, Stefan Berger ha scritto: > > With the above file naming and directory placement I followed the > pattern of > > backends/rng.c > include/qemu/rng.h > > So are you planning on having them renamed and moved as well? Uff, we're really bad at consistent naming. :) Given the a

Re: [Qemu-devel] vNVRAM / blobstore design

2013-03-27 Thread Michael S. Tsirkin
On Wed, Mar 27, 2013 at 11:20:43AM -0400, Corey Bryant wrote: > > > On 03/27/2013 11:17 AM, Corey Bryant wrote: > > > > > >On 03/25/2013 06:20 PM, Stefan Berger wrote: > >>On 03/25/2013 06:05 PM, Anthony Liguori wrote: > >>>Stefan Berger writes: > >>> > [argh, just posted this to qemu-trivia

Re: [Qemu-devel] [PATCH] chardev-frontends: Explicitly check, inc and dec avail_connections

2013-03-27 Thread Hans de Goede
Hi, On 03/27/2013 04:11 PM, Paolo Bonzini wrote: diff --git a/backends/rng-egd.c b/backends/rng-egd.c index 5e012e9..d8e9d63 100644 --- a/backends/rng-egd.c +++ b/backends/rng-egd.c @@ -149,6 +149,12 @@ static void rng_egd_opened(RngBackend *b, Error **errp) return; } +if

Re: [Qemu-devel] [PATCH 08/12] introduce CPU hot-plug notifier

2013-03-27 Thread Paolo Bonzini
Il 27/03/2013 16:24, Igor Mammedov ha scritto: > I've put notifier in vl.c since most of them are there They are there, because the code that invokes them is also there. In fact, most calls of notifier_list_notify in vl.c are from static functions. > Yep there wouldn't be need for stub if notifi

Re: [Qemu-devel] [PATCH] chardev-frontends: Explicitly check, inc and dec avail_connections

2013-03-27 Thread Paolo Bonzini
Il 27/03/2013 16:36, Hans de Goede ha scritto: > Unless some smartass adds, ie: -mon chardev=serial0 to the cmdline, then an > error will be reported. Right. :) For smartasses we can use qemu_chr_fe_start_nofail. :) Paolo

Re: [Qemu-devel] dataplane bug: fail to start Windows VM with dataplane enable

2013-03-27 Thread Stefan Hajnoczi
On Tue, Mar 26, 2013 at 11:10:35PM +0800, 张磊强 wrote: > Hi, Paolo && Stefan: > > When I test the dataplane feature with qemu master, I find that > Windows (Windows 7 and Windows 2003) VM will hang if dataplane is > enabled. But if I try to start a Fedora VM, it can start normally. > > The command

Re: [Qemu-devel] [PATCH v3] block: Add support for Secure Shell (ssh) block device.

2013-03-27 Thread Richard W.M. Jones
On Wed, Mar 27, 2013 at 10:12:42AM -0500, Anthony Liguori wrote: > "Richard W.M. Jones" writes: > > > From: "Richard W.M. Jones" > > > > qemu-system-x86_64 -drive file=ssh://hostname/some/image > > > > QEMU will ssh into 'hostname' and open '/some/image' which is made > > available as a standa

Re: [Qemu-devel] [PATCH V14 5/5] VMXNET3 device implementation

2013-03-27 Thread Paolo Bonzini
Il 27/03/2013 15:49, Alexander Graf ha scritto: >> > +#if defined(HOST_WORDS_BIGENDIAN) >> > +#define const_cpu_to_le64(x) bswap_64(x) >> > +#define __BIG_ENDIAN_BITFIELD > Ah, sorry, I replied to the wrong version. > > ARE YOU KIDDING ME? BIG ENDIAN BITFIELD? BITFIELDS ARE _IMPLEMENTATION > SPEC

[Qemu-devel] [PATCH] virtio-pci: pass real with_irqfd to virtio_pci_set_guest_notifier()

2013-03-27 Thread Stefan Hajnoczi
virtio_pci_set_guest_notifiers() checks whether irqfd can be used and whether MSI-X is enabled for the PCI adapter. But then it calls virtio_pci_set_guest_notifier() and passes kvm_msi_via_irqfd_enabled() instead of with_irqfd. When MSI-X is disabled but irqfd is allowed this means that guest_not

Re: [Qemu-devel] [Qemu-ppc] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Fabien Chouteau
On 03/27/2013 04:10 PM, Alexander Graf wrote: >> It's actually already implemented (helper_regs.h:96). The question is: >> what is the value of MSR[IP] at reset? > > For 740 / 750, it's 1. All other bits are 0. Is it true for all PPC, because MSR_EP/IP is set for all kind of CPU right now. > >>

Re: [Qemu-devel] vNVRAM / blobstore design

2013-03-27 Thread Michael S. Tsirkin
On Wed, Mar 27, 2013 at 11:43:53AM -0400, Kenneth Goldman wrote: > A few comments FWIW > > When I first did TPM 1.2, I stored different parts of the TPM NV data > (permanent data, owner evict keys, defined space) in different files. It got > ugly and I eventually changed to one big blob, This was

[Qemu-devel] [PATCH v4] block: Add support for Secure Shell (ssh) block device.

2013-03-27 Thread Richard W.M. Jones
This is version 4 of the Secure Shell (ssh) block device. Links to earlier versions: v1: http://www.mail-archive.com/qemu-devel@nongnu.org/msg162605.html v2: http://www.mail-archive.com/qemu-devel@nongnu.org/msg162730.html v3: http://www.mail-archive.com/qemu-devel@nongnu.org/msg162805.html The

[Qemu-devel] [PATCH v4] block: Add support for Secure Shell (ssh) block device.

2013-03-27 Thread Richard W.M. Jones
From: "Richard W.M. Jones" qemu-system-x86_64 -drive file=ssh://hostname/some/image QEMU will ssh into 'hostname' and open '/some/image' which is made available as a standard block device. You can specify a username (ssh://user@host/...) and/or a port number (ssh://host:port/...). You can al

Re: [Qemu-devel] [PATCH V14 5/5] VMXNET3 device implementation

2013-03-27 Thread Alexander Graf
On 27.03.2013, at 16:46, Paolo Bonzini wrote: > Il 27/03/2013 15:49, Alexander Graf ha scritto: +#if defined(HOST_WORDS_BIGENDIAN) +#define const_cpu_to_le64(x) bswap_64(x) +#define __BIG_ENDIAN_BITFIELD >> Ah, sorry, I replied to the wrong version. >> >> ARE YOU KIDDING ME? BIG E

Re: [Qemu-devel] [Qemu-ppc] [PATCH] PPC: init_excp_7x0: fix hreset entry point.

2013-03-27 Thread Alexander Graf
On 27.03.2013, at 16:49, Fabien Chouteau wrote: > On 03/27/2013 04:10 PM, Alexander Graf wrote: >>> It's actually already implemented (helper_regs.h:96). The question is: >>> what is the value of MSR[IP] at reset? >> >> For 740 / 750, it's 1. All other bits are 0. > > Is it true for all PPC, be

  1   2   3   >