Re: [Qemu-devel] [RFC 06/13] qemu-thread: add TLS wrappers

2013-06-20 Thread Fam Zheng
On Fri, 06/14 11:48, Stefan Hajnoczi wrote: > From: Paolo Bonzini > > Fast TLS is not available on some platforms, but it is always nice to > use it. This wrapper implementation falls back to pthread_get/setspecific > on POSIX systems that lack __thread, but uses the dynamic linker's TLS > suppo

Re: [Qemu-devel] [Xen-devel] [PATCH] Remove hardcoded xen-platform device initialization

2013-06-20 Thread Paul Durrant
> -Original Message- > From: Stefano Stabellini [mailto:stefano.stabell...@eu.citrix.com] > Sent: 19 June 2013 17:28 > To: Paul Durrant > Cc: Stefano Stabellini; Ian Campbell; Paolo Bonzini; xen-de...@lists.xen.org; > qemu-devel@nongnu.org > Subject: RE: [Qemu-devel] [Xen-devel] [PATCH] Rem

Re: [Qemu-devel] [PATCH v3 2/2] QEMUBH: make AioContext's bh re-entrant

2013-06-20 Thread Stefan Hajnoczi
On Thu, Jun 20, 2013 at 04:59:29AM +0800, Liu Ping Fan wrote: > BH will be used outside big lock, so introduce lock to protect > between the writers, ie, bh's adders and deleter. The lock only > affects the writers and bh's callback does not take this extra lock. > Note that for the same AioContext

Re: [Qemu-devel] [PATCH v2 2/6] net: introduce lock to protect NetClientState's peer's access

2013-06-20 Thread Stefan Hajnoczi
On Thu, Jun 20, 2013 at 02:30:30PM +0800, liu ping fan wrote: > On Tue, Jun 18, 2013 at 8:25 PM, Stefan Hajnoczi wrote: > > On Thu, Jun 13, 2013 at 05:03:02PM +0800, Liu Ping Fan wrote: > >> + * And flush out peer's queue. > >> + */ > >> +static void qemu_net_client_detach_flush(NetClientState *nc

Re: [Qemu-devel] [Xen-devel] [PATCH] Add Xen platform PCI device version 2.

2013-06-20 Thread Paul Durrant
> -Original Message- > From: Tim Deegan [mailto:t...@xen.org] > Sent: 19 June 2013 21:15 > To: Matt Wilson > Cc: Alex Bligh; Paul Durrant; xen-de...@lists.xen.org; Ian Campbell; qemu- > de...@nongnu.org > Subject: Re: [Xen-devel] [Qemu-devel] [PATCH] Add Xen platform PCI device > version 2.

Re: [Qemu-devel] [PATCH v2 5/6] net: defer nested call to BH

2013-06-20 Thread Stefan Hajnoczi
On Thu, Jun 20, 2013 at 02:30:56PM +0800, liu ping fan wrote: > On Tue, Jun 18, 2013 at 8:57 PM, Stefan Hajnoczi wrote: > > On Thu, Jun 13, 2013 at 05:03:05PM +0800, Liu Ping Fan wrote: > >> From: Liu Ping Fan > >> > >> Nested call caused by ->receive() will raise issue like deadlock, > >> so pos

Re: [Qemu-devel] [PATCH v2 0/5] qcow2: Discard freed clusters

2013-06-20 Thread Stefan Hajnoczi
On Wed, Jun 19, 2013 at 01:44:16PM +0200, Kevin Wolf wrote: > This series adds options to make qcow2 discard freed clusters, in several > categories. By default, only freed clusters related to snapshots (i.e. mainly > snapshot deletion) are discarded. > > v2: > - Removed leftover debug code > - Do

Re: [Qemu-devel] [PATCH 0/3] qapi: Top-level type reference for command definitions

2013-06-20 Thread Stefan Hajnoczi
On Wed, Jun 19, 2013 at 06:28:04PM +0200, Kevin Wolf wrote: > Kevin Wolf (3): > qapi.py: Move common code to evaluate() > qapi.py: Allow top-level type reference for command definitions > qapi-schema: Use BlockdevSnapshot type for blockdev-snapshot-sync > > qapi-schema.json | 3 +-- > scri

Re: [Qemu-devel] Java volatile vs. C11 seq_cst (was Re: [PATCH v2 1/2] add a header file for atomic operations)

2013-06-20 Thread Paolo Bonzini
Il 19/06/2013 22:25, Torvald Riegel ha scritto: > On Wed, 2013-06-19 at 17:14 +0200, Paolo Bonzini wrote: >> (1) I don't care about relaxed RMW ops (loads/stores occur in hot paths, >> but RMW shouldn't be that bad. I don't care if reference counting is a >> little slower than it could be, for exa

[Qemu-devel] [PATCH v2 2/8] exec: Clean up fall back when -mem-path allocation fails

2013-06-20 Thread Markus Armbruster
With -mem-path, qemu_ram_alloc_from_ptr() first tries to allocate accordingly, but when it fails, it falls back to normal allocation. The fall back allocation code used to be effectively identical to the "-mem-path not given" code, until it started to diverge in commit 432d268. I believe the code

[Qemu-devel] [PATCH v2 1/8] exec: Fix Xen RAM allocation with unusual options

2013-06-20 Thread Markus Armbruster
Issues: * We try to obey -mem-path even though it can't work with Xen. * To implement -machine mem-merge, we call memory_try_enable_merging(new_block->host, size). But with Xen, new_block->host remains null. Oops. Fix by separating Xen allocation from normal allocation. Acked-by: Stefano

[Qemu-devel] [PATCH v2 8/8] pc_sysfw: Fix ISA BIOS init for ridiculously big flash

