[Qemu-devel] What is cpu_A0 in target-i386/translate.c

2012-08-14 Thread Steven
Hi, I would like to trace the guest physical address of the load instructions from the guest. I thought the cpu_A0 is the memory address to be accessed. However, when I print out the value of cpu_A0, like static inline void gen_op_ld_v(int idx, TCGv t0, TCGv a0) { int mem_index = (idx >> 2) -

Re: [Qemu-devel] [Qemu-ppc][PATCH v8 2/2] Add USB enablement on sPAPR platform.

2012-08-14 Thread Li Zhang
On 2012年08月15日 02:09, Alexander Graf wrote: On 14.08.2012, at 19:49, Li Zhang wrote: USB is enabled as default on sPAPR platform because it needs USB keyboard and USB mouse when VGA is enabled. This patch is to add USB controller on sPAPR platform. Signed-off-by: Li Zhang This looks a lot

Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 1/3] Add USB option in machine options

2012-08-14 Thread Li Zhang
On Wed, Aug 15, 2012 at 10:57 AM, David Gibson wrote: > On Wed, Aug 15, 2012 at 10:50:04AM +0800, Li Zhang wrote: >> On Wed, Aug 15, 2012 at 9:47 AM, David Gibson wrote: >> > On Wed, Aug 15, 2012 at 09:24:34AM +0800, Li Zhang wrote: >> >> On Wed, Aug 15, 2012 at 8:09 AM, Benjamin Herrenschmidt >>

Re: [Qemu-devel] [PATCH v6 2/2] block: Support GlusterFS as a QEMU block backend

2012-08-14 Thread Bharata B Rao
On Tue, Aug 14, 2012 at 10:29:26AM +0200, Kevin Wolf wrote: > >>> +static void gluster_finish_aiocb(struct glfs_fd *fd, ssize_t ret, void > >>> *arg) > >>> +{ > >>> +GlusterAIOCB *acb = (GlusterAIOCB *)arg; > >>> +BDRVGlusterState *s = acb->common.bs->opaque; > >>> + > >>> +acb->ret =

[Qemu-devel] [0/7] pseries: Patches to fix system reset

2012-08-14 Thread David Gibson
Hi Alex, Here is a string of patches which fix most of the many problems with system reset on the pseriss machine. They apply on top of my other string of pseries patches which you already merged. They apply before Li Zhang's usb and vga patches, since it looks like those will go another iterati

[Qemu-devel] [PATCH 5/7] pseries: Add support for new KVM hash table control call

2012-08-14 Thread David Gibson
From: Ben Herrenschmidt This adds support for then new "reset htab" ioctl which allows qemu to properly cleanup the MMU hash table when the guest is reset. With the corresponding kernel support, reset of a guest now works properly. This also paves the way for indicating a different size hash tab

[Qemu-devel] [PATCH 1/7] Allow QEMUMachine to override reset sequencing

2012-08-14 Thread David Gibson
qemu_system_reset() function always performs the same basic actions on all machines. This includes running all the reset handler hooks, however the order in which these will run is not always easily predictable. This patch splits the core of qemu_system_reset() - the invocation of the reset handl

[Qemu-devel] [PATCH 4/7] pseries: Use new method to correct reset sequence

2012-08-14 Thread David Gibson
A number of things need to occur during reset of the PAPR paravirtualized platform in a specific order. For example, the hash table needs to be cleared before the CPUs are reset, so that they initialize their register state correctly, and the CPUs need to have their main reset called before we set

[Qemu-devel] [PATCH 7/7] ppc/pseries: Reset VPA registration on CPU reset

2012-08-14 Thread David Gibson
The ppc specific CPU state contains several variables which track the VPA, SLB shadow and dispatch trace log. These are structures shared between OS and hypervisor that are used on the pseries machine to track various per-CPU quantities. The address of these structures needs to be registered by t

[Qemu-devel] [PATCH 2/7] ppc: Make kvm_arch_put_registers() put *all* the registers

2012-08-14 Thread David Gibson
At least when invoked with high enough 'level' arguments, kvm_arch_put_registers() is supposed to copy essentially all the cpu state as encoded in qemu's internal structures into the kvm state. Currently the ppc version does not do this - it never calls KVM_SET_SREGS, for example, and therefore ne

[Qemu-devel] [PATCH 3/7] pseries: Fix and cleanup CPU initialization and reset

2012-08-14 Thread David Gibson
The current pseries machine init function iterates over the CPUs at several points, doing various bits of initialization. This is messy; these can and should be merged into a single iteration doing all the necessary per cpu initialization. Worse, some of these initializations were setting up stat

[Qemu-devel] [PATCH 6/7] pseries: Clear TCE state when resetting PAPR VIO devices

2012-08-14 Thread David Gibson
When we reset the system, the reset method for VIO bus devices resets the state of their request queue (if present) as it should. However it was not resetting the state of their TCE table (DMA translation) if present. This patch corrects that bug, and also removes some small code duplication in t

[Qemu-devel] buildbot failure in qemu on block_x86_64_debian_6_0

2012-08-14 Thread qemu
The Buildbot has detected a new failure on builder block_x86_64_debian_6_0 while building qemu. Full details are available at: http://buildbot.b1-systems.de/qemu/builders/block_x86_64_debian_6_0/builds/360 Buildbot URL: http://buildbot.b1-systems.de/qemu/ Buildslave for this Build: yuzuki Buil

Re: [Qemu-devel] [PATCH 3/4] s390/kvm: Add a channel I/O based virtio transport driver.

2012-08-14 Thread Rusty Russell
On Tue, 14 Aug 2012 13:03:34 +0200, Cornelia Huck wrote: > > It would be per-machine; per-device would be a bit crazy. We'd > > deprecate the old ring format. > > > > There's been no consistent thread on the ideas for a ring change, > > unfortunately, but you can find interesting parts here, of

[Qemu-devel] buildbot failure in qemu on block_i386_debian_6_0

2012-08-14 Thread qemu
The Buildbot has detected a new failure on builder block_i386_debian_6_0 while building qemu. Full details are available at: http://buildbot.b1-systems.de/qemu/builders/block_i386_debian_6_0/builds/360 Buildbot URL: http://buildbot.b1-systems.de/qemu/ Buildslave for this Build: yuzuki Build Re

[Qemu-devel] [PATCH] win32: provide separate macros for weak decls and definitions

2012-08-14 Thread Anthony Liguori
mingw32 seems to want the declaration to also carry the weak attribute. Strangely, gcc on Linux absolutely does not want the declaration to be marked as weak. This may not be the right fix, but it seems to do the trick. Signed-off-by: Anthony Liguori --- arch_init.h |4

Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 1/3] Add USB option in machine options

