[Qemu-devel] [PATCH 11/16] qemu-config: find_list(): use error_set()

2012-05-21 Thread Luiz Capitulino
Note that qemu_find_opts() and qemu_config_parse() need to call error_report() to maintain their semantics on error. Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- qemu-config.c | 32 +--- 1 file changed, 25 insertions(+), 7 deletions(-) diff --git

[Qemu-devel] [PATCH 10/19] msix: Invoke msix_handle_mask_update on msix_mask_all

2012-05-21 Thread Avi Kivity
From: Jan Kiszka jan.kis...@siemens.com In preparation of firing vector notifiers on mask changes, call msix_handle_mask_update also from msix_mask_all. So far, this will have no real effect. Signed-off-by: Jan Kiszka jan.kis...@siemens.com Signed-off-by: Avi Kivity a...@redhat.com ---

Re: [Qemu-devel] [PATCH 2/9] tcg: declare __jit_debug_descriptor to be static

2012-05-21 Thread Jim Meyering
Peter Maydell wrote: On 21 May 2012 20:51, Jim Meyering j...@meyering.net wrote: From: Jim Meyering meyer...@redhat.com Signed-off-by: Jim Meyering meyer...@redhat.com ---  tcg/tcg.c | 2 +-  1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tcg/tcg.c b/tcg/tcg.c index

[Qemu-devel] [PATCH qmp-next v5 00/16]: qapi: convert netdev_add netdev_del

2012-05-21 Thread Luiz Capitulino
v5 - Simplify set_option_parameter() [Laszlo] - Fix bad patch split in patch 15/16, hunk changing net_init_netdev() pertains to patch 14/16 [Laszlo] blockdev.c |2 +- hmp-commands.hx |6 +- hmp.c| 30 + hmp.h|2 +

[Qemu-devel] [PATCH 10/16] qerror: introduce QERR_INVALID_OPTION_GROUP

2012-05-21 Thread Luiz Capitulino
Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- qerror.c |4 qerror.h |3 +++ 2 files changed, 7 insertions(+) diff --git a/qerror.c b/qerror.c index 5092fe7..92c4eff 100644 --- a/qerror.c +++ b/qerror.c @@ -156,6 +156,10 @@ static const QErrorStringTable qerror_table[] =

[Qemu-devel] [PATCH 07/16] qemu-option: opt_set(): use error_set()

2012-05-21 Thread Luiz Capitulino
The functions qemu_opt_set() and opts_do_parse() both call opt_set(), but their callers expect QError semantics. Thus, both functions call qerro_report_err() to keep the expected semantics. Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- qemu-option.c | 31

[Qemu-devel] [PATCH 16/16] qapi: convert netdev_del

2012-05-21 Thread Luiz Capitulino
Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- hmp-commands.hx |3 +-- hmp.c|9 + hmp.h|1 + net.c| 11 +-- net.h|1 - qapi-schema.json | 14

[Qemu-devel] [PATCH v2 0/3] Event notifications for balloon driver

2012-05-21 Thread Daniel P. Berrange
This series is a followup to 2 previously posted patches * BALLOON_CHANGE QMP event: http://lists.nongnu.org/archive/html/qemu-devel/2012-05/msg02215.html * query-events QMP command: http://lists.nongnu.org/archive/html/qemu-devel/2012-05/msg02255.html Changes since v1: - Use a

[Qemu-devel] [PATCH 7/9] mips-dis: declare four globals to be static

2012-05-21 Thread Jim Meyering
From: Jim Meyering meyer...@redhat.com Signed-off-by: Jim Meyering meyer...@redhat.com --- mips-dis.c | 15 +++ 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/mips-dis.c b/mips-dis.c index e3a6e0b..f6109a1 100644 --- a/mips-dis.c +++ b/mips-dis.c @@ -888,10 +888,9 @@

[Qemu-devel] [RFC PATCH 1/4] qemu-options: Add -filefd command line option

2012-05-21 Thread Corey Bryant
This patch provides support for the -filefd command line option. This option will allow passing of a filename and its corresponding file descriptor to QEMU at exec time. Signed-off-by: Corey Bryant cor...@linux.vnet.ibm.com --- qemu-config.c | 17 + qemu-config.h |1 +

[Qemu-devel] [RFC PATCH 4/4] Example -filefd and getfd_file server