2013-06-20 Thread Markus Armbruster
pc_isa_bios_init() suffers integer overflow for flash larger than INT_MAX. Signed-off-by: Markus Armbruster --- hw/block/pc_sysfw.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/hw/block/pc_sysfw.c b/hw/block/pc_sysfw.c index 412d1b0..aebefc9 100644 --- a/hw/block/pc_sy

[Qemu-devel] [PATCH v2 3/8] exec: Reduce ifdeffery around -mem-path

2013-06-20 Thread Markus Armbruster
Instead of spreading its ifdeffery everywhere, confine it to qemu_ram_alloc_from_ptr(). Everywhere else, simply test block->fd, which is non-negative exactly when block uses -mem-path. Signed-off-by: Markus Armbruster --- exec.c | 37 ++--- includ

[Qemu-devel] [PATCH v2 4/8] exec: Simplify the guest physical memory allocation hook

2013-06-20 Thread Markus Armbruster
Make it a generic hook rather than a KVM hook. Less code and ifdeffery. Since the only user of the hook is old S390 KVM, there's hope we can get rid of it some day. Acked-by: Christian Borntraeger Signed-off-by: Markus Armbruster --- exec.c | 20 ++-- include/

[Qemu-devel] [PATCH v2 0/8] Guest memory allocation fixes & cleanup

2013-06-20 Thread Markus Armbruster
All I wanted to do is exit(1) instead of abort() on guest memory allocation failure [07/08]. But that lead me into a minor #ifdef bog, and here's what I brought back. Enjoy! Testing: * Christian Borntraeger reports v1 works fine under LPAR (new S390 KVM, i.e. generic allocation) and as second

[Qemu-devel] [PATCH v2 5/8] exec: Drop incorrect & dead S390 code in qemu_ram_remap()

2013-06-20 Thread Markus Armbruster
Old S390 KVM wants guest RAM mapped in a peculiar way. Commit 6b02494 implemented that. When qemu_ram_remap() got added in commit cd19cfa, its code carefully mimicked the allocation code: peculiar way if defined(TARGET_S390X) && defined(CONFIG_KVM), else normal way. For new S390 KVM, we actually

[Qemu-devel] [PATCH v2 6/8] exec: Clean up unnecessary S390 ifdeffery

2013-06-20 Thread Markus Armbruster
Another issue missed in commit fdec991 is -mem-path: it needs to be rejected only for old S390 KVM, not for any S390. Not that I personally care, but the ifdeffery in qemu_ram_alloc_from_ptr() annoys me. Note that this doesn't actually make -mem-path work, as the kernel doesn't (yet?) support la

[Qemu-devel] [PATCH v2 7/8] exec: Don't abort when we can't allocate guest memory

2013-06-20 Thread Markus Armbruster
We abort() on memory allocation failure. abort() is appropriate for programming errors. Maybe most memory allocation failures are programming errors, maybe not. But guest memory allocation failure isn't, and aborting when the user asks for more memory than we can provide is not nice. exit(1) in

Re: [Qemu-devel] [PATCH v3 1/2] pvpanic: initialization cleanup

2013-06-20 Thread Laszlo Ersek
On 06/19/13 17:02, Michael S. Tsirkin wrote: > Avoid use of static variables: PC systems > initialize pvpanic device through pvpanic_init, > so we can simply create the fw_cfg file at that point. > This also makes it possible to skip device > creation completely if fw_cfg is not there, e.g. for xen

Re: [Qemu-devel] [PATCH v3 1/2] add a header file for atomic operations

2013-06-20 Thread Paolo Bonzini
Il 19/06/2013 22:44, Richard Henderson ha scritto: >>> >> +/* Data must be read atomically. We don't really need barrier >>> >> semantics >>> >> + * but it's easier to use atomic_* than roll our own. */ >>> >> +log = atomic_xchg(from, 0); >> > >> > If you really don't need

Re: [Qemu-devel] [Xen-devel] [PATCH] Add Xen platform PCI device version 2.

2013-06-20 Thread Alex Bligh
--On 20 June 2013 07:47:12 + Paul Durrant wrote: If someone has a VM that has the old Citrix drivers installed, or GPLPV, I think I should be able to spot this and make sure that the new bus driver quiesces itself to prevent strangeness ensuing. If and when said previous drivers are un-

Re: [Qemu-devel] [PATCH v3 2/2] QEMUBH: make AioContext's bh re-entrant

2013-06-20 Thread Paolo Bonzini
Il 20/06/2013 09:39, Stefan Hajnoczi ha scritto: > qemu_bh_cancel() and qemu_bh_delete() are not modified by this patch. > > It seems that calling them from a thread is a little risky because there > is no guarantee that the BH is no longer invoked after a thread calls > these functions. > > I th

Re: [Qemu-devel] [Xen-devel] [PATCH] Add Xen platform PCI device version 2.

2013-06-20 Thread Paul Durrant
> -Original Message- > From: Alex Bligh [mailto:a...@alex.org.uk] > Sent: 20 June 2013 09:09 > To: Paul Durrant; Tim (Xen.org); Matt Wilson > Cc: xen-de...@lists.xen.org; Ian Campbell; qemu-devel@nongnu.org; Alex > Bligh > Subject: RE: [Xen-devel] [Qemu-devel] [PATCH] Add Xen platform PCI d

Re: [Qemu-devel] [RESEND PATCH] virtio-scsi: forward scsibus for virtio-scsi-pci.

2013-06-20 Thread Frederic Konrad
On 18/06/2013 17:21, Michael S. Tsirkin wrote: On Fri, Jun 14, 2013 at 08:13:29AM +0200, Frederic Konrad wrote: On 13/06/2013 09:59, Michael S. Tsirkin wrote: On Thu, Jun 13, 2013 at 09:34:30AM +0200, Frederic Konrad wrote: On 13/06/2013 09:23, Michael S. Tsirkin wrote: On Thu, Jun 13, 2013 a