2012-08-14 Thread David Gibson
On Wed, Aug 15, 2012 at 10:50:04AM +0800, Li Zhang wrote: > On Wed, Aug 15, 2012 at 9:47 AM, David Gibson wrote: > > On Wed, Aug 15, 2012 at 09:24:34AM +0800, Li Zhang wrote: > >> On Wed, Aug 15, 2012 at 8:09 AM, Benjamin Herrenschmidt > >> wrote: > >> > On Wed, 2012-08-15 at 09:10 +1000, David G

Re: [Qemu-devel] [Qemu-ppc] [PATCH: RFC] Adding BAR0 for e500 PCI controller

2012-08-14 Thread Bhushan Bharat-R65777
> -Original Message- > From: Wood Scott-B07421 > Sent: Wednesday, August 15, 2012 6:59 AM > To: Bhushan Bharat-R65777 > Cc: qemu-devel@nongnu.org; qemu-...@nongnu.org; ag...@suse.de; Bhushan Bharat- > R65777 > Subject: Re: [Qemu-ppc] [PATCH: RFC] Adding BAR0 for e500 PCI controller > > O

Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 1/3] Add USB option in machine options

2012-08-14 Thread Li Zhang
On Wed, Aug 15, 2012 at 9:47 AM, David Gibson wrote: > On Wed, Aug 15, 2012 at 09:24:34AM +0800, Li Zhang wrote: >> On Wed, Aug 15, 2012 at 8:09 AM, Benjamin Herrenschmidt >> wrote: >> > On Wed, 2012-08-15 at 09:10 +1000, David Gibson wrote: >> >> > I see. I will redo this patch. Send out it late

Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 1/3] Add USB option in machine options

2012-08-14 Thread David Gibson
On Wed, Aug 15, 2012 at 09:24:34AM +0800, Li Zhang wrote: > On Wed, Aug 15, 2012 at 8:09 AM, Benjamin Herrenschmidt > wrote: > > On Wed, 2012-08-15 at 09:10 +1000, David Gibson wrote: > >> > I see. I will redo this patch. Send out it later. :) > >> > Thanks for your comments. > >> > >> When you do

Re: [Qemu-devel] [PATCH v8] kvm: notify host when the guest is panicked\

2012-08-14 Thread Marcelo Tosatti
On Tue, Aug 14, 2012 at 05:59:06PM -0500, Anthony Liguori wrote: > Marcelo Tosatti writes: > > > On Tue, Aug 14, 2012 at 02:35:34PM -0500, Anthony Liguori wrote: > >> Marcelo Tosatti writes: > >> > >> > On Tue, Aug 14, 2012 at 01:53:01PM -0500, Anthony Liguori wrote: > >> >> Marcelo Tosatti wr

Re: [Qemu-devel] [Qemu-ppc] [PATCH: RFC] Adding BAR0 for e500 PCI controller

2012-08-14 Thread Scott Wood
On 08/14/2012 07:50 AM, Bharat Bhushan wrote: > PCI Root complex have TYPE-1 configuration header while PCI endpoint > have type-0 configuration header. The type-1 configuration header have > a BAR (BAR0). In Freescale PCI controller BAR0 is used for mapping pci > address space to CCSR address spac

Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 1/3] Add USB option in machine options

2012-08-14 Thread Li Zhang
On Wed, Aug 15, 2012 at 8:09 AM, Benjamin Herrenschmidt wrote: > On Wed, 2012-08-15 at 09:10 +1000, David Gibson wrote: >> > I see. I will redo this patch. Send out it later. :) >> > Thanks for your comments. >> >> When you do that, please also change the default to make spapr _not_ >> have usb. >

Re: [Qemu-devel] [Qemu-ppc][PATCH v8 1/2] Add USB option in machine options

2012-08-14 Thread Li Zhang
On Wed, Aug 15, 2012 at 2:08 AM, Alexander Graf wrote: > > > On 14.08.2012, at 19:49, Li Zhang wrote: > >> When -usb option is used, global varible usb_enabled is set. >> And all the plafrom will create one USB controller according >> to this variable. In fact, global varibles make code hard >> t

Re: [Qemu-devel] [Qemu-ppc] [PATCH 06/10] pseries: Export find_phb() utility function for PCI code

2012-08-14 Thread David Gibson
On Tue, Aug 14, 2012 at 01:45:53PM +0200, Alexander Graf wrote: > On 08/08/2012 04:10 AM, David Gibson wrote: > >From: Alexey Kardashevskiy > > > >The pseries PCI code makes use of an internal find_dev() function which > >locates a PCIDevice * given a (platform specific) bus ID and device > >addre

Re: [Qemu-devel] [Qemu-ppc] [0/10] pseries updates and cleanups

2012-08-14 Thread David Gibson
On Tue, Aug 14, 2012 at 02:56:43PM +0200, Alexander Graf wrote: > On 08/14/2012 02:34 PM, Alexander Graf wrote: > >On 08/08/2012 04:10 AM, David Gibson wrote: > >>Hi Alex, > >> > >>This series contains all my outstanding pseries updates which aren't > >>dependent on getting a generic patch upstream