2012-05-21 Thread Corey Bryant
This example demonstrates use of the -filefd command to open two disk drives at start-up time. It also demonstrates hot attaching a third disk drive with the getfd_file monitor command. I still have some learning to do with regards to QMP, so the example is using a not-so-program-friendly HMP

[Qemu-devel] [RFC PATCH 2/4] qmp/hmp: Add getfd_file monitor command

2012-05-21 Thread Corey Bryant
This patch provides support for the getfd_file monitor command. This command will allow passing of a filename and its corresponding file descriptor to a guest via the monitor. This command could be followed, for example, by a drive_add command to hot attach a disk drive. Signed-off-by: Corey

[Qemu-devel] [RFC PATCH 3/4] block: Enable QEMU to retrieve passed fd before attempting open

2012-05-21 Thread Corey Bryant
With this patch, when QEMU needs to open a file, it will first check to see if a matching filename/fd pair were passed via the -filefd command line option or the getfd_file monitor command. If a match is found, QEMU will use the passed fd and will not attempt to open the file. Otherwise, if a

[Qemu-devel] [RFC PATCH 0/4] block: file descriptor passing using -filefd and getfd_file

2012-05-21 Thread Corey Bryant
libvirt's sVirt security driver provides SELinux MAC isolation for Qemu guest processes and their corresponding image files. In other words, sVirt uses SELinux to prevent a QEMU process from opening files that do not belong to it. sVirt provides this support by labeling guests and resources with

[Qemu-devel] [PATCH 9/9] convert many more globals to static

2012-05-21 Thread Jim Meyering
From: Jim Meyering meyer...@redhat.com Minor exceptions: * arm-dis: move now-detected-as-unused static variables into #if-0'd block of code where they *are* used. * microblaze: remove decls of now-detected-as-unused vars Signed-off-by: Jim Meyering meyer...@redhat.com --- arm-dis.c

Re: [Qemu-devel] [PATCH 2/9] tcg: declare __jit_debug_descriptor to be static

2012-05-21 Thread Peter Maydell
On 21 May 2012 21:10, Jim Meyering j...@meyering.net wrote: Peter Maydell wrote: On 21 May 2012 20:51, Jim Meyering j...@meyering.net wrote: From: Jim Meyering meyer...@redhat.com Signed-off-by: Jim Meyering meyer...@redhat.com ---  tcg/tcg.c | 2 +-  1 file changed, 1 insertion(+), 1

Re: [Qemu-devel] [PATCH 1/2] pci: Add pci_device_get_host_irq