Re: [Qemu-devel] [RESEND PATCH] virtio-scsi: forward scsibus for virtio-scsi-pci.

2013-06-20 Thread Michael S. Tsirkin
On Thu, Jun 20, 2013 at 10:26:18AM +0200, Frederic Konrad wrote: > On 18/06/2013 17:21, Michael S. Tsirkin wrote: > >On Fri, Jun 14, 2013 at 08:13:29AM +0200, Frederic Konrad wrote: > >>On 13/06/2013 09:59, Michael S. Tsirkin wrote: > >>>On Thu, Jun 13, 2013 at 09:34:30AM +0200, Frederic Konrad wro

Re: [Qemu-devel] [PATCH] pseries: Fix compiler warning (conversion of pointer to integral value)

2013-06-20 Thread Alexander Graf
Am 20.06.2013 um 07:10 schrieb Michael Tokarev : > 20.06.2013 01:40, Alexander Graf wrote: >> >> On 19.06.2013, at 23:08, Stefan Weil wrote: >> >>> This kind of type cast must use uintptr_t or target_ulong to be portable >>> for hosts with sizeof(void *) != sizeof(long). >>> >>> Here the valu

Re: [Qemu-devel] [PATCH 6/9] vhost-scsi: new device supporting the tcm_vhost Linux kernel module

2013-06-20 Thread Libaiqing
Hi Asias, Thanks for your config. According to you config,I test booting from vhost device with upstream kernel and qemu,but failed. 1 installing guest from cdrom,ok. 2 booting vhost-scsi,guest fs error occurs. 3 using fileio backstores,the error is same.. 4 rebooting

Re: [Qemu-devel] [RFC 06/13] qemu-thread: add TLS wrappers

2013-06-20 Thread Paolo Bonzini
Il 20/06/2013 09:26, Fam Zheng ha scritto: > On Fri, 06/14 11:48, Stefan Hajnoczi wrote: >> From: Paolo Bonzini >> >> Fast TLS is not available on some platforms, but it is always nice to >> use it. This wrapper implementation falls back to pthread_get/setspecific >> on POSIX systems that lack __

Re: [Qemu-devel] [PATCH 06/12] spapr-vty: add copyright and license

2013-06-20 Thread Paolo Bonzini
Il 19/06/2013 22:40, Anthony Liguori ha scritto: > If you are on CC, then please Ack this patch as you touched this > file at some point in time. > > Cc: Alexey Kardashevskiy > Cc: Andreas Färber > Cc: David Gibson > Cc: Michael Ellerman > Cc: Paolo Bonzini > Signed-off-by: Anthony Liguori >

Re: [Qemu-devel] [Xen-devel] [PATCH] Add Xen platform PCI device version 2.

2013-06-20 Thread Tim Deegan
At 07:47 + on 20 Jun (1371714432), Paul Durrant wrote: > > > I agree. If this is really the only solution, we would need to have > > > both versions presented to the guest so that old drivers continue to > > > work without any intervention. > > > > I suspect that if we expose both, both sets o

Re: [Qemu-devel] [PATCH v4 0/9] Make 'dump-guest-memory' dump in kdump-compressed format

2013-06-20 Thread Stefan Hajnoczi
On Thu, Jun 20, 2013 at 10:18:35AM +0800, Qiao Nuohan wrote: > On 06/19/2013 09:49 PM, Stefan Hajnoczi wrote: > >Where does that code live that writes DISKDUMP files? I can see the > >diskdump.[ch] code. > > Sorry, I cannot catch what do you mean here. Please link to the code that writes DISKDUM

[Qemu-devel] [RFC] qemu-img: add option -d in convert

2013-06-20 Thread Wenchao Xia
Hi, This is a draft design which aimed for internal snapshot convert, hope to get your comments: Internal snapshot is not as easy as external snapshot, to query and convert. This patch will improve convertion side, which helps internal / external snapshot mixed case. With it user can treat int

[Qemu-devel] 1192847 : NMI watchdog fails to increment the NMI counter in /proc/interrupts

2013-06-20 Thread chandrashekar shastri
Hi All, I have filed the following bug for watchdog: NMI watchdog fails to increment the NMI counter in /proc/interrupts Kernel Version: 3.10.0-rc5+ Libvirt Version: 1.0.6 Qemu Version: 1.5.50 Steps to reproduce the issue: 1. Booted the VM with : qemu-system-x86_64 VM1.qcow2 -enable-kvm -watc

[Qemu-devel] Failed booting into OS after introduct the KVM_MEM_READONLY flag for regions