[Qemu-devel] buildbot failure in qemu on block_openbsd_current

2012-08-14 Thread qemu
The Buildbot has detected a new failure on builder block_openbsd_current while building qemu. Full details are available at: http://buildbot.b1-systems.de/qemu/builders/block_openbsd_current/builds/305 Buildbot URL: http://buildbot.b1-systems.de/qemu/ Buildslave for this Build: brad_openbsd_cur

[Qemu-devel] buildbot failure in qemu on block_mingw32

2012-08-14 Thread qemu
The Buildbot has detected a new failure on builder block_mingw32 while building qemu. Full details are available at: http://buildbot.b1-systems.de/qemu/builders/block_mingw32/builds/295 Buildbot URL: http://buildbot.b1-systems.de/qemu/ Buildslave for this Build: kraxel_rhel61 Build Reason: The

[Qemu-devel] buildbot failure in qemu on block_openbsd_4.9

2012-08-14 Thread qemu
The Buildbot has detected a new failure on builder block_openbsd_4.9 while building qemu. Full details are available at: http://buildbot.b1-systems.de/qemu/builders/block_openbsd_4.9/builds/295 Buildbot URL: http://buildbot.b1-systems.de/qemu/ Buildslave for this Build: kraxel_openbsd49 Build

[Qemu-devel] [PATCH 2/4] kvm: i8254: Finish time conversion fix

2012-08-14 Thread Marcelo Tosatti
From: Jan Kiszka 0cdd3d1444 fixed reading back the counter load time from the kernel while assuming the kernel would always update its load time on writing the state. That is only true for channel 1, and so pit_get_channel_info returned wrong output pin states for high counter values. Fix this b

[Qemu-devel] [PATCH 4/4] update-linux-headers.sh: Pull in asm-generic/kvm_para.h

2012-08-14 Thread Marcelo Tosatti
From: Peter Maydell Add asm-generic/kvm_para.h to the set of non-architecture specific KVM kernel headers we copy into QEMU. This header may be included by an architecture's kvm_para.h header. Reviewed-by: Jan Kiszka Signed-off-by: Peter Maydell Signed-off-by: Marcelo Tosatti --- scripts/upd

[Qemu-devel] [PATCH 0/4] [PULL] qemu-kvm.git uq/master queue

2012-08-14 Thread Marcelo Tosatti
The following changes since commit 873359d411eeb380906761e46839a2b705dbcf75: Merge branch 'linux-user.next' of git://git.linaro.org/people/pmaydell/qemu-arm (2012-08-14 19:50:22 +) are available in the git repository at: git://git.kernel.org/pub/scm/virt/kvm/qemu-kvm.git uq/master Jan

[Qemu-devel] [PATCH 3/4] kvmvapic: Disable if there is insufficient memory

2012-08-14 Thread Marcelo Tosatti
From: Jan Kiszka We need at least 1M of RAM to map the option ROM. Otherwise, we will corrupt host memory or even crash: $ qemu-system-x86_64 -nodefaults --enable-kvm -vnc :0 -m 640k Segmentation fault (core dumped) Reported-and-tested-by: Markus Armbruster Signed-off-by: Jan Kiszka S

[Qemu-devel] [PATCH 1/4] kvm: i8254: Cache kernel clock offset in KVMPITState

2012-08-14 Thread Marcelo Tosatti
From: Jan Kiszka To prepare the final fix for clock calibration issues with the in-kernel PIT, we want to cache the offset between vmclock and the clock used by the in-kernel PIT. So far, we only need to update it when the VM state changes between running and stopped because we only read the in-k

Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 1/3] Add USB option in machine options

2012-08-14 Thread Benjamin Herrenschmidt
On Wed, 2012-08-15 at 09:10 +1000, David Gibson wrote: > > I see. I will redo this patch. Send out it later. :) > > Thanks for your comments. > > When you do that, please also change the default to make spapr _not_ > have usb. FYI, I originally asked for USB as default ... however it looks like a

Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 1/3] Add USB option in machine options

2012-08-14 Thread Alexander Graf
On 15.08.2012, at 01:10, David Gibson wrote: > On Tue, Aug 14, 2012 at 11:01:19PM +0800, Li Zhang wrote: >> On Tue, Aug 14, 2012 at 6:46 PM, Alexander Graf wrote: >>> On 08/07/2012 04:41 AM, Li Zhang wrote: When -usb option is used, global varible usb_enabled is set. And all the

Re: [Qemu-devel] [PATCH] configure: Don't override user's --cpu on MacOS and Solaris

2012-08-14 Thread Schindler Karl-Michael
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Pathetic case (32bit qemu on 64bit hw under Mac OS X 10.6) tested succesfully. Thanks for your patience and help. Michael -BEGIN PGP SIGNATURE- Version: GnuPG/MacGPG2 v2.0.18 (Darwin) Comment: GPGTools - http://gpgtools.org iQEcBAEBAgAGBQJQK

Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 3/3] spapr: Add support for -vga option

2012-08-14 Thread David Gibson
On Wed, Aug 15, 2012 at 01:52:55AM +0800, Li Zhang wrote: > On Wed, Aug 15, 2012 at 1:19 AM, Li Zhang wrote: > > On Tue, Aug 14, 2012 at 11:13 PM, Li Zhang wrote: > >> On Tue, Aug 14, 2012 at 8:13 PM, David Gibson wrote: > >>> On Tue, Aug 14, 2012 at 10:04:03PM +1000, Benjamin Herrenschmidt wrot

Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 1/3] Add USB option in machine options

2012-08-14 Thread David Gibson
On Tue, Aug 14, 2012 at 11:01:19PM +0800, Li Zhang wrote: > On Tue, Aug 14, 2012 at 6:46 PM, Alexander Graf wrote: > > On 08/07/2012 04:41 AM, Li Zhang wrote: > >> > >> When -usb option is used, global varible usb_enabled is set. > >> And all the plafrom will create one USB controller according >