2012-05-21 Thread Jan Kiszka
On 2012-05-21 16:05, Michael S. Tsirkin wrote: On Mon, May 21, 2012 at 10:13:47AM -0300, Jan Kiszka wrote: @@ -386,6 +387,14 @@ static void piix3_set_irq(void *opaque, int pirq, int level) piix3_set_irq_level(piix3, pirq, level); } +static int piix3_map_host_irq(void *opaque, int

[Qemu-devel] [ANNOUNCE] libguestfs 1.18 released - tools for managing virtual machines and disk images

2012-05-21 Thread Richard W.M. Jones
I'm pleased to announce the latest stable release of libguestfs, a library and a set of tools for reading, writing, managing, inspecting, rescuing, resizing and aligning disk images, and offline and live virtual machines. There are many new features and bug fixes in this release; see the release

Re: [Qemu-devel] [PATCH 1/1] virtio-rng: device to send host entropy to guest

2012-05-21 Thread Anthony Liguori
On 05/21/2012 02:39 PM, Amit Shah wrote: On (Wed) 16 May 2012 [13:23:11], Anthony Liguori wrote: On 05/16/2012 12:21 PM, Amit Shah wrote: On (Wed) 16 May 2012 [08:24:22], Anthony Liguori wrote: On 05/16/2012 06:30 AM, Amit Shah wrote: The Linux kernel already has a virtio-rng driver, this is

Re: [Qemu-devel] [PATCH 1/2] pci: Add pci_device_get_host_irq

2012-05-21 Thread Michael S. Tsirkin
On Mon, May 21, 2012 at 05:35:34PM -0300, Jan Kiszka wrote: On 2012-05-21 16:05, Michael S. Tsirkin wrote: On Mon, May 21, 2012 at 10:13:47AM -0300, Jan Kiszka wrote: @@ -386,6 +387,14 @@ static void piix3_set_irq(void *opaque, int pirq, int level) piix3_set_irq_level(piix3, pirq,

Re: [Qemu-devel] [PATCH 1/2] pci: Add pci_device_get_host_irq

2012-05-21 Thread Michael S. Tsirkin
On Mon, May 21, 2012 at 03:58:57PM -0300, Jan Kiszka wrote: On 2012-05-21 14:34, Michael S. Tsirkin wrote: On Mon, May 21, 2012 at 10:13:47AM -0300, Jan Kiszka wrote: Add a PCI IRQ path discovery function that walks from a given device to the host bridge, returning the IRQ number that is

Re: [Qemu-devel] [RFC PATCH 1/4] qemu-options: Add -filefd command line option

2012-05-21 Thread Eric Blake
On 05/21/2012 02:19 PM, Corey Bryant wrote: This patch provides support for the -filefd command line option. This option will allow passing of a filename and its corresponding file descriptor to QEMU at exec time. Signed-off-by: Corey Bryant cor...@linux.vnet.ibm.com +DEF(filefd, HAS_ARG,

Re: [Qemu-devel] [RFC PATCH 2/4] qmp/hmp: Add getfd_file monitor command

2012-05-21 Thread Eric Blake
On 05/21/2012 02:19 PM, Corey Bryant wrote: This patch provides support for the getfd_file monitor command. This command will allow passing of a filename and its corresponding file descriptor to a guest via the monitor. This command could be followed, for example, by a drive_add command to

Re: [Qemu-devel] [RFC PATCH 3/4] block: Enable QEMU to retrieve passed fd before attempting open

2012-05-21 Thread Eric Blake
On 05/21/2012 02:19 PM, Corey Bryant wrote: With this patch, when QEMU needs to open a file, it will first check to see if a matching filename/fd pair were passed via the -filefd command line option or the getfd_file monitor command. If a match is found, QEMU will use the passed fd and will

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access function

2012-05-21 Thread Benjamin Herrenschmidt
On Mon, 2012-05-21 at 15:18 +0300, Michael S. Tsirkin wrote: mb is more than just read flush writes (besides it's not a statement about flushing, it's a statement about ordering. whether it has a flushing side effect on x86 is a separate issue, it doesn't on power for example). I

Re: [Qemu-devel] Get current env within io_handler ?

2012-05-21 Thread Edgar E. Iglesias
On Mon, May 21, 2012 at 06:40:38PM +, Blue Swirl wrote: On Mon, May 21, 2012 at 6:28 PM, Peter Maydell peter.mayd...@linaro.org wrote: On 21 May 2012 19:08, Blue Swirl blauwir...@gmail.com wrote: On Mon, May 21, 2012 at 10:36 AM, Peter Maydell peter.mayd...@linaro.org wrote: I think

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access functions

2012-05-21 Thread Anthony Liguori
On 05/21/2012 03:31 AM, Michael S. Tsirkin wrote: More than that. smp_mb is pretty expensive. You often can do just smp_wmb and smp_rmb and that is very cheap. Many operations run in the vcpu context or start when guest exits to host and work is bounced from there and thus no barrier is needed

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access function

2012-05-21 Thread Michael S. Tsirkin
On Tue, May 22, 2012 at 07:58:17AM +1000, Benjamin Herrenschmidt wrote: On Mon, 2012-05-21 at 15:18 +0300, Michael S. Tsirkin wrote: mb is more than just read flush writes (besides it's not a statement about flushing, it's a statement about ordering. whether it has a flushing side

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access functions

2012-05-21 Thread Benjamin Herrenschmidt
On Mon, 2012-05-21 at 17:18 -0500, Anthony Liguori wrote: But this isn't what this series is about. This series is only attempting to make sure that writes are ordered with respect to other writes in main memory. Actually, it applies to both reads and writes. They can't pass each other

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access functions

2012-05-21 Thread Anthony Liguori
On 05/21/2012 05:26 PM, Benjamin Herrenschmidt wrote: On Mon, 2012-05-21 at 17:18 -0500, Anthony Liguori wrote: But this isn't what this series is about. This series is only attempting to make sure that writes are ordered with respect to other writes in main memory. Actually, it applies to

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access functions

2012-05-21 Thread Michael S. Tsirkin
On Mon, May 21, 2012 at 05:18:21PM -0500, Anthony Liguori wrote: On 05/21/2012 03:31 AM, Michael S. Tsirkin wrote: More than that. smp_mb is pretty expensive. You often can do just smp_wmb and smp_rmb and that is very cheap. Many operations run in the vcpu context or start when guest exits

Re: [Qemu-devel] [PATCH next v2 00/74] QOM CPUState, part 3: CPU reset

2012-05-21 Thread Andreas Färber
Am 21.05.2012 15:52, schrieb Alexander Graf: Very simple, nice and clean ;) PowerPC parts are: Acked-by: Alexander Graf ag...@suse.de Thanks, applied to qom-next: http://repo.or.cz/w/qemu/afaerber.git/shortlog/refs/heads/qom-next David and Edgar, you two were apparently not cc'ed. Could

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access functions

2012-05-21 Thread Michael S. Tsirkin
On Mon, May 21, 2012 at 05:31:06PM -0500, Anthony Liguori wrote: On 05/21/2012 05:26 PM, Benjamin Herrenschmidt wrote: On Mon, 2012-05-21 at 17:18 -0500, Anthony Liguori wrote: But this isn't what this series is about. This series is only attempting to make sure that writes are ordered with

[Qemu-devel] [Bug 990364] Re: virtio_ioport_write: unexpected address 0x13 value 0x1

2012-05-21 Thread Vitalis
But with new drivers i got virtio_ioport_write: unexpected address 0x13 value 0x1 again. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/990364 Title: virtio_ioport_write: unexpected address 0x13

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access function

2012-05-21 Thread Benjamin Herrenschmidt
On Tue, 2012-05-22 at 01:22 +0300, Michael S. Tsirkin wrote: Again, from which originator ? From a given initiator, nothing bypasses anything, so the right thing to do here is a full mb(). However, I suspect what you are talking about here is read -responses- not bypassing writes in the

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access functions

2012-05-21 Thread Benjamin Herrenschmidt
On Tue, 2012-05-22 at 01:44 +0300, Michael S. Tsirkin wrote: OK. Just not another level of indirect function callbacks please. Make it a library so each bus can do the right thing. There are not so many buses. I think we are a long way from having to deal with subtly different ordering

[Qemu-devel] [ANNOUNCE] kvm-kmod-3.4

2012-05-21 Thread Jan Kiszka
After the release of kernel 3.4, this is now the announcements of the corresponding kvm-kmod-3.4. The package is available from http://sourceforge.net/projects/kvm/files/kvm-kmod/3.4/kvm-kmod-3.4.tar.bz2/download See [1] for further details on kvm-kmod. Major KVM changes since kvm-kmod-3.3.6:

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access function

2012-05-21 Thread Benjamin Herrenschmidt
On Tue, 2012-05-22 at 01:22 +0300, Michael S. Tsirkin wrote: Again, from which originator ? From a given initiator, nothing bypasses anything, so the right thing to do here is a full mb(). However, I suspect what you are talking about here is read -responses- not bypassing writes in the

Re: [Qemu-devel] [PATCH next v2 00/74] QOM CPUState, part 3: CPU reset

2012-05-21 Thread Andreas Färber
Am 21.05.2012 20:20, schrieb Blue Swirl: On Mon, May 21, 2012 at 9:09 AM, Andreas Färber afaer...@suse.de wrote: Am 14.05.2012 23:22, schrieb Blue Swirl: On Mon, May 14, 2012 at 8:59 PM, Andreas Färber afaer...@suse.de wrote: Am 14.05.2012 21:54, schrieb Blue Swirl: On Mon, May 14, 2012 at

Re: [Qemu-devel] The image size of instance VM keeps growing

2012-05-21 Thread Charles . Tsai-蔡清海-研究發展部
Stefan, Thank you for information. We will try to isolate the issue here and give you an update. -Original Message- From: Stefan Hajnoczi [mailto:stefa...@gmail.com] Sent: Monday, May 21, 2012 9:24 PM To: Charles.Tsai-蔡清海-研究發展部 Cc: qemu-devel@nongnu.org; Jonah.Wu-吳君勉-研究發展部 Subject:

Re: [Qemu-devel] [RFC PATCH] qemu pci: pci_add_capability enhancement to prevent damaging config space

2012-05-21 Thread Benjamin Herrenschmidt
On Fri, 2012-05-18 at 15:12 +1000, Alexey Kardashevskiy wrote: Alexander, Is that any better? :) Alex (Graf that is), ping ? The original patch from Alexey was fine btw. VFIO will always call things with the existing capability offset so there's no real risk of doing the wrong thing or

Re: [Qemu-devel] Is it possible to retrieve pre-process information in QEMU?

2012-05-21 Thread 陳韋任
 I would like to know if I can retrieve pre-process information in QEMU system mode. For example, I want to know each process's page fault ratio. Is there a way to do that? logically, it's possible, but you need to locate the task_struct of each processes first. Using GDB, that might be

Re: [Qemu-devel] [RFC PATCH] qemu pci: pci_add_capability enhancement to prevent damaging config space

2012-05-21 Thread Alexander Graf
On 22.05.2012, at 04:02, Benjamin Herrenschmidt b...@kernel.crashing.org wrote: On Fri, 2012-05-18 at 15:12 +1000, Alexey Kardashevskiy wrote: Alexander, Is that any better? :) Alex (Graf that is), ping ? The original patch from Alexey was fine btw. VFIO will always call things

Re: [Qemu-devel] [RFC PATCH] qemu pci: pci_add_capability enhancement to prevent damaging config space

2012-05-21 Thread Alexey Kardashevskiy
On 22/05/12 13:21, Alexander Graf wrote: On 22.05.2012, at 04:02, Benjamin Herrenschmidt b...@kernel.crashing.org wrote: On Fri, 2012-05-18 at 15:12 +1000, Alexey Kardashevskiy wrote: Alexander, Is that any better? :) Alex (Graf that is), ping ? The original patch from Alexey was

[Qemu-devel] [PATCH] Add a memory barrier to DMA functions

2012-05-21 Thread Benjamin Herrenschmidt
The emulated devices can run simultaneously with the guest, so we need to be careful with ordering of load and stores done by them to the guest system memory, which need to be observed in the right order by the guest operating system. This adds a barrier call to the basic DMA read/write ops which

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access function

2012-05-21 Thread Rusty Russell
On Tue, 22 May 2012 07:58:17 +1000, Benjamin Herrenschmidt b...@kernel.crashing.org wrote: On Mon, 2012-05-21 at 15:18 +0300, Michael S. Tsirkin wrote: But I can also live with a global flag latest_dma_read and on read we could do if (unlikely(latest_dma_read)) smp_mb();

Re: [Qemu-devel] [PATCH] Add a memory barrier to DMA functions

2012-05-21 Thread Benjamin Herrenschmidt
On Tue, 2012-05-22 at 14:34 +1000, Benjamin Herrenschmidt wrote: So here's the latest try :-) I've kept is simple, I don't add anything to map/unmap at this stage, so we might still have a problem with drivers who do that a lot without any explicit barrier (ahci ?). My preference is to also

Re: [Qemu-devel] [PATCH] Add a memory barrier to guest memory access function

2012-05-21 Thread Michael S. Tsirkin
On Tue, May 22, 2012 at 08:56:12AM +1000, Benjamin Herrenschmidt wrote: On Tue, 2012-05-22 at 01:22 +0300, Michael S. Tsirkin wrote: Again, from which originator ? From a given initiator, nothing bypasses anything, so the right thing to do here is a full mb(). However, I suspect what

Re: [Qemu-devel] qemu-microblaze-system

2012-05-21 Thread Peter Crosthwaite
Hi Michael, The microblaze linux kernel is available at: http://wiki.xilinx.com/ If you wish to do your own kernel config from scratch. There is some brief documentation there on how to do a bringup. The qemu port for mb maintained by PetaLogix and I notice you are using a student email

Re: [Qemu-devel] [RFC PATCH] qemu pci: pci_add_capability enhancement to prevent damaging config space

2012-05-21 Thread Alexander Graf
On 22.05.2012, at 05:44, Alexey Kardashevskiy a...@ozlabs.ru wrote: On 22/05/12 13:21, Alexander Graf wrote: On 22.05.2012, at 04:02, Benjamin Herrenschmidt b...@kernel.crashing.org wrote: On Fri, 2012-05-18 at 15:12 +1000, Alexey Kardashevskiy wrote: Alexander, Is that any

<    1   2   3