2013-06-20 Thread Zhangleiqiang
HI, Jordan: By using the latest master of qemu, after booting the vnc view will continue to be just black, and the os cannot be start. After bisect, I found the problem was introduced by the commit: 235e8982ad393e5611cb892df54881c872eea9e1 (kvm: support using KVM_MEM_READONLY flag for

Re: [Qemu-devel] [PATCH v2 2/2] QEMUBH: make AioContext's bh re-entrant

2013-06-20 Thread Stefan Hajnoczi
On Wed, Jun 19, 2013 at 11:27:25AM +0200, Paolo Bonzini wrote: > Il 19/06/2013 00:26, mdroth ha scritto: > > On Tue, Jun 18, 2013 at 09:20:26PM +0200, Paolo Bonzini wrote: > >> Il 18/06/2013 17:14, mdroth ha scritto: > >>> Could we possibly simplify this by introducing a recursive mutex that we > >

Re: [Qemu-devel] [PATCH v3 2/2] QEMUBH: make AioContext's bh re-entrant

2013-06-20 Thread liu ping fan
On Thu, Jun 20, 2013 at 4:16 PM, Paolo Bonzini wrote: > Il 20/06/2013 09:39, Stefan Hajnoczi ha scritto: >> qemu_bh_cancel() and qemu_bh_delete() are not modified by this patch. >> >> It seems that calling them from a thread is a little risky because there >> is no guarantee that the BH is no long

Re: [Qemu-devel] [PATCH v2 3/6] net: make netclient re-entrant with refcnt

2013-06-20 Thread liu ping fan
On Tue, Jun 18, 2013 at 8:41 PM, Stefan Hajnoczi wrote: > On Thu, Jun 13, 2013 at 05:03:03PM +0800, Liu Ping Fan wrote: >> From: Liu Ping Fan >> >> With refcnt, NetClientState's user can run agaist deleter. > > Please split this into two patches: > > 1. net_clients lock > 2. NetClientState refcou

Re: [Qemu-devel] [PATCH v2 2/6] net: introduce lock to protect NetClientState's peer's access

2013-06-20 Thread liu ping fan
On Thu, Jun 20, 2013 at 3:46 PM, Stefan Hajnoczi wrote: > On Thu, Jun 20, 2013 at 02:30:30PM +0800, liu ping fan wrote: >> On Tue, Jun 18, 2013 at 8:25 PM, Stefan Hajnoczi wrote: >> > On Thu, Jun 13, 2013 at 05:03:02PM +0800, Liu Ping Fan wrote: >> >> + * And flush out peer's queue. >> >> + */ >>

Re: [Qemu-devel] [PATCH v3 2/2] QEMUBH: make AioContext's bh re-entrant

2013-06-20 Thread Paolo Bonzini
Il 20/06/2013 11:12, liu ping fan ha scritto: >> Right. You need to order ->idle writes before ->scheduled writes, and >> add memory barriers, or alternatively use two bits in ->scheduled so >> that you can assign both atomically. >> > I think just shift the position of smp_rmb/wmb in _schedule an

Re: [Qemu-devel] [Xen-devel] [PATCH] Add Xen platform PCI device version 2.

2013-06-20 Thread Paul Durrant
> -Original Message- > From: Tim Deegan [mailto:t...@xen.org] > Sent: 20 June 2013 09:56 > To: Paul Durrant > Cc: Matt Wilson; Alex Bligh; xen-de...@lists.xen.org; Ian Campbell; qemu- > de...@nongnu.org > Subject: Re: [Xen-devel] [Qemu-devel] [PATCH] Add Xen platform PCI device > version 2.

[Qemu-devel] [Bug 994378] Re: Nested-virt)L1 (kvm on kvm)guest panic with parameter “-cpu host” in qemu command line.

2013-06-20 Thread Kashyap Chamarthy
Short: I can't reproduce here with L1 guest having has host-passthrough for CPU. Long: = Version Info: - On Physical host: ~ $ uname -r; rpm -q libvirt-daemon-kvm qemu 3.10.0-0.rc2.git1.2.fc20.x86_64 qemu-1.4.2-3.fc19.x86_64 libvirt-daemon-kvm-1.0.5.2-1.fc19.x86_6

Re: [Qemu-devel] [PATCH 6/9] vhost-scsi: new device supporting the tcm_vhost Linux kernel module

2013-06-20 Thread Asias He
On Thu, Jun 20, 2013 at 08:49:50AM +, Libaiqing wrote: > Hi Asias, > Thanks for your config. > According to you config,I test booting from vhost device with upstream > kernel and qemu,but failed. > > 1 installing guest from cdrom,ok. > 2 booting vhost-scsi,guest fs error o

Re: [Qemu-devel] [PATCH v3 2/2] QEMUBH: make AioContext's bh re-entrant

2013-06-20 Thread liu ping fan
On Thu, Jun 20, 2013 at 4:16 PM, Paolo Bonzini wrote: > Il 20/06/2013 09:39, Stefan Hajnoczi ha scritto: >> qemu_bh_cancel() and qemu_bh_delete() are not modified by this patch. >> >> It seems that calling them from a thread is a little risky because there >> is no guarantee that the BH is no long

Re: [Qemu-devel] [PATCH v3 2/2] QEMUBH: make AioContext's bh re-entrant

2013-06-20 Thread Paolo Bonzini
Il 20/06/2013 11:41, liu ping fan ha scritto: > On Thu, Jun 20, 2013 at 4:16 PM, Paolo Bonzini wrote: >> Il 20/06/2013 09:39, Stefan Hajnoczi ha scritto: >>> qemu_bh_cancel() and qemu_bh_delete() are not modified by this patch. >>> >>> It seems that calling them from a thread is a little risky bec

Re: [Qemu-devel] Adding a persistent writeback cache to qemu

2013-06-20 Thread Stefan Hajnoczi
On Wed, Jun 19, 2013 at 10:28:53PM +0100, Alex Bligh wrote: > --On 11 April 2013 11:25:48 +0200 Stefan Hajnoczi > wrote: > > >>I'd like to experiment with adding persistent writeback cache to qemu. > >>The use case here is where non-local storage is used (e.g. rbd, ceph) > >>using the qemu driver

Re: [Qemu-devel] [PATCH v3] vl.c: Support multiple CPU ranges on -numa option

2013-06-20 Thread Paolo Bonzini
Il 20/06/2013 11:30, Igor Mammedov ha scritto: > > > So, basically the format seemed easier to work with if we are > > > thinking > > > of using QemuOpts for -numa. Using -cpu rather than cpus probably > > > makes it less ambiguous as well IMO. However, it's probably not a >>

Re: [Qemu-devel] [RFC PATCH 0/4] per-object libraries

2013-06-20 Thread Peter Maydell
On 20 June 2013 10:49, Paolo Bonzini wrote: > This only leaves Darwin. I have no idea about that, and I don't have > anymore a machine to test it. Andreas or Peter, can you shed light? If you have something concrete you'd like me to test I can test it. > But still, libtool wouldn't be a partic