[Qemu-devel] buildbot failure in qemu on default_mingw32

2012-08-14 Thread qemu
The Buildbot has detected a new failure on builder default_mingw32 while building qemu. Full details are available at: http://buildbot.b1-systems.de/qemu/builders/default_mingw32/builds/346 Buildbot URL: http://buildbot.b1-systems.de/qemu/ Buildslave for this Build: kraxel_rhel61 Build Reason:

Re: [Qemu-devel] [PATCH v8] kvm: notify host when the guest is panicked

2012-08-14 Thread Anthony Liguori
Marcelo Tosatti writes: > On Tue, Aug 14, 2012 at 02:35:34PM -0500, Anthony Liguori wrote: >> Marcelo Tosatti writes: >> >> > On Tue, Aug 14, 2012 at 01:53:01PM -0500, Anthony Liguori wrote: >> >> Marcelo Tosatti writes: >> >> >> >> > On Tue, Aug 14, 2012 at 05:55:54PM +0300, Yan Vugenfirer w

Re: [Qemu-devel] [RFC 18/20] target-i386: use properties to set/unset user specified features on CPU

2012-08-14 Thread Igor Mammedov
On Mon, 13 Aug 2012 17:48:24 -0300 Eduardo Habkost wrote: > On Fri, Aug 10, 2012 at 01:22:34PM +0200, Igor Mammedov wrote: > > Signed-off-by: Igor Mammedov > > --- > > target-i386/cpu.c | 167 > > +++--- > > 1 file changed, 20 insertions(+), 147

Re: [Qemu-devel] [PATCH v8] kvm: notify host when the guest is panicked

2012-08-14 Thread Marcelo Tosatti
On Tue, Aug 14, 2012 at 02:35:34PM -0500, Anthony Liguori wrote: > Marcelo Tosatti writes: > > > On Tue, Aug 14, 2012 at 01:53:01PM -0500, Anthony Liguori wrote: > >> Marcelo Tosatti writes: > >> > >> > On Tue, Aug 14, 2012 at 05:55:54PM +0300, Yan Vugenfirer wrote: > >> >> > >> >> On Aug 14,

Re: [Qemu-devel] [PATCH] update-linux-headers.sh: Pull in asm-generic/kvm_para.h

2012-08-14 Thread Marcelo Tosatti
On Wed, Jul 25, 2012 at 04:29:07PM +0100, Peter Maydell wrote: > Add asm-generic/kvm_para.h to the set of non-architecture specific > KVM kernel headers we copy into QEMU. This header may be included > by an architecture's kvm_para.h header. > > Signed-off-by: Peter Maydell > --- > scripts/updat

Re: [Qemu-devel] [PATCH 16/20] qidl: Add documentation

2012-08-14 Thread Peter Maydell
On 14 August 2012 23:15, Michael Roth wrote: > On Tue, Aug 14, 2012 at 08:41:56PM +0100, Peter Maydell wrote: >> On 14 August 2012 17:27, Michael Roth wrote: >> > +In our *SerialDevice* example, the *CharDriverState* pointer reflects the >> > host >> > +backend that we use to send serial output

Re: [Qemu-devel] [PATCH 16/20] qidl: Add documentation

2012-08-14 Thread Michael Roth
On Tue, Aug 14, 2012 at 08:41:56PM +0100, Peter Maydell wrote: > On 14 August 2012 17:27, Michael Roth wrote: > > > > Signed-off-by: Michael Roth > > --- > > docs/qidl.txt | 343 > > + > > 1 file changed, 343 insertions(+) > > create mod

[Qemu-devel] [PATCH v7 2/4] Adding qemu-seccomp.[ch]

2012-08-14 Thread Eduardo Otubo
v1: * I added a syscall struct using priority levels as described in the libseccomp man page. The priority numbers are based to the frequency they appear in a sample strace from a regular qemu guest run under libvirt. Libseccomp generates linear BPF code to filter system calls, those

[Qemu-devel] [PATCH v7 4/4] Command line support for seccomp with -sandbox

2012-08-14 Thread Eduardo Otubo
v7: * New in v7 * The seccomp filter can be switched on and off using the command line option "-sandbox", the default value is off. Signed-off-by: Eduardo Otubo --- qemu-config.c | 13 + qemu-config.h |1 + qemu-options.hx | 10 ++ vl.c| 17

[Qemu-devel] [PATCH v7 3/4] Adding seccomp calls to vl.c

2012-08-14 Thread Eduardo Otubo
v1: * Full seccomp calls and data included in vl.c v2: * Full seccomp calls and data removed from vl.c and put into separate qemu-seccomp.[ch] file. Signed-off-by: Eduardo Otubo --- vl.c | 13 + 1 files changed, 13 insertions(+), 0 deletions(-) diff --git a/vl.c b/vl.c index

[Qemu-devel] [PATCH v7 1/4] Adding support for libseccomp in configure and Makefile

2012-08-14 Thread Eduardo Otubo
Adding basic options to the configure script to use libseccomp or not. The default is set to 'no'. If the flag --enable-libseccomp is used, the script will check for its existence using pkg-config. v2: * As I removed all the code related to seccomp from vl.c, I created qemu-seccomp.[ch]. * Al

[Qemu-devel] [PATCH v7 0/4] Sandboxing Qemu guests with Libseccomp

2012-08-14 Thread Eduardo Otubo
Hello all, This patch is an effort to sandbox Qemu guests using Libseccomp[0]. The patches that follows are pretty simple and straightforward. I added the correct options and checks to the configure script and the basic calls to libseccomp in the main loop at vl.c. Details of each one are in the e

[Qemu-devel] [PATCH v3 2/4] Update Linux kernel headers