Re: [Qemu-devel] [RFC PATCH 0/4] per-object libraries

2013-06-20 Thread Paolo Bonzini
Il 19/06/2013 22:00, Michael Tokarev ha scritto: > 19.06.2013 22:52, Paolo Bonzini wrote: >> Il 19/06/2013 20:18, Michael Tokarev ha scritto: >>> Currently I expand it like this: >>> >>> $(foreach m, $(filter %.o,$1), $($(m:%.o=%.libs))) >>> >>> Probably I can change that to >>> >>> $(foreach m

[Qemu-devel] [PATCH RFC 01/15] i440fx: remove unused parameter i440fx_state of i440fx_init.

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/i386/pc_piix.c| 4 +--- hw/pci-host/piix.c | 10 -- include/hw/i386/pc.h | 2 +- 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c index 97362f2..1e83c1c 100644 --- a/hw/i386/pc_piix.c +++ b/hw/i386/p

[Qemu-devel] [PATCH RFC 02/15] i440fx: rename i440FX to i440FX-PMC

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/pci-host/piix.c | 60 ++-- include/hw/i386/pc.h | 6 +++--- 2 files changed, 33 insertions(+), 33 deletions(-) diff --git a/hw/pci-host/piix.c b/hw/pci-host/piix.c index 0176ae9..fc955bd 100644 --- a/hw/pci-host/piix

[Qemu-devel] [PATCH RFC 03/15] i440fx: rename i440FX-pcihost to i440FX

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/pci-host/piix.c | 20 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/hw/pci-host/piix.c b/hw/pci-host/piix.c index fc955bd..9c482ec 100644 --- a/hw/pci-host/piix.c +++ b/hw/pci-host/piix.c @@ -38,6 +38,10 @@ * http://download.int

[Qemu-devel] [PATCH RFC 05/15] i440fx pmc: create pmc through comosition

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/pci-host/piix.c | 123 + 1 file changed, 76 insertions(+), 47 deletions(-) diff --git a/hw/pci-host/piix.c b/hw/pci-host/piix.c index 1c5c761..218aca2 100644 --- a/hw/pci-host/piix.c +++ b/hw/pci-host/piix.c @@ -38,

[Qemu-devel] [PATCH RFC 00/15] pc refactor about memory controller

2013-06-20 Thread Hu Tao
This series introduces MemoryController, and refactor pc code about i440fx pmc and q35 mch, and introduces ISAPc to resolve breakage of isapc. The memory hotplug patchset will base on this series. Comments are welcome! Hu Tao (15): i440fx: remove unused parameter i440fx_state of i440fx_init.

[Qemu-devel] [PATCH RFC 09/15] i440fx-pmc: move ram initialization into i440fx-pmc

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/i386/pc.c | 24 +--- hw/i386/pc_piix.c| 5 ++--- hw/pci-host/piix.c | 39 +++ include/hw/i386/pc.h | 3 +-- 4 files changed, 35 insertions(+), 36 deletions(-) diff --git a/hw/i386/pc.c b/hw/i386/

[Qemu-devel] [PATCH RFC 06/15] i440fx-pmc: calculate PCI memory hole directly

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/i386/pc_piix.c| 6 -- hw/pci-host/piix.c | 49 - include/hw/i386/pc.h | 4 3 files changed, 24 insertions(+), 35 deletions(-) diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c index 1e83c1c..3934754 10

[Qemu-devel] [PATCH RFC 08/15] q35-mch: create pci address space

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/i386/pc_q35.c | 13 - hw/pci-host/q35.c | 12 +++- include/hw/pci-host/q35.h | 1 + 3 files changed, 12 insertions(+), 14 deletions(-) diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c index bb0ce6a..109bb64 100644 --- a/hw/i386/p

[Qemu-devel] [PATCH RFC 04/15] i440fx: prepare for composition

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/pci-host/piix.c | 49 +++-- 1 file changed, 31 insertions(+), 18 deletions(-) diff --git a/hw/pci-host/piix.c b/hw/pci-host/piix.c index 9c482ec..1c5c761 100644 --- a/hw/pci-host/piix.c +++ b/hw/pci-host/piix.c @@ -44,6 +44

[Qemu-devel] [PATCH RFC 12/15] introduce memory controller

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/i386/pc.c | 156 +++ hw/pci-host/piix.c | 1 - include/hw/i386/pc.h | 43 ++ 3 files changed, 199 insertions(+), 1 deletion(-) diff --git a/hw/i386/pc.c b/hw/i386/pc.c index 398b201..c28baa2 100

[Qemu-devel] [PATCH RFC 10/15] q35-mch: move ram initialization into q35-mch

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/i386/pc.c | 3 +-- hw/i386/pc_piix.c | 2 +- hw/i386/pc_q35.c | 7 ++- hw/pci-host/q35.c | 36 +++- include/hw/i386/pc.h | 3 +-- include/hw/pci-host/q35.h | 9 +++-- 6 files chang

[Qemu-devel] [PATCH RFC 15/15] move bios loading to MemoryController and ISAPc

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/i386/pc.c| 35 ++- hw/i386/pc_piix.c | 13 ++--- hw/i386/pc_q35.c| 13 ++--- hw/isa/isa_pc.c | 11 +++ include/hw/i386/pc.h| 7 +++ include/hw/isa/isa_pc.h | 1 + 6 fil

[Qemu-devel] [PATCH RFC 11/15] introduce ISAPc

2013-06-20 Thread Hu Tao
Previous refactor breaks isapc. This patch introduces ISAPc and move isapc initializing code to ISAPc. Signed-off-by: Hu Tao --- hw/i386/pc_piix.c | 15 +++ hw/isa/Makefile.objs| 2 +- hw/isa/isa_pc.c | 42 ++ include/hw/isa/

[Qemu-devel] [PATCH RFC 14/15] q35 mch: inherit from MemoryController

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/i386/pc_q35.c | 4 +- hw/pci-host/q35.c | 150 +- include/hw/pci-host/q35.h | 14 + 3 files changed, 32 insertions(+), 136 deletions(-) diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c index d7d9703.

[Qemu-devel] [PATCH RFC 13/15] i440fx pmc: inherit from MemoryController

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/pci-host/piix.c | 159 - 1 file changed, 22 insertions(+), 137 deletions(-) diff --git a/hw/pci-host/piix.c b/hw/pci-host/piix.c index 44ebe0f..71a9b8b 100644 --- a/hw/pci-host/piix.c +++ b/hw/pci-host/piix.c @@ -86

Re: [Qemu-devel] [PATCH v3] vl.c: Support multiple CPU ranges on -numa option

2013-06-20 Thread Igor Mammedov
On Wed, 19 Jun 2013 10:26:42 -0300 Eduardo Habkost wrote: > On Wed, Jun 19, 2013 at 01:42:52PM +0200, Igor Mammedov wrote: > > On Tue, 18 Jun 2013 16:09:49 -0400 > > Bandan Das wrote: > > > > > > > > This allows us to use the cpu property multiple times > > > to specify multiple cpu (ranges) t

[Qemu-devel] [PATCH RFC 07/15] i440fx-pmc: create pci address space

2013-06-20 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/i386/pc_piix.c| 33 +++-- hw/pci-host/piix.c | 16 +--- include/hw/i386/pc.h | 2 +- 3 files changed, 25 insertions(+), 26 deletions(-) diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c index 3934754..1ca705c 100644 ---

[Qemu-devel] [PATCH 0/1] ARM aarch64 TCG tlb fast lookup

2013-06-20 Thread Jani Kokkonen
This patch implements the TCG tlb fast lookup in tcg_out_qemu_ld/st for the aarch64 TCG target. Supports also CONFIG_QEMU_LDST_OPTIMIZATION. Tested running on a x86-64 physical machine running Foundation v8, running a linux 3.2.0 minimal host system based on linaro v8 image build 0.8.4423 for

[Qemu-devel] [PATCH 1/1] tcg/aarch64: Implement tlb lookup fast path

2013-06-20 Thread Jani Kokkonen
Supports CONFIG_QEMU_LDST_OPTIMIZATION Signed-off-by: Jani Kokkonen --- configure|2 +- include/exec/exec-all.h | 16 +++- tcg/aarch64/tcg-target.c | 197 ++ 3 files changed, 162 insertions(+), 53 deletions(-) diff --git a/conf

Re: [Qemu-devel] [PATCH v3 1/2] pvpanic: initialization cleanup

2013-06-20 Thread Stefano Stabellini
On Wed, 19 Jun 2013, Michael S. Tsirkin wrote: > -int pvpanic_init(ISABus *bus) > +void pvpanic_init(ISABus *bus) > { > -isa_create_simple(bus, TYPE_ISA_PVPANIC_DEVICE); > -return 0; > +ISADevice *dev; > +FWCfgState *fw_cfg = fw_cfg_find(); > +if (!fw_cfg) { > +return;

Re: [Qemu-devel] [PATCH 1/2] PPC: Add dump_mmu() for 6xx

2013-06-20 Thread Alexander Graf
On 18.06.2013, at 18:04, Fabien Chouteau wrote: > On 06/18/2013 05:31 PM, Alexander Graf wrote: >>> +for (type = 0; type < 2; type++) >> >> You need braces on these. Please run your patch through checkpatch.pl :). > > I did ;) > > -> ./scripts/checkpatch.pl 0001-PPC-Add-dump_mmu-for-6xx.pa

Re: [Qemu-devel] [PATCH v3] vl.c: Support multiple CPU ranges on -numa option

2013-06-20 Thread Michael Tokarev
20.06.2013 13:52, Paolo Bonzini wrote: > Il 20/06/2013 11:30, Igor Mammedov ha scritto: libvirt uses the "cpus" option already, so we have to keep it working. >> Sure, we can leave it as it's now for some time while a new interface is >> introduced/adopted. And than later deprecate "cpus". >

Re: [Qemu-devel] [PATCH v5 03/11] block: add basic backup support to block driver

2013-06-20 Thread Stefan Hajnoczi
On Wed, Jun 19, 2013 at 01:14:17PM +0200, Paolo Bonzini wrote: > Il 19/06/2013 12:50, Kevin Wolf ha scritto: > >> > +/* Publish progress */ > >> > +job->sectors_read += n; > >> > +job->common.offset += n * BDRV_SECTOR_SIZE; > > This is interesting, because the function is no

Re: [Qemu-devel] [PATCH v5 03/11] block: add basic backup support to block driver

2013-06-20 Thread Stefan Hajnoczi
On Wed, Jun 19, 2013 at 01:19:34PM +0200, Paolo Bonzini wrote: > Il 19/06/2013 12:50, Kevin Wolf ha scritto: > >> > + > >> > +DPRINTF("%s enter %s C%" PRId64 " %" PRId64 " %d\n", > >> > +__func__, bdrv_get_device_name(bs), start, sector_num, > >> > nb_sectors); > > Maybe put the fi

[Qemu-devel] [PATCH] Graphics: Switch to 800x600x32 as default mode

2013-06-20 Thread Alexander Graf
We have stayed at 800x600x15 as default graphics mode for the last 9 years. If there ever was a reason to be there, surely nobody remembers it. However, recently non-Linux PPC guests started to show bad effects on 15 bit color mode. They do work just fine with 32 bits however. So let's switch to

Re: [Qemu-devel] [PATCH v5 03/11] block: add basic backup support to block driver

2013-06-20 Thread Stefan Hajnoczi
On Wed, Jun 19, 2013 at 12:50:16PM +0200, Kevin Wolf wrote: > Am 30.05.2013 um 14:34 hat Stefan Hajnoczi geschrieben: > > +DPRINTF("%s enter %s C%" PRId64 " %" PRId64 " %d\n", > > +__func__, bdrv_get_device_name(bs), start, sector_num, > > nb_sectors); > > Maybe put the first "%s"

Re: [Qemu-devel] [PATCH] Graphics: Switch to 800x600x32 as default mode

2013-06-20 Thread Peter Maydell
On 20 June 2013 13:09, Alexander Graf wrote: > We have stayed at 800x600x15 as default graphics mode for the last 9 years. > If there ever was a reason to be there, surely nobody remembers it. > > However, recently non-Linux PPC guests started to show bad effects on 15 bit > color mode. They do wo

Re: [Qemu-devel] [PATCH v5 06/11] block: add drive-backup QMP command

2013-06-20 Thread Stefan Hajnoczi
On Wed, Jun 19, 2013 at 01:07:42PM +0200, Kevin Wolf wrote: > Am 30.05.2013 um 14:34 hat Stefan Hajnoczi geschrieben: > > @drive-backup > > > > Start a point-in-time copy of a block device to a new destination. The > > status of ongoing drive-backup operations can be checked with > > query-block-

Re: [Qemu-devel] [PATCH v2] s390: Implement dump-guest-memory support for target s390x

2013-06-20 Thread Alexander Graf
On 12.06.2013, at 10:09, Jens Freimann wrote: > From: Ekaterina Tumanova > > With this patch dump-guest-memory on s390 produces an ELF formatted, > crash-readable dump. > In order to implement this, the arch-specific part of dump-guest-memory > was added: > target-s390x/arch_dump.c contains th

Re: [Qemu-devel] [PATCH] Graphics: Switch to 800x600x32 as default mode

2013-06-20 Thread Alexander Graf
On 20.06.2013, at 14:19, Peter Maydell wrote: > On 20 June 2013 13:09, Alexander Graf wrote: >> We have stayed at 800x600x15 as default graphics mode for the last 9 years. >> If there ever was a reason to be there, surely nobody remembers it. >> >> However, recently non-Linux PPC guests started

Re: [Qemu-devel] [PATCH] Add Xen platform PCI device version 2.

2013-06-20 Thread Anthony Liguori
Paul Durrant writes: > The XenServer 6.1+ Citrix Windows PV bus driver binds to a new version > of the Xen platform device (since the newer driver set cannot co-exist > with previous drivers which bind to the existing "xen-platform" type of > device). This patch introduces a new "xen-platform-2"

Re: [Qemu-devel] [RFC PATCH 0/4] per-object libraries

2013-06-20 Thread Paolo Bonzini
Il 20/06/2013 12:06, Peter Maydell ha scritto: >> > This only leaves Darwin. I have no idea about that, and I don't have >> > anymore a machine to test it. Andreas or Peter, can you shed light? > If you have something concrete you'd like me to test I can test it. You can modify the configure pro

Re: [Qemu-devel] [PATCH] Add Xen platform PCI device version 2.

2013-06-20 Thread Paul Durrant
> -Original Message- > I don't understand why two devices are required here and the thread > doesn't really answer that either. Is there a spec for the Xen platform > devices? Take a look at docs/specs for some examples in the tree. > > It certainly helps to have one for discussions like

[Qemu-devel] KVM call agenda for 2013-06-25

2013-06-20 Thread Michael S. Tsirkin
Please, send any topic that you are interested in covering. Thanks, MST -- MST

Re: [Qemu-devel] [RFC PATCH 0/4] per-object libraries

2013-06-20 Thread Peter Maydell
On 20 June 2013 13:39, Paolo Bonzini wrote: > Il 20/06/2013 12:06, Peter Maydell ha scritto: >>> > This only leaves Darwin. I have no idea about that, and I don't have >>> > anymore a machine to test it. Andreas or Peter, can you shed light? >> If you have something concrete you'd like me to tes

Re: [Qemu-devel] [RFC PATCH v6 3/3] Force auto-convegence of live migration

2013-06-20 Thread Paolo Bonzini
Il 14/06/2013 15:58, Chegu Vinod ha scritto: > If a user chooses to turn on the auto-converge migration capability > these changes detect the lack of convergence and throttle down the > guest. i.e. force the VCPUs out of the guest for some duration > and let the migration thread catchup and help co

Re: [Qemu-devel] [RFC 06/13] qemu-thread: add TLS wrappers

2013-06-20 Thread Stefan Hajnoczi
On Thu, Jun 20, 2013 at 10:50:32AM +0200, Paolo Bonzini wrote: > Il 20/06/2013 09:26, Fam Zheng ha scritto: > > On Fri, 06/14 11:48, Stefan Hajnoczi wrote: > >> From: Paolo Bonzini > >> > >> Fast TLS is not available on some platforms, but it is always nice to > >> use it. This wrapper implementa

Re: [Qemu-devel] [PATCH v3] vl.c: Support multiple CPU ranges on -numa option

2013-06-20 Thread Paolo Bonzini
Il 20/06/2013 13:34, Michael Tokarev ha scritto: > 20.06.2013 13:52, Paolo Bonzini wrote: >> Il 20/06/2013 11:30, Igor Mammedov ha scritto: > libvirt uses the "cpus" option already, so we have to keep it working. >>> Sure, we can leave it as it's now for some time while a new interface is >>> i

Re: [Qemu-devel] [PATCH 1/2] PPC: Add dump_mmu() for 6xx

2013-06-20 Thread Fabien Chouteau
On 06/20/2013 01:16 PM, Alexander Graf wrote: > > On 18.06.2013, at 18:04, Fabien Chouteau wrote: > >> On 06/18/2013 05:31 PM, Alexander Graf wrote: +for (type = 0; type < 2; type++) >>> >>> You need braces on these. Please run your patch through checkpatch.pl :). >> >> I did ;) >> >> ->