2012-08-14 Thread Alex Williamson
Based on Linux as of ddf343f6. Note that vfio.h isn't yet an installed header at this commit, but is fixed by trivial update to include/linux/Kbuild. Signed-off-by: Alex Williamson --- linux-headers/asm-s390/kvm.h |2 linux-headers/asm-s390/kvm_para.h |2 linux-headers/asm-x86/k

Re: [Qemu-devel] [RFC 11/20] target-i386: convert 'check' and 'enforce' features into properties

2012-08-14 Thread Igor Mammedov
On Fri, 10 Aug 2012 12:09:04 -0300 Eduardo Habkost wrote: > On Fri, Aug 10, 2012 at 01:22:27PM +0200, Igor Mammedov wrote: > > Signed-off-by: Igor Mammedov > > --- > > target-i386/cpu.c | 68 > > ++- > > 1 file changed, 57 insertions(+), 11 d

[Qemu-devel] [PATCH v3 4/4] vfio: Enable vfio-pci and mark supported

2012-08-14 Thread Alex Williamson
Signed-off-by: Alex Williamson --- MAINTAINERS |5 + configure |6 ++ hw/i386/Makefile.objs |1 + 3 files changed, 12 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 708ad54..327b219 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -468,6 +468,1

Re: [Qemu-devel] [RFC-v2 3/6] vhost-scsi: add -vhost-scsi host device for use with tcm-vhost

2012-08-14 Thread Nicholas A. Bellinger
On Mon, 2012-08-13 at 19:47 +, Blue Swirl wrote: > On Mon, Aug 13, 2012 at 8:35 AM, Nicholas A. Bellinger > wrote: > > From: Stefan Hajnoczi > > > > This patch adds a new type of host device that drives the vhost_scsi > > device. The syntax to add vhost-scsi is: > > > > qemu -vhost-scsi id

Re: [Qemu-devel] Qemu memory operations

2012-08-14 Thread Steven
Hi, Prathmesh I am working on getting the guest memory trace too. You said you have trapped the guest memory access for most instructions. I have three questions. 1. Did you get the guest physical address for the load/store instructions? 2. The code you pasted seems translated code. The number of i

Re: [Qemu-devel] [RFC-v2 3/6] vhost-scsi: add -vhost-scsi host device for use with tcm-vhost

2012-08-14 Thread Nicholas A. Bellinger
On Mon, 2012-08-13 at 11:59 +0300, Michael S. Tsirkin wrote: > On Mon, Aug 13, 2012 at 08:35:14AM +, Nicholas A. Bellinger wrote: > > From: Stefan Hajnoczi > > > > This patch adds a new type of host device that drives the vhost_scsi > > device. The syntax to add vhost-scsi is: > > > > qem

[Qemu-devel] [PATCH v11 2/7] qapi: Introduce add-fd, remove-fd, query-fdsets

2012-08-14 Thread Corey Bryant
This patch adds support that enables passing of file descriptors to the QEMU monitor where they will be stored in specified file descriptor sets. A file descriptor set can be used by a client like libvirt to store file descriptors for the same file. This allows the client to open a file with diff

[Qemu-devel] [PATCH v11 1/7] qemu-char: Add MSG_CMSG_CLOEXEC flag to recvmsg

2012-08-14 Thread Corey Bryant
Set the close-on-exec flag for the file descriptor received via SCM_RIGHTS. Signed-off-by: Corey Bryant --- v4 -This patch is new in v4 (ebl...@redhat.com) v5 -Fallback to FD_CLOEXEC if MSG_CMSG_CLOEXEC is not available (ebl...@redhat.com, stefa...@linux.vnet.ibm.com) v6 -Set cloexec on co

[Qemu-devel] [PATCH v11 7/7] monitor: Clean up fd sets on monitor disconnect

2012-08-14 Thread Corey Bryant
Fd sets are shared by all monitor connections. Fd sets are considered to be in use while at least one monitor is connected. When the last monitor disconnects, all fds that are members of an fd set with no outstanding dup references are closed. This prevents any fd leakage associated with a clien

[Qemu-devel] [PATCH v11 0/7] file descriptor passing using fd sets

2012-08-14 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 v11 6/7] block: Enable qemu_open/close to work with fd sets

2012-08-14 Thread Corey Bryant
When qemu_open is passed a filename of the "/dev/fdset/nnn" format (where nnn is the fdset ID), an fd with matching access mode flags will be searched for within the specified monitor fd set. If the fd is found, a dup of the fd will be returned from qemu_open. Signed-off-by: Corey Bryant --- v2:

[Qemu-devel] [PATCH v11 5/7] block: Convert close calls to qemu_close

2012-08-14 Thread Corey Bryant
This patch converts all block layer close calls, that correspond to qemu_open calls, to qemu_close. Signed-off-by: Corey Bryant --- v5: -This patch is new in v5. (kw...@redhat.com, ebl...@redhat.com) v6-v9: -No changes v10: -Don't use underscore prefix on functions. (blauwir...@gmail.com) v

[Qemu-devel] [PATCH v11 3/7] block: Prevent detection of /dev/fdset/ as floppy

2012-08-14 Thread Corey Bryant
Signed-off-by: Corey Bryant --- v8 -This patch is new in v8. It was reported on a prior fd passing approach and I realized it's needed in this series. (kw...@redhat.com) v9-v11 -No changes block/raw-posix.c |4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/block/ra

[Qemu-devel] [PATCH v11 4/7] block: Convert open calls to qemu_open

2012-08-14 Thread Corey Bryant
This patch converts all block layer open calls to qemu_open. Note that this adds the O_CLOEXEC flag to the changed open paths when the O_CLOEXEC macro is defined. Signed-off-by: Corey Bryant --- v2: -Convert calls to qemu_open instead of file_open (kw...@redhat.com) -Mention introduction of O_