[Qemu-devel] [PULL 00/21] pci,net,misc enhancements

2013-06-20 Thread Michael S. Tsirkin
From: Michael S. Tsirkin The following changes since commit 90a2541b763b31d2b551b07e24aae3de5266d31b: target-i386: fix over 80 chars warnings (2013-06-15 17:50:38 +) are available in the git repository at: git://git.kernel.org/pub/scm/virt/kvm/mst/qemu.git tags/for_anthony for you to

[Qemu-devel] [PULL 01/21] range: add Range structure

2013-06-20 Thread Michael S. Tsirkin
Sometimes we need to pass ranges around, add a handy structure for this purpose. Note: memory.c defines its own concept of AddrRange structure for working with 128 addresses. It's necessary there for doing range math. This is not needed for most users: struct Range is much simpler, and is only us

[Qemu-devel] [PULL 03/21] pc: pass PCI hole ranges to Guests

2013-06-20 Thread Michael S. Tsirkin
Guest currently has to jump through lots of hoops to guess the PCI hole ranges. It's fragile, and makes us change BIOS each time we add a new chipset. Let's report the window in a ROM file, to make BIOS do exactly what QEMU intends. Signed-off-by: Michael S. Tsirkin --- hw/i386/pc.c |

[Qemu-devel] [PULL 05/21] e1000: cleanup process_tx_desc

2013-06-20 Thread Michael S. Tsirkin
From: Andrew Jones Coverity complains about two overruns in process_tx_desc(). The complaints are false positives, but we might as well eliminate them. The problem is that "hdr" is defined as an unsigned int, but then used to offset an array of size 65536, and another of size 256 bytes. hdr will

[Qemu-devel] [PULL 06/21] kvm: zero-initialize KVM_SET_GSI_ROUTING input

2013-06-20 Thread Michael S. Tsirkin
kvm_add_routing_entry makes an attempt to zero-initialize any new routing entry. However, it fails to initialize padding within the u field of the structure kvm_irq_routing_entry. Other functions like kvm_irqchip_update_msi_route also fail to initialize the padding field in kvm_irq_routing_entry.

[Qemu-devel] [PULL 04/21] pc_piix: cleanup init compat handling

2013-06-20 Thread Michael S. Tsirkin
Make sure 1.4 calls 1.5, 1.3 calls 1.4 etc. This way it's enough to add enough new compat hook in a single place in piix. Signed-off-by: Michael S. Tsirkin --- hw/i386/pc_piix.c | 18 -- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/hw/i386/pc_piix.c b/hw/i386/pc

[Qemu-devel] [PULL 07/21] kvm: skip system call when msi route is unchanged

2013-06-20 Thread Michael S. Tsirkin
Some guests do a large number of mask/unmask calls which currently trigger expensive route update system calls. Detect that route in unchanged and skip the system call. Reported-by: "Zhanghaoyu (A)" Signed-off-by: Michael S. Tsirkin --- kvm-all.c | 4 1 file changed, 4 insertions(+) diff