Re: [Qemu-devel] [PATCH v2 3/4] vfio: vfio-pci device assignment driver

2012-08-14 Thread Jan Kiszka
On 2012-08-14 21:09, Alex Williamson wrote: >>> +static void vfio_map_bar(VFIODevice *vdev, int nr) >>> +{ >>> +VFIOBAR *bar = &vdev->bars[nr]; >>> +unsigned size = bar->size; >>> +char name[64]; >>> +uint32_t pci_bar; >>> +uint8_t type; >>> +int ret; >>> + >>> +/* Skip

[Qemu-devel] [PATCH v3 1/4] Update kernel header script to include vfio

2012-08-14 Thread Alex Williamson
Signed-off-by: Alex Williamson --- scripts/update-linux-headers.sh |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/update-linux-headers.sh b/scripts/update-linux-headers.sh index 9d2a4bc..270d32b 100755 --- a/scripts/update-linux-headers.sh +++ b/scripts/update-lin

[Qemu-devel] [PATCH v3 0/4] VFIO-based PCI device assignment for QEMU 1.2

2012-08-14 Thread Alex Williamson
v3: - Incorporate feedback from Anthony, Avi, and Jan (Thank you!) I've also added a new tag to my github tree, so those who have already reviewed can check the delta by comparing: git://github.com/awilliam/qemu-vfio.git tags/vfio-pci-for-qemu-1.2 tags/vfio-pci-for-qemu-1.2-v2

Re: [Qemu-devel] [PATCH] block-migration: deprecate block migration for the 1.2 release

2012-08-14 Thread Luiz Capitulino
On Tue, 14 Aug 2012 22:25:40 +0200 Markus Armbruster wrote: > Anthony Liguori writes: > > > Luiz Capitulino writes: > > > >> On Tue, 14 Aug 2012 08:32:31 -0500 > >> Anthony Liguori wrote: > >> > >>> To be replaced with live block copy. > >>> > >>> Signed-off-by: Anthony Liguori > >>> --- >

Re: [Qemu-devel] [RFC-v2 3/6] vhost-scsi: add -vhost-scsi host device for use with tcm-vhost

2012-08-14 Thread Nicholas A. Bellinger
On Mon, 2012-08-13 at 11:53 +0300, Michael S. Tsirkin wrote: > On Mon, Aug 13, 2012 at 08:35:14AM +, Nicholas A. Bellinger wrote: > > From: Stefan Hajnoczi > > > > This patch adds a new type of host device that drives the vhost_scsi > > device. The syntax to add vhost-scsi is: > > > > qem

[Qemu-devel] [PATCH] PATCH V2: fix NULL dereferences / races between task completition and abort

2012-08-14 Thread Stefan Priebe
Signed-off-by: Stefan Priebe --- block/iscsi.c | 55 +++ 1 files changed, 23 insertions(+), 32 deletions(-) diff --git a/block/iscsi.c b/block/iscsi.c index 12ca76d..1c8b049 100644 --- a/block/iscsi.c +++ b/block/iscsi.c @@ -76,6 +76,10 @@ s

[Qemu-devel] PATCH V2: fix NULL dereferences / races between task completition and abort

2012-08-14 Thread Stefan Priebe
This patch fixes a race and some segfaults which i discovered while testing scsi-generic and unmapping with libiscsi. The first problem is that in iscsi_aio_cancel iscsi_scsi_task_cancel and iscsi_task_mgmt_abort_task_async got called but iscsi_task_mgmt_abort_task_async already calls iscsi_scs

Re: [Qemu-devel] [PATCH] block-migration: deprecate block migration for the 1.2 release

2012-08-14 Thread Luiz Capitulino
On Tue, 14 Aug 2012 14:45:17 -0500 Anthony Liguori wrote: > Luiz Capitulino writes: > > > On Tue, 14 Aug 2012 08:32:31 -0500 > > Anthony Liguori wrote: > > > >> To be replaced with live block copy. > >> > >> Signed-off-by: Anthony Liguori > >> --- > >> migration.c |9 + > >> 1 f

Re: [Qemu-devel] [PATCH] block-migration: deprecate block migration for the 1.2 release

2012-08-14 Thread Markus Armbruster
Anthony Liguori writes: > Luiz Capitulino writes: > >> On Tue, 14 Aug 2012 08:32:31 -0500 >> Anthony Liguori wrote: >> >>> To be replaced with live block copy. >>> >>> Signed-off-by: Anthony Liguori >>> --- >>> migration.c |9 + >>> 1 files changed, 9 insertions(+), 0 deletions(-

Re: [Qemu-devel] [PATCH] iscsi: fix race between task completition and task abortion

2012-08-14 Thread Stefan Priebe
Am 14.08.2012 16:08, schrieb Kevin Wolf: Am 14.08.2012 14:11, schrieb Stefan Hajnoczi: On Tue, Aug 14, 2012 at 1:09 PM, ronnie sahlberg wrote: Is a reply with the text Acked-by: Ronnie Sahlberg sufficient ? Yes But is this only meant as a question or a real Acked-by and I should pick it

Re: [Qemu-devel] [RFC-v2 6/6] virtio-scsi: Fix incorrect VirtIOSCSI->cmd_vqs[0] definition

2012-08-14 Thread Nicholas A. Bellinger
On Mon, 2012-08-13 at 12:02 +0300, Michael S. Tsirkin wrote: > On Mon, Aug 13, 2012 at 08:35:17AM +, Nicholas A. Bellinger wrote: > > From: Nicholas Bellinger > > > > This patch fixes bug in the definition of VirtIOSCSI->cmd_vqs[0], > > where the return of virtio_add_queue() in virtio_scsi_in

Re: [Qemu-devel] [RFC-v2 1/6] msix: Work-around for vhost-scsi with KVM in-kernel MSI injection

2012-08-14 Thread Nicholas A. Bellinger
On Mon, 2012-08-13 at 21:17 +0300, Michael S. Tsirkin wrote: > On Mon, Aug 13, 2012 at 08:06:17PM +0200, Jan Kiszka wrote: > > On 2012-08-13 20:03, Michael S. Tsirkin wrote: > > > On Mon, Aug 13, 2012 at 02:06:10PM +0200, Jan Kiszka wrote: > > >> On 2012-08-13 10:35, Nicholas A. Bellinger wrote: >

Re: [Qemu-devel] [PATCH v8] kvm: notify host when the guest is panicked

2012-08-14 Thread Peter Maydell
On 14 August 2012 19:53, Anthony Liguori wrote: > Forget about !x86 platforms. They have their own way to do this sort of > thing. Think of this feature like a status LED on a motherboard. These > are very common and usually controlled by IO ports. Please don't forget !x86 platforms, we are cu

Re: [Qemu-devel] [PATCH 3/4] s390/kvm: Add a channel I/O based virtio transport driver.

2012-08-14 Thread Anthony Liguori
Cornelia Huck writes: > Add a driver for kvm guests that matches virtual ccw devices provided > by the host as virtio bridge devices. > > These virtio-ccw devices use a special set of channel commands in order > to perform virtio functions. > > Signed-off-by: Cornelia Huck Hi, Have you written

Re: [Qemu-devel] [PULL for-1.2 00/10] linux-user queue

2012-08-14 Thread Blue Swirl
On Tue, Aug 14, 2012 at 9:40 AM, Peter Maydell wrote: > Hi. This is a collection of recent linux-user patches: > * my minor fixes for complaints about ioctl mismatches > * Jing Huang's fixes for running ping > * Meador's guest space probing patches > * and some minor fixes from Mike Frysinger

Re: [Qemu-devel] [PATCH] block-migration: deprecate block migration for the 1.2 release

2012-08-14 Thread Anthony Liguori
Luiz Capitulino writes: > On Tue, 14 Aug 2012 08:32:31 -0500 > Anthony Liguori wrote: > >> To be replaced with live block copy. >> >> Signed-off-by: Anthony Liguori >> --- >> migration.c |9 + >> 1 files changed, 9 insertions(+), 0 deletions(-) >> >> diff --git a/migration.c b/mi

Re: [Qemu-devel] [PATCH 16/20] qidl: Add documentation

2012-08-14 Thread Peter Maydell
On 14 August 2012 17:27, Michael Roth wrote: > > Signed-off-by: Michael Roth > --- > docs/qidl.txt | 343 > + > 1 file changed, 343 insertions(+) > create mode 100644 docs/qidl.txt > > diff --git a/docs/qidl.txt b/docs/qidl.txt > new fil

Re: [Qemu-devel] [PATCH 03/10] linux-user: Move target_to_host_errno_table[] setup out of ioctl loop

2012-08-14 Thread Peter Maydell
On 14 August 2012 19:58, Blue Swirl wrote: > On Tue, Aug 14, 2012 at 6:38 PM, Peter Maydell > wrote: >> On 14 August 2012 19:27, Blue Swirl wrote: >>> On Tue, Aug 14, 2012 at 9:40 AM, Peter Maydell >>> wrote: +/* Build target_to_host_errno_table[] table from + * host_to_targ

Re: [Qemu-devel] [PATCH v8] kvm: notify host when the guest is panicked

2012-08-14 Thread Anthony Liguori
Marcelo Tosatti writes: > On Tue, Aug 14, 2012 at 01:53:01PM -0500, Anthony Liguori wrote: >> Marcelo Tosatti writes: >> >> > On Tue, Aug 14, 2012 at 05:55:54PM +0300, Yan Vugenfirer wrote: >> >> >> >> On Aug 14, 2012, at 1:42 PM, Jan Kiszka wrote: >> >> >> >> > On 2012-08-14 10:56, Daniel P.

Re: [Qemu-devel] [PATCH 0/3] VFIO-based PCI device assignment for QEMU 1.2

2012-08-14 Thread Cole Robinson
On 08/14/2012 11:04 AM, Jan Kiszka wrote: > On 2012-08-14 16:53, Cole Robinson wrote: >> On 08/13/2012 03:31 PM, Anthony Liguori wrote: >>> Jan Kiszka writes: >>> On 2012-08-13 15:58, Avi Kivity wrote: > On 08/13/2012 04:27 PM, Anthony Liguori wrote: > >> Thanks for pushing this f

Re: [Qemu-devel] [PATCH v8] kvm: notify host when the guest is panicked

2012-08-14 Thread Marcelo Tosatti
On Tue, Aug 14, 2012 at 01:53:01PM -0500, Anthony Liguori wrote: > Marcelo Tosatti writes: > > > On Tue, Aug 14, 2012 at 05:55:54PM +0300, Yan Vugenfirer wrote: > >> > >> On Aug 14, 2012, at 1:42 PM, Jan Kiszka wrote: > >> > >> > On 2012-08-14 10:56, Daniel P. Berrange wrote: > >> >> On Mon, Au

Re: [Qemu-devel] [PATCH v2 3/4] vfio: vfio-pci device assignment driver

2012-08-14 Thread Alex Williamson
On Tue, 2012-08-14 at 19:40 +0200, Jan Kiszka wrote: > Just some comments, didn't look at all details. Thanks! I'll send out a v3 soon. I think that the off-by-one in strncat doesn't exist though, so would appreciate if you could double check. Individual comments below... > On 2012-08-02 21:17

Re: [Qemu-devel] [PATCH v2 uq/master] kvmvapic: Disable if there is insufficient memory

2012-08-14 Thread Marcelo Tosatti
On Tue, Aug 14, 2012 at 01:43:12PM +0200, Jan Kiszka wrote: > We need at least 1M of RAM to map the option ROM. Otherwise, we will > corrupt host memory or even crash: > > $ qemu-system-x86_64 -nodefaults --enable-kvm -vnc :0 -m 640k > Segmentation fault (core dumped) > > Reported-and-tes

Re: [Qemu-devel] [PATCH uq/master 1/2] kvm: i8254: Cache kernel clock offset in KVMPITState

2012-08-14 Thread Marcelo Tosatti
On Tue, Aug 14, 2012 at 10:24:03AM +0200, Jan Kiszka wrote: > To prepare the final fix for clock calibration issues with the in-kernel > PIT, we want to cache the offset between vmclock and the clock used by > the in-kernel PIT. So far, we only need to update it when the VM state > changes between

Re: [Qemu-devel] [PATCH 16/20] qidl: Add documentation

2012-08-14 Thread Eric Blake
On 08/14/2012 10:27 AM, Michael Roth wrote: > Signed-off-by: Michael Roth > --- > docs/qidl.txt | 343 > + > 1 file changed, 343 insertions(+) > create mode 100644 docs/qidl.txt > > + > +For the rest, of the document, the following simpl

Re: [Qemu-devel] [PATCH 03/10] linux-user: Move target_to_host_errno_table[] setup out of ioctl loop

2012-08-14 Thread Blue Swirl
On Tue, Aug 14, 2012 at 6:38 PM, Peter Maydell wrote: > On 14 August 2012 19:27, Blue Swirl wrote: >> On Tue, Aug 14, 2012 at 9:40 AM, Peter Maydell >> wrote: >>> The code to initialise the target_to_host_errno_table[] array was >>> accidentally inside the loop through checking and initialising

Re: [Qemu-devel] [PATCH v8] kvm: notify host when the guest is panicked

2012-08-14 Thread Anthony Liguori
Marcelo Tosatti writes: > On Tue, Aug 14, 2012 at 05:55:54PM +0300, Yan Vugenfirer wrote: >> >> On Aug 14, 2012, at 1:42 PM, Jan Kiszka wrote: >> >> > On 2012-08-14 10:56, Daniel P. Berrange wrote: >> >> On Mon, Aug 13, 2012 at 03:21:32PM -0300, Marcelo Tosatti wrote: >> >>> On Wed, Aug 08, 201

Re: [Qemu-devel] [RFC V3 7/9] quorum: Add quorum_co_flush().

2012-08-14 Thread Blue Swirl
On Tue, Aug 14, 2012 at 2:14 PM, Benoît Canet wrote: > Signed-off-by: Benoit Canet > --- > block/quorum.c | 16 > 1 file changed, 16 insertions(+) > > diff --git a/block/quorum.c b/block/quorum.c > index 0a6647f..86962b4 100644 > --- a/block/quorum.c > +++ b/block/quorum.c > @

Re: [Qemu-devel] [PATCH 0/3] VFIO-based PCI device assignment for QEMU 1.2

2012-08-14 Thread Cole Robinson
On 08/13/2012 03:31 PM, Anthony Liguori wrote: > Jan Kiszka writes: > >> On 2012-08-13 15:58, Avi Kivity wrote: >>> On 08/13/2012 04:27 PM, Anthony Liguori wrote: >>> Thanks for pushing this forward! Hopefully this will finally kill off qemu-kvm.git for good. >>> >>> No, it won't. vfi

[Qemu-devel] [PATCH 2/2] register reset handlers to write images into memory

2012-08-14 Thread Olivia Yin
Instead of add rom blobs, this patch just write them directly to memory. This patch registers reset handler uimage_reset() and image_file_reset() which load images into RAM during initial bootup and VM reset. Signed-off-by: Olivia Yin --- This patch is based on branch 'ppc-next' of Alex's upstre

Re: [Qemu-devel] [RFC V3 0/9] Quorum disk image corruption resiliency

2012-08-14 Thread Blue Swirl
On Tue, Aug 14, 2012 at 2:14 PM, Benoît Canet wrote: > This patchset create a block driver implementing a quorum using m qemu disk > images. Writes are mirrored on the m files. > For the reading part the m files are read at the same time and a vote is > done to determine if a qiov version is prese

[Qemu-devel] [Bug 1036645] [NEW] /usr/bin/xargs: rm: Argument list too long during make distclean in cross chroot

2012-08-14 Thread David Cullen
Public bug reported: I am building the Linux kernel in a cross chroot environment. When I run "make distclean", the following messages are emitted: [user@host:/home/work/linux]: make distclean /usr/bin/xargs: rm: Argument list too long make: *** [clean] Error 126 I create the cross chroot enviro

[Qemu-devel] [PATCH 1/2] extract file_load() function from rom_add_file() for reusing

2012-08-14 Thread Olivia Yin
Sanity check in rom_add_file() could be reused by other image loaders. Signed-off-by: Olivia Yin --- This patch is based on branch 'ppc-next' of Alex's upstream QEMU repo: http://repo.or.cz/r/qemu/agraf.git hw/loader.c | 61 +++--- 1 files c

Re: [Qemu-devel] [RFC PATCH 0/4] Live block commit

2012-08-14 Thread Tiziano Müller
Hi Jeff This is an awesome feature and absolutely necessary to get a working live-snapshot/backup solution. What is the status on this? Will it make it into 1.2.0? Thanks in advance, best regards, Tiziano Am Dienstag, den 31.07.2012, 01:16 -0400 schrieb Jeff Cody: > These are proposed changes,

Re: [Qemu-devel] [PULL 0/6 1.2] Tracing patches for QEMU 1.2

2012-08-14 Thread Anthony Liguori
Stefan Hajnoczi writes: > The last pull request from 19 July was not merged. Here it is rebased on > qemu.git/master with two additional fixes from Stefan Weil. I'm not sure what you mean: commit 903f650b0c77827f8d92b35f61419401d648df1e Merge: 61dc008 90a147a Author: Anthony Liguori Date: M

  1   2   3   >