[Qemu-devel] [PULL 08/21] MAINTAINERS: s/Marcelo/Paolo/

2013-06-20 Thread Michael S. Tsirkin
Marcelo doesn't maintain kvm anymore, Paolo is taking over the job. Update MAINTAINERS to stop flooding Marcelo with mail. Signed-off-by: Michael S. Tsirkin --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index 3412b07..f329406 100644

[Qemu-devel] [PULL 10/21] pvpanic: fix fwcfg for big endian hosts

2013-06-20 Thread Michael S. Tsirkin
Convert port number to little endian when exposing it in fw cfg. Signed-off-by: Michael S. Tsirkin --- hw/misc/pvpanic.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/hw/misc/pvpanic.c b/hw/misc/pvpanic.c index 83ed226..792d8e4 100644 --- a/hw/misc/pvpanic.c +++ b/hw

[Qemu-devel] [PULL 09/21] pvpanic: initialization cleanup

2013-06-20 Thread Michael S. Tsirkin
Avoid use of static variables: PC systems initialize pvpanic device through pvpanic_init, so we can simply create the fw_cfg file at that point. This also makes it possible to skip device creation completely if fw_cfg is not there, e.g. for xen - so the ports it reserves are not discoverable by gue

[Qemu-devel] [PULL 14/21] pci: Abolish pci_find_root_bus()

2013-06-20 Thread Michael S. Tsirkin
From: David Gibson pci_find_root_bus() takes a domain parameter. Currently PCI root buses with domain other than 0 can't be created, so this is more or less a long winded way of retrieving the main PCI root bus. Numbered domains don't actually properly cover the (non x86) possibilities for mult

[Qemu-devel] [PULL 15/21] pci: Use helper to find device's root bus in pci_find_domain()

2013-06-20 Thread Michael S. Tsirkin
From: David Gibson Currently pci_find_domain() performs two functions - it locates the PCI root bus above the given bus, then looks up that root bus's domain number. This patch adds a helper function to perform the first task, finding the root bus for a given PCI device. This is then used in pci

[Qemu-devel] [PULL 21/21] pci: Fold host_buses list into PCIHostState functionality

2013-06-20 Thread Michael S. Tsirkin
From: David Gibson The host_buses list is an odd structure - a list of pointers to PCI root buses existing in parallel to the normal qdev tree structure. This patch removes it, instead putting the link pointers into the PCIHostState structure, which have a 1:1 relationship to PCIHostBus structur

  1   2   3   >