[Qemu-devel] [PATCH for-2.3 2/4] virtio-ccw: range check in READ_VQ_CONF

2015-03-26 Thread Cornelia Huck
Processing for READ_VQ_CONF needs to check whether the requested queue value is actually in the supported range and post a channel program check if not. Cc: qemu-sta...@nongnu.org Reviewed-by: David Hildenbrand Signed-off-by: Cornelia Huck --- hw/s390x/virtio-ccw.c | 4 1 file changed, 4 i

Re: [Qemu-devel] [PATCH v2 4/4] tests: Use qtest_add_data_func() consistently

2015-03-26 Thread Andreas Färber
Am 25.03.2015 um 23:14 schrieb John Snow: > On 03/25/2015 02:20 PM, Andreas Färber wrote: >> Replace uses of g_test_add_data_func() for QTest test cases. >> >> It is still valid to use it for any non-QTest test cases, >> which are not run for multiple target binaries. >> >> Suggested-by: John Snow

Re: [Qemu-devel] [PATCH v5 12/28] qapi: Introduce 'alternate' to replace anonymous union

2015-03-26 Thread Markus Armbruster
Eric Blake writes: > Rather than special-casing "'union':'foo','alternate':{}" as an > unusual union that can represent a non-dictionary, it is nicer > to designate a separate meta-type "'alternate':'foo'" for the > purpose. This involves a lot of documentation tweaks and fallout > from .json fi

Re: [Qemu-devel] [PULL 0/3] Migration pull request

2015-03-26 Thread Peter Maydell
the git repository at: > > git://github.com/juanquintela/qemu.git tags/migration/20150326 > > for you to fetch changes up to 43edc0ed11a4d25f2fe67bb9d89a8a6a0a43b1e0: > > migration: remove last_sent_block from save_page_header (2015-03-26 > 15:31:46 +0100) >

Re: [Qemu-devel] [PATCH v5 13/28] qapi: Add some expr tests

2015-03-26 Thread Markus Armbruster
Eric Blake writes: > Demonstrate that the qapi generator doesn't deal well with > expressions that aren't up to par. Later patches will improve > the expected results as the generator is made stricter. Only > one of the added tests actually behaves sanely at rejecting > obvious problems. > > Not

[Qemu-devel] [PATCH] seccomp: libseccomp version varying according to arch

2015-03-26 Thread Eduardo Otubo
Libseccomp dependency was mandating version 2.2.0 on all architectures and this was causing configure and virt-test to break on non-updates distros. This patch works-around it and give a more flexible way to check the version, giving more time for other distros to update libseccomp version. Signed

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Radim Krčmář
2015-03-25 20:05-0400, Kevin O'Connor: > On Thu, Mar 26, 2015 at 02:35:58AM +0300, Andrey Korolyov wrote: > > Thanks, strangely the reboot is always failing now and always reaching > > seabios greeting. May be prints straightened up a race (e.g. it is not > > int19 problem really). > > > > object

Re: [Qemu-devel] [PATCH v5 06/28] qapi: Add some union tests

2015-03-26 Thread Markus Armbruster
Eric Blake writes: > On 03/26/2015 07:23 AM, Markus Armbruster wrote: >> One more: >> >> [...] >>> diff --git a/tests/qapi-schema/alternate-conflict-string.json >>> b/tests/qapi-schema/alternate-conflict-string.json >>> new file mode 100644 >>> index 000..5fd1a47 >>> --- /dev/null >>> +++ b/

[Qemu-devel] [PULL 00/14] Misc bugfixes for 2.3.0-rc2

2015-03-26 Thread Paolo Bonzini
The following changes since commit 549c4e49788bbb16bdac3fb5480a2177019899e2: Merge remote-tracking branch 'remotes/bkoppelmann/tags/pull-tricore-20150324' into staging (2015-03-24 09:52:19 +) are available in the git repository at: git://github.com/bonzini/qemu.git tags/for-upstream fo

[Qemu-devel] [PULL 04/14] i6300esb: Fix signed integer overflow

2015-03-26 Thread Paolo Bonzini
From: David Gibson If the guest programs a sufficiently large timeout value an integer overflow can occur in i6300esb_restart_timer(). e.g. if the maximum possible timer preload value of 0xf is programmed then we end up with the calculation: timeout = get_ticks_per_sec() * (0xf << 15) /

[Qemu-devel] [PULL 07/14] vmw_pvscsi: use PCI DMA APIs

2015-03-26 Thread Paolo Bonzini
It is wrong to use address_space_memory directly, because there could be an IOMMU in the middle. Passing the entire PVSCSIRingInfo to RS_GET_FIELD and RS_SET_FIELD makes it easy to go back to the PVSCSIState. Signed-off-by: Paolo Bonzini --- hw/scsi/vmw_pvscsi.c | 42 +--

[Qemu-devel] [PULL 08/14] nbd: Fix up comment after commit e140177

2015-03-26 Thread Paolo Bonzini
From: Markus Armbruster Signed-off-by: Markus Armbruster Message-Id: <1427271528-11624-1-git-send-email-arm...@redhat.com> Signed-off-by: Paolo Bonzini --- blockdev-nbd.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/blockdev-nbd.c b/blockdev-nbd.c index b29e456..85c

[Qemu-devel] [PULL 09/14] m68k: memory: Replace memory_region_init_ram with memory_region_allocate_system_memory

2015-03-26 Thread Paolo Bonzini
From: Dirk Müller Commit 0b183fc871:"memory: move mem_path handling to memory_region_allocate_system_memory" split memory_region_init_ram and memory_region_init_ram_from_file. Also it moved mem-path handling a step up from memory_region_init_ram to memory_region_allocate_system_memory. Therefore

[Qemu-devel] [PULL 05/14] cpus: Don't kick un-realized cpus.

2015-03-26 Thread Paolo Bonzini
From: Peter Crosthwaite following a464982499b2f637f6699e3d03e0a9d2e0b5288b, it's now possible for there to be attempts to take the BQL before CPUs have been realized in cases where a machine model inits peripherals before the first CPU. BQL lock aquisition kicks the first_cpu, leading to a segfa

[Qemu-devel] [PULL 01/14] rcu tests: fix compilation on 32-bit ppc

2015-03-26 Thread Paolo Bonzini
32-bit PPC cannot do atomic operations on long long. Inside the loops, we are already using local counters that are summed at the end of the run---with some exceptions (rcu_stress_count for rcutorture, n_nodes for test-rcu-list): fix them to use the same technique. For test-rcu-list, remove the mo

[Qemu-devel] [PULL 03/14] i6300esb: Correct endiannness

2015-03-26 Thread Paolo Bonzini
From: David Gibson The IO operations for the i6300esb watchdog timer are marked as DEVICE_NATIVE_ENDIAN. This is not correct, and - as a PCI device - should be DEVICE_LITTLE_ENDIAN. This allows i6300esb to work on ppc targets (yes, using an Intel ICH derived device on ppc is a bit odd, but the

[Qemu-devel] [PULL 02/14] fw_cfg: factor out initialization of FW_CFG_ID (rev. number)

2015-03-26 Thread Paolo Bonzini
From: "Gabriel L. Somlo" The fw_cfg documentation says this of the revision key (0x0001, FW_CFG_ID): > A 32-bit little-endian unsigned int, this item is used as an interface > revision number, and is currently set to 1 by all QEMU architectures > which expose a fw_cfg device. arm/virt doesn't.

[Qemu-devel] [PULL 14/14] virtio-scsi-dataplane: fix memory leak for VirtIOSCSIVring

2015-03-26 Thread Paolo Bonzini
From: Ting Wang VirtIOSCSIVring which allocated in virtio_scsi_vring_init should be free when dataplane has been stopped or failed to start. Signed-off-by: Ting Wang Message-Id: <1427355752-25844-1-git-send-email-kathy.wangt...@huawei.com> Signed-off-by: Paolo Bonzini --- hw/scsi/virtio-scsi-

[Qemu-devel] [PULL 12/14] exec: avoid possible overwriting of mmaped area in qemu_ram_remap

2015-03-26 Thread Paolo Bonzini
It is not necessary to munmap an area before remapping it with MAP_FIXED; if the memory region specified by addr and len overlaps pages of any existing mapping, then the overlapped part of the existing mapping will be discarded. On the other hand, if QEMU does munmap the pages, there is a small pr

[Qemu-devel] [PULL 06/14] megasas: use PCI DMA APIs

2015-03-26 Thread Paolo Bonzini
It is wrong to use address_space_memory directly, because there could be an IOMMU in the middle. Signed-off-by: Paolo Bonzini --- hw/scsi/megasas.c | 51 --- 1 file changed, 24 insertions(+), 27 deletions(-) diff --git a/hw/scsi/megasas.c b/hw/scs

[Qemu-devel] [PULL 13/14] misc: fix typos in copyright declaration

2015-03-26 Thread Paolo Bonzini
From: Gonglei Add a space after comma. Signed-off-by: Gonglei Message-Id: <1427374663-10168-1-git-send-email-arei.gong...@huawei.com> Reviewed-by: Eric Blake Signed-off-by: Paolo Bonzini --- bootdevice.c | 2 +- tests/usb-hcd-ohci-test.c | 2 +- tests/usb-hcd-uhci-test.c | 2 +-

[Qemu-devel] [PULL 11/14] sparc: memory: Replace memory_region_init_ram with memory_region_allocate_system_memory

2015-03-26 Thread Paolo Bonzini
From: Dirk Müller Commit 0b183fc871:"memory: move mem_path handling to memory_region_allocate_system_memory" split memory_region_init_ram and memory_region_init_ram_from_file. Also it moved mem-path handling a step up from memory_region_init_ram to memory_region_allocate_system_memory. Therefore

[Qemu-devel] [PULL 10/14] mips: memory: Replace memory_region_init_ram with memory_region_allocate_system_memory

2015-03-26 Thread Paolo Bonzini
From: Dirk Müller Commit 0b183fc871:"memory: move mem_path handling to memory_region_allocate_system_memory" split memory_region_init_ram and memory_region_init_ram_from_file. Also it moved mem-path handling a step up from memory_region_init_ram to memory_region_allocate_system_memory. Therefore

Re: [Qemu-devel] [PATCH] seccomp: libseccomp version varying according to arch

2015-03-26 Thread Juan Quintela
Eduardo Otubo wrote: > Libseccomp dependency was mandating version 2.2.0 on all architectures > and this was causing configure and virt-test to break on non-updates > distros. This patch works-around it and give a more flexible way to > check the version, giving more time for other distros to upda

Re: [Qemu-devel] [PATCH v5 14/28] qapi: Better error messages for bad expressions

2015-03-26 Thread Markus Armbruster
Eric Blake writes: > The previous commit demonstrated that the generator overlooked some > fairly basic broken expressions: > - missing metataype > - metatype key has a non-string value > - unknown key in relation to the metatype > - conflicting metatype (this patch treats the second metatype as

Re: [Qemu-devel] [PATCH v5 17/45] Add wrappers and handlers for sending/receiving the postcopy-ram migration messages.

2015-03-26 Thread Dr. David Alan Gilbert
(Only replying to some of the items in this mail - the others I'll get to another time). * David Gibson (da...@gibson.dropbear.id.au) wrote: > On Wed, Feb 25, 2015 at 04:51:40PM +, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > The state of the postcopy proces

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Kevin O'Connor
On Thu, Mar 26, 2015 at 04:58:07PM +0100, Radim Krčmář wrote: > 2015-03-25 20:05-0400, Kevin O'Connor: > > On Thu, Mar 26, 2015 at 02:35:58AM +0300, Andrey Korolyov wrote: > > > Thanks, strangely the reboot is always failing now and always reaching > > > seabios greeting. May be prints straightened

[Qemu-devel] [PATCH] fix assertion in "info memory-devices" if memdev isn't accessible

2015-03-26 Thread Igor Mammedov
showing a memory device whose memdev is removed leads to an assert: (qemu) object_add memory-backend-ram,id=ram0,size=128M (qemu) device_add pc-dimm,id=d0,memdev=ram0 (qemu) object_del ram0 (qemu) info memory-devices ** ERROR:qom/object.c:1274:object_get_canonical_path_component:\

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Andrey Korolyov
On Thu, Mar 26, 2015 at 7:36 PM, Kevin O'Connor wrote: > On Thu, Mar 26, 2015 at 04:58:07PM +0100, Radim Krčmář wrote: >> 2015-03-25 20:05-0400, Kevin O'Connor: >> > On Thu, Mar 26, 2015 at 02:35:58AM +0300, Andrey Korolyov wrote: >> > > Thanks, strangely the reboot is always failing now and alway

[Qemu-devel] [PULL 1/1] gtk: do not call gtk_widget_get_window if drawing area is not initialized

2015-03-26 Thread Gerd Hoffmann
From: Hervé Poussineau This prevents gtk_widget_get_window to return a NULL pointer. Signed-off-by: Hervé Poussineau Signed-off-by: Gerd Hoffmann --- ui/gtk.c | 12 1 file changed, 12 insertions(+) diff --git a/ui/gtk.c b/ui/gtk.c index 6a81076..51abac9 100644 --- a/ui/gtk.c +++

[Qemu-devel] [PULL for-2.3 0/1] gtk: do not call gtk_widget_get_window if drawing area is not initialized

2015-03-26 Thread Gerd Hoffmann
-20150326-1 for you to fetch changes up to 4cdfc93526364bc9b20a21c9edd802d737cec85f: gtk: do not call gtk_widget_get_window if drawing area is not initialized (2015-03-26 17:58:12 +0100) gtk: do not call gtk_widget_get_window if

Re: [Qemu-devel] [PATCH v5 15/28] qapi: Add tests of redefined expressions

2015-03-26 Thread Markus Armbruster
Eric Blake writes: > Demonstrate that the qapi generator doesn't deal very well with > redefined expressions. At the parse level, they are silently > accepted; and while the testsuite just stops at parsing, I've > further tested that many of them cause generator crashes or > invalid C code if th

[Qemu-devel] [PATCH v3 0/2] Add generic can_be_deleted to UserCreatableClass.

2015-03-26 Thread Lin Ma
The patchset adds a generic can_be_deleted callback to UserCreatableClass. It prevents removing a usercreatable object if the callback returns false. Backends could implement the callback if it shoudn't be removed while it's in use. Thank Peter Crosthwaite, Paolo Bonzini, Andreas Färber and Igor

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Kevin O'Connor
On Thu, Mar 26, 2015 at 07:48:09PM +0300, Andrey Korolyov wrote: > On Thu, Mar 26, 2015 at 7:36 PM, Kevin O'Connor wrote: > > I'm not sure if the crash always happens at the "int $0x19" location > > though. Andrey, does the crash always happen with "EIP=d331" and/or > > with "Code=... 19"? > >

[Qemu-devel] [PATCH v3 1/2] qom: Add can_be_deleted callback to UserCreatableClass

2015-03-26 Thread Lin Ma
If backends implement the can_be_deleted and it returns false, Then the qmp_object_del won't delete the given backends. Signed-off-by: Lin Ma --- include/qom/object_interfaces.h | 3 +++ qmp.c | 13 + 2 files changed, 16 insertions(+) diff --git a/include/

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Andrey Korolyov
On Thu, Mar 26, 2015 at 8:06 PM, Kevin O'Connor wrote: > On Thu, Mar 26, 2015 at 07:48:09PM +0300, Andrey Korolyov wrote: >> On Thu, Mar 26, 2015 at 7:36 PM, Kevin O'Connor wrote: >> > I'm not sure if the crash always happens at the "int $0x19" location >> > though. Andrey, does the crash always

[Qemu-devel] [PATCH v3 2/2] hostmem: Prevent removing an in-use memory backend object

2015-03-26 Thread Lin Ma
showing a memory device whose memdev is removed leads an assert: (qemu) object_add memory-backend-ram,id=ram0,size=128M (qemu) device_add pc-dimm,id=d0,memdev=ram0 (qemu) object_del ram0 (qemu) info memory-devices ** ERROR:qom/object.c:1274:object_get_canonical_path_component:\

Re: [Qemu-devel] [PATCH v5 2/6] target-arm: kvm: save/restore mp state

2015-03-26 Thread Peter Maydell
On 23 March 2015 at 17:05, Alex Bennée wrote: > This adds the saving and restore of the current Multi-Processing state > of the machine. While the KVM_GET/SET_MP_STATE API exposes a number of > potential states for x86 we only use two for ARM. Either the process is > running or not. We then save t

Re: [Qemu-devel] [PATCH v5 3/6] hw/intc: arm_gic_kvm.c restore config first

2015-03-26 Thread Peter Maydell
On 23 March 2015 at 17:05, Alex Bennée wrote: > As there is logic to deal with the difference between edge and level > triggered interrupts in the kernel we must ensure it knows the > configuration of the IRQs before we restore the pending state. > > Signed-off-by: Alex Bennée > Acked-by: Christo

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Kevin O'Connor
On Thu, Mar 26, 2015 at 08:08:52PM +0300, Andrey Korolyov wrote: > On Thu, Mar 26, 2015 at 8:06 PM, Kevin O'Connor wrote: > > On Thu, Mar 26, 2015 at 07:48:09PM +0300, Andrey Korolyov wrote: > >> On Thu, Mar 26, 2015 at 7:36 PM, Kevin O'Connor wrote: > >> > I'm not sure if the crash always happen

Re: [Qemu-devel] [PATCH v5 4/6] target-arm: kvm64 sync FP register state

2015-03-26 Thread Peter Maydell
On 23 March 2015 at 17:05, Alex Bennée wrote: > +/* Advanced SIMD and FP registers > + * We map Qn = regs[2n+1]:regs[2n] > + */ > +for (i = 0; i < 32; i++) { > +int rd = i << 1; > +float128 fp_val = make_float128(env->vfp.regs[rd + 1], > +

Re: [Qemu-devel] [PATCH v5 16/28] qapi: Better error messages for duplicated expressions

2015-03-26 Thread Markus Armbruster
Eric Blake writes: > The previous commit demonstrated that the generator overlooked > duplicate expressions: > - a complex type or command reusing a built-in type name > - redeclaration of a type name, whether by the same or different > metatype > - redeclaration of a command or event > - collisi

Re: [Qemu-devel] [PATCH v5 5/6] target-arm: kvm64 fix save/restore of SPSR regs

2015-03-26 Thread Peter Maydell
On 23 March 2015 at 17:05, Alex Bennée wrote: > The current code was negatively indexing the cpu state array and not > synchronizing banked spsr register state with the current mode's spsr > state, causing occasional failures with migration. > > Some munging is done to take care of the aarch64 map

[Qemu-devel] [PATCH 4/7] throttle: Add throttle group support

2015-03-26 Thread Alberto Garcia
The throttle group support use a cooperative round robin scheduling algorithm. The principles of the algorithm are simple: - Each BDS of the group is used as a token in a circular way. - The active BDS computes if a wait must be done and arms the right timer. - If a wait must be done the token t

[Qemu-devel] [PATCH 7/7] throttle: Update throttle infrastructure copyright

2015-03-26 Thread Alberto Garcia
Signed-off-by: Alberto Garcia --- include/qemu/throttle.h | 8 +--- util/throttle.c | 8 +--- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/include/qemu/throttle.h b/include/qemu/throttle.h index 2c560db..5af76f0 100644 --- a/include/qemu/throttle.h +++ b/include

[Qemu-devel] [PATCH 6/7] throttle: add the name of the ThrottleGroup to BlockDeviceInfo

2015-03-26 Thread Alberto Garcia
Signed-off-by: Alberto Garcia --- block/qapi.c | 3 +++ hmp.c| 6 -- qapi/block-core.json | 4 +++- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/block/qapi.c b/block/qapi.c index 65af057..ee823d1 100644 --- a/block/qapi.c +++ b/block/qapi.c @@ -91,6

[Qemu-devel] [PATCH v4 0/7] Block Throttle Group Support

2015-03-26 Thread Alberto Garcia
A new version of the patchset. Here was the previous one: https://lists.gnu.org/archive/html/qemu-devel/2015-03/msg01990.html I checked all the things pointed out by Stefan in his comments and I think all of them are fixed now. In addition to that I detected and fixed some additional problem

Re: [Qemu-devel] [PATCH v5 6/6] target-arm: cpu.h document why env->spsr exists

2015-03-26 Thread Peter Maydell
On 23 March 2015 at 17:05, Alex Bennée wrote: > I was getting very confused about the duplication of state so wanted to > make it explicit. > > Signed-off-by: Alex Bennée > > diff --git a/target-arm/cpu.h b/target-arm/cpu.h > index 083211c..6dc1799 100644 > --- a/target-arm/cpu.h > +++ b/target-a

[Qemu-devel] [PATCH 3/7] throttle: Add throttle group infrastructure tests

2015-03-26 Thread Alberto Garcia
Signed-off-by: Alberto Garcia --- tests/test-throttle.c | 37 +++-- 1 file changed, 35 insertions(+), 2 deletions(-) diff --git a/tests/test-throttle.c b/tests/test-throttle.c index 458f577..4f151ec 100644 --- a/tests/test-throttle.c +++ b/tests/test-throttle.c @@

[Qemu-devel] [PATCH 2/7] throttle: Add throttle group infrastructure

2015-03-26 Thread Alberto Garcia
Signed-off-by: Alberto Garcia --- block/Makefile.objs | 1 + block/throttle-groups.c | 254 include/block/block_int.h | 1 + include/block/throttle-groups.h | 39 ++ 4 files changed, 295 insertions(+) create mode 100644

[Qemu-devel] [PATCH 1/7] throttle: Extract timers from ThrottleState into a separate structure

2015-03-26 Thread Alberto Garcia
From: Benoît Canet Group throttling will share ThrottleState between multiple bs. As a consequence the ThrottleState will be accessed by multiple aio context. Timers are tied to their aio context so they must go out of the ThrottleState structure. This commit paves the way for each bs of a comm

[Qemu-devel] [PATCH 5/7] throttle: acquire the ThrottleGroup lock in bdrv_swap()

2015-03-26 Thread Alberto Garcia
bdrv_swap() touches the fields of a BlockDriverState that are protected by the ThrottleGroup lock. Although those fields end up in their original place, they are temporarily swapped in the process, so there's a chance that an operation on a member of the same group happening on a different thread c

Re: [Qemu-devel] [PATCH v5 17/28] qapi: Allow true, false and null in schema json

2015-03-26 Thread Markus Armbruster
Eric Blake writes: > From: Fam Zheng > > In the near term, we will use it for a sensible-looking > 'gen':false inside command declarations, instead of the > current ugly 'gen':'no'. > > In the long term, it will allow conversion from shorthand > with defaults mentioned only in side-band document

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Andrey Korolyov
On Thu, Mar 26, 2015 at 8:18 PM, Kevin O'Connor wrote: > On Thu, Mar 26, 2015 at 08:08:52PM +0300, Andrey Korolyov wrote: >> On Thu, Mar 26, 2015 at 8:06 PM, Kevin O'Connor wrote: >> > On Thu, Mar 26, 2015 at 07:48:09PM +0300, Andrey Korolyov wrote: >> >> On Thu, Mar 26, 2015 at 7:36 PM, Kevin O'

Re: [Qemu-devel] [PATCH] seccomp: libseccomp version varying according to arch

2015-03-26 Thread Peter Maydell
On 26 March 2015 at 16:21, Juan Quintela wrote: > Eduardo Otubo wrote: >> Libseccomp dependency was mandating version 2.2.0 on all architectures >> and this was causing configure and virt-test to break on non-updates >> distros. This patch works-around it and give a more flexible way to >> check

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Radim Krčmář
2015-03-26 19:48+0300, Andrey Korolyov: > I`ll post a sample event > capture with and without Radim`s proposed patch maybe today or > tomorrow. Thanks. The patch doesn't change runtime behavior, it just adds another data field to the error report, so t

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Radim Krčmář
2015-03-26 12:36-0400, Kevin O'Connor: > On Thu, Mar 26, 2015 at 04:58:07PM +0100, Radim Krčmář wrote: > > Notice the 0xef. My best hypothesis so far is that we fail at resetting > > devices, and 0xef is LOCAL_TIMER_VECTOR from Linux before we rebooted. > > (The bug happens at the first place that

[Qemu-devel] [PATCH 00/22] Dirty bitmap atomic access and optimizations

2015-03-26 Thread Paolo Bonzini
QEMU is currently accessing the dirty bitmaps very liberally, which is understandable since the accesses are cheap. This is however not good for squeezing maximum performance out of dataplane, and is also not good if the accesses become more expensive---as is the case when they use atomic primitiv

[Qemu-devel] [PATCH 02/22] acpi-build: remove dependency from ram_addr.h

2015-03-26 Thread Paolo Bonzini
ram_addr_t is an internal interface, everyone should go through MemoryRegion. Clean it up by making rom_add_blob return a MemoryRegion* and using the new qemu_ram_resize infrastructure. Cc: Michael S. Tsirkin Signed-off-by: Paolo Bonzini --- hw/core/loader.c | 8 hw/i386/acpi-bui

[Qemu-devel] [PATCH 04/22] display: enable DIRTY_MEMORY_VGA tracking explicitly

2015-03-26 Thread Paolo Bonzini
This will be required soon by the memory core. Signed-off-by: Paolo Bonzini --- hw/display/cg3.c | 1 + hw/display/exynos4210_fimd.c | 7 ++- hw/display/g364fb.c | 2 +- hw/display/sm501.c | 1 + hw/display/tcx.c | 1 + 5 files changed, 10 insertion

[Qemu-devel] [PATCH 01/22] memory: add memory_region_ram_resize

2015-03-26 Thread Paolo Bonzini
This is a simple MemoryRegion wrapper for qemu_ram_resize. Cc: Michael S. Tsirkin Signed-off-by: Paolo Bonzini --- include/exec/memory.h | 12 memory.c | 7 +++ 2 files changed, 19 insertions(+) diff --git a/include/exec/memory.h b/include/exec/memory.h index 06f

[Qemu-devel] [PATCH 03/22] memory: the only dirty memory flag for users is DIRTY_MEMORY_VGA

2015-03-26 Thread Paolo Bonzini
DIRTY_MEMORY_MIGRATION is triggered by memory_global_dirty_log_start and memory_global_dirty_log_stop, so it cannot be used with memory_region_set_log. Specify this in the documentation and assert it. Signed-off-by: Paolo Bonzini --- include/exec/memory.h | 3 +-- memory.c | 1 + 2

Re: [Qemu-devel] [PATCH v5 18/28] qapi: Unify type bypass and add tests

2015-03-26 Thread Markus Armbruster
Eric Blake writes: > For a few QMP commands, we are forced to pass an arbitrary type > without tracking it properly in QAPI. Among the existing clients, > this unnamed type was spelled 'dict', 'visitor', and '**'; this > patch standardizes on '**'. > > Meanwhile, for both 'gen' and 'success-resp

[Qemu-devel] [PATCH 08/22] memory: track DIRTY_MEMORY_CODE in mr->dirty_log_mask

2015-03-26 Thread Paolo Bonzini
DIRTY_MEMORY_CODE is only needed for TCG. Signed-off-by: Paolo Bonzini --- include/exec/memory.h | 1 - memory.c | 4 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/include/exec/memory.h b/include/exec/memory.h index 8d5feb2..aa46a52 100644 --- a/include/exec/mem

[Qemu-devel] [PATCH 07/22] ui/console: check memory_region_is_logging

2015-03-26 Thread Paolo Bonzini
dpy_gfx_update_dirty expects DIRTY_MEMORY_VGA logging to be always on, but that will not be the case soon. Because it computes the memory region on the fly for every update (with memory_region_find), it cannot enable/disable logging by itself. Instead, always treat updates as invalidations if dir

[Qemu-devel] [PATCH 05/22] memory: return bitmap from memory_region_is_logging

2015-03-26 Thread Paolo Bonzini
For now it only returns (1 << DIRTY_MEMORY_VGA) or 0, but this will change soon so adjust the callers. Listeners check for "any bit except migration", which is handled via the global start/stop listener callbacks. This in practice means VGA because the code bitmap is TCG-specific; however, be exp

[Qemu-devel] [PATCH 13/22] exec: pass client mask to cpu_physical_memory_set_dirty_range

2015-03-26 Thread Paolo Bonzini
This cuts in half the cost of bitmap operations (which will become more expensive when made atomic) during migration on non-VRAM regions. Signed-off-by: Paolo Bonzini --- exec.c | 23 +-- include/exec/ram_addr.h | 33 - memory.

[Qemu-devel] [PATCH 15/22] memory: do not touch code dirty bitmap unless TCG is enabled

2015-03-26 Thread Paolo Bonzini
cpu_physical_memory_set_dirty_lebitmap unconditionally syncs the DIRTY_MEMORY_CODE bitmap. This however is unused unless TCG is enabled. Signed-off-by: Paolo Bonzini --- include/exec/ram_addr.h | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/include/exec/ram_addr.h b

[Qemu-devel] [PATCH 09/22] memory: return DIRTY_MEMORY_MIGRATION from memory_region_is_logging

2015-03-26 Thread Paolo Bonzini
This will be used to make the setting of bitmaps conditional. Signed-off-by: Paolo Bonzini --- memory.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/memory.c b/memory.c index 3864667..76da05b 100644 --- a/memory.c +++ b/memory.c @@ -1324,7 +1324,11 @@ bool memory_regi

[Qemu-devel] [PATCH 11/22] exec: simplify notdirty_mem_write

2015-03-26 Thread Paolo Bonzini
The function has just set two dirty bits and invalidated code, thus cpu_physical_memory_is_clean cannot return true here. Signed-off-by: Paolo Bonzini --- exec.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/exec.c b/exec.c index ffa57dd..56fd0f5 100644 --- a/exec.c

[Qemu-devel] [PATCH 14/22] exec: only check relevant bitmaps for cleanliness

2015-03-26 Thread Paolo Bonzini
Most of the time, not all bitmaps have to be marked as dirty; do not do anything if the interesting ones are already dirty. Previously, any clean bitmap would have cause all the bitmaps to be marked dirty. In fact, unless running TCG most of the time bitmap operations are not done at all because m

[Qemu-devel] [PATCH 20/22] memory: replace cpu_physical_memory_reset_dirty() with test-and-clear

2015-03-26 Thread Paolo Bonzini
From: Stefan Hajnoczi The cpu_physical_memory_reset_dirty() function is sometimes used together with cpu_physical_memory_get_dirty(). This is not atomic since two separate accesses to the dirty memory bitmap are made. Turn cpu_physical_memory_reset_dirty() and cpu_physical_memory_clear_dirty_ra

[Qemu-devel] [PATCH 12/22] exec: use memory_region_is_logging to optimize dirty tracking

2015-03-26 Thread Paolo Bonzini
memory_region_is_logging now returns the exact set of bitmaps that have to be tracked. Use it instead of the in_migration variable. In the next patch, we will also use it to set only DIRTY_MEMORY_VGA or DIRTY_MEMORY_MIGRATION if necessary. As a result, fewer expensive atomic operations will be r

[Qemu-devel] [PATCH 06/22] framebuffer: check memory_region_is_logging

2015-03-26 Thread Paolo Bonzini
framebuffer.c expects DIRTY_MEMORY_VGA logging to be always on, but that will not be the case soon. Because framebuffer.c computes the memory region on the fly for every update (with memory_region_find), it cannot enable/disable logging by itself. Instead, always treat updates as invalidations if

[Qemu-devel] [PATCH 19/22] migration: move dirty bitmap sync to ram_addr.h

2015-03-26 Thread Paolo Bonzini
From: Stefan Hajnoczi The dirty memory bitmap is managed by ram_addr.h and copied to migration_bitmap[] periodically during live migration. Move the code to sync the bitmap to ram_addr.h where related code lives. Signed-off-by: Stefan Hajnoczi Message-Id: <1417519399-3166-5-git-send-email-stef

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Radim Krčmář
2015-03-26 20:08+0300, Andrey Korolyov: > KVM internal error. Suberror: 2 > extra data[0]: 80ef > extra data[1]: 8b0d Btw. does this part ever change? I see that first report had: KVM internal error. Suberror: 2 extra data[0]: 80d1 extra data[1]: 8b0d Was that a Windows gu

[Qemu-devel] [PATCH 10/22] ram_addr: tweaks to xen_modified_memory

2015-03-26 Thread Paolo Bonzini
Invoke xen_modified_memory from cpu_physical_memory_set_dirty_range_nocode; it is akin to DIRTY_MEMORY_MIGRATION, so set it together with that bitmap. The remaining call from invalidate_and_set_dirty's "else" branch will go away soon. Second, fix the second argument to the function in the cpu_phys

[Qemu-devel] [PATCH 17/22] bitmap: add atomic test and clear

2015-03-26 Thread Paolo Bonzini
From: Stefan Hajnoczi The new bitmap_test_and_clear_atomic() function clears a range and returns whether or not the bits were set. Signed-off-by: Stefan Hajnoczi Message-Id: <1417519399-3166-3-git-send-email-stefa...@redhat.com> [Test before xchg; then a full barrier is needed at the end just l

[Qemu-devel] [PATCH 18/22] memory: use atomic ops for setting dirty memory bits

2015-03-26 Thread Paolo Bonzini
From: Stefan Hajnoczi Use set_bit_atomic() and bitmap_set_atomic() so that multiple threads can dirty memory without race conditions. Signed-off-by: Stefan Hajnoczi Message-Id: <1417519399-3166-4-git-send-email-stefa...@redhat.com> Signed-off-by: Paolo Bonzini --- include/exec/ram_addr.h | 16

[Qemu-devel] [PATCH 16/22] bitmap: add atomic set functions

2015-03-26 Thread Paolo Bonzini
From: Stefan Hajnoczi Use atomic_or() for atomic bitmaps where several threads may set bits at the same time. This avoids the race condition between threads loading an element, bitwise ORing, and then storing the element. When setting all bits in a word we can avoid atomic ops and instead just

[Qemu-devel] [PATCH 21/22] memory: make cpu_physical_memory_sync_dirty_bitmap() fully atomic

2015-03-26 Thread Paolo Bonzini
From: Stefan Hajnoczi The fast path of cpu_physical_memory_sync_dirty_bitmap() directly manipulates the dirty bitmap. Use atomic_xchg() to make the test-and-clear atomic. Signed-off-by: Stefan Hajnoczi Message-Id: <1417519399-3166-7-git-send-email-stefa...@redhat.com> [Only do xchg on nonzero

Re: [Qemu-devel] [PATCH RFC 0/4] target-i386: PC socket/core/thread modeling, part 1

2015-03-26 Thread Igor Mammedov
On Mon, 23 Mar 2015 18:31:59 +0100 Andreas Färber wrote: > Hello, > > This long-postponed series proposes a hierarchical QOM model of socket > and core objects for the x86 PC machines. > > Background is that due to qdev limitations we had to introduce an ICC bus > to be able to hot-add CPUs and

[Qemu-devel] [PATCH 22/22] migration: run bitmap sync outside iothread lock

2015-03-26 Thread Paolo Bonzini
Synchronization of the dirty bitmap can now run concurrently with modifications of it. Note that the change in migration_bitmap_sync is not needed and is only for improved clarity. Signed-off-by: Paolo Bonzini --- arch_init.c | 10 +- include/exec/memory.h | 8 2 fil

Re: [Qemu-devel] [PATCH v5 19/28] qapi: Add some type check tests

2015-03-26 Thread Markus Armbruster
Eric Blake writes: > Demonstrate that the qapi generator silently parses confusing > types, which may cause other errors later on. Later patches > will update the expected results as the generator is made stricter. > > Signed-off-by: Eric Blake > --- [...] > diff --git a/tests/qapi-schema/data-a

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Andrey Korolyov
On Thu, Mar 26, 2015 at 8:40 PM, Radim Krčmář wrote: > 2015-03-26 20:08+0300, Andrey Korolyov: >> KVM internal error. Suberror: 2 >> extra data[0]: 80ef >> extra data[1]: 8b0d > > Btw. does this part ever change? > > I see that first report had: > > KVM internal error. Suberror: 2 > ex

Re: [Qemu-devel] [PULL 00/14] Misc bugfixes for 2.3.0-rc2

2015-03-26 Thread Peter Maydell
On 26 March 2015 at 16:02, Paolo Bonzini wrote: > The following changes since commit 549c4e49788bbb16bdac3fb5480a2177019899e2: > > Merge remote-tracking branch > 'remotes/bkoppelmann/tags/pull-tricore-20150324' into staging (2015-03-24 > 09:52:19 +) > > are available in the git repository

Re: [Qemu-devel] [PATCH v4 0/7] Block Throttle Group Support

2015-03-26 Thread Alberto Garcia
On Thu, Mar 26, 2015 at 07:24:54PM +0200, Alberto Garcia wrote: > - The creation/destruction of ThrottleTimers is now handled internally > when a BlockDriverState is added/removed from a group, since > there's not much point on keeping them separate. This also hides > the timer callbacks fro

Re: [Qemu-devel] [PATCH v5 13/28] qapi: Add some expr tests

2015-03-26 Thread Eric Blake
On 03/26/2015 09:55 AM, Markus Armbruster wrote: > Eric Blake writes: > >> Demonstrate that the qapi generator doesn't deal well with >> expressions that aren't up to par. Later patches will improve >> the expected results as the generator is made stricter. Only >> one of the added tests actuall

Re: [Qemu-devel] [PATCH v5 18/28] qapi: Unify type bypass and add tests

2015-03-26 Thread Eric Blake
On 03/26/2015 11:38 AM, Markus Armbruster wrote: > Eric Blake writes: > >> For a few QMP commands, we are forced to pass an arbitrary type >> without tracking it properly in QAPI. Among the existing clients, >> this unnamed type was spelled 'dict', 'visitor', and '**'; this >> patch standardizes

Re: [Qemu-devel] [PATCH v5 19/28] qapi: Add some type check tests

2015-03-26 Thread Eric Blake
On 03/26/2015 11:58 AM, Markus Armbruster wrote: > Eric Blake writes: > >> Demonstrate that the qapi generator silently parses confusing >> types, which may cause other errors later on. Later patches >> will update the expected results as the generator is made stricter. >> >> Signed-off-by: Eric

Re: [Qemu-devel] [PATCH 3/3] qga support process list, netstat and file stat/delete

2015-03-26 Thread Eric Blake
On 03/25/2015 06:25 AM, itamar.t...@gmail.com wrote: > From: Itamar Tal This patch says 3/3, but I see no 1/3 or 2/3 (let alone a 0/3 cover letter) in the mail archives. > > this patch add support for some more functionality in the qemu-guest-agent, > both for windows and linux. Main added feat

Re: [Qemu-devel] [PULL for-2.3 0/1] gtk: do not call gtk_widget_get_window if drawing area is not initialized

2015-03-26 Thread Peter Maydell
16 +) > > are available in the git repository at: > > git://git.kraxel.org/qemu tags/pull-gtk-20150326-1 > > for you to fetch changes up to 4cdfc93526364bc9b20a21c9edd802d737cec85f: > > gtk: do not call gtk_widget_get_window if drawing

Re: [Qemu-devel] [PATCH] fix assertion in "info memory-devices" if memdev isn't accessible

2015-03-26 Thread Luiz Capitulino
On Thu, 26 Mar 2015 16:42:54 + Igor Mammedov wrote: > showing a memory device whose memdev is removed leads to an assert: > > (qemu) object_add memory-backend-ram,id=ram0,size=128M > (qemu) device_add pc-dimm,id=d0,memdev=ram0 > (qemu) object_del ram0 > (qemu) info memory-devices > ** > ERRO

Re: [Qemu-devel] [PATCH] fix assertion in "info memory-devices" if memdev isn't accessible

2015-03-26 Thread Luiz Capitulino
On Thu, 26 Mar 2015 15:59:25 -0400 Luiz Capitulino wrote: > On Thu, 26 Mar 2015 16:42:54 + > Igor Mammedov wrote: > > > showing a memory device whose memdev is removed leads to an assert: > > > > (qemu) object_add memory-backend-ram,id=ram0,size=128M > > (qemu) device_add pc-dimm,id=d0,mem

Re: [Qemu-devel] [Qemu-discuss] error - Guest has not initialized the display yet.

2015-03-26 Thread Mark Cave-Ayland
On 25/03/15 23:52, Programmingkid wrote: (Added Peter C as CC) > On Mar 25, 2015, at 6:20 PM, qemu-discuss-requ...@nongnu.org > wrote: > >>> QEMU window opens up, but I am getting this error "Guest has not >>> initialized >>> the display yet" >>> I had en

Re: [Qemu-devel] [PATCH] fix assertion in "info memory-devices" if memdev isn't accessible

2015-03-26 Thread Paolo Bonzini
On 26/03/2015 17:42, Igor Mammedov wrote: > +mdevid = object_property_get_str(OBJECT(dimm->hostmem), "id", > + &error_abort); > +mdevpath = g_strdup_printf("/objects/%s", mdevid); > +g_free(mdevid); > +mde

Re: [Qemu-devel] [PATCH v3 1/2] qom: Add can_be_deleted callback to UserCreatableClass

2015-03-26 Thread Paolo Bonzini
On 26/03/2015 18:07, Lin Ma wrote: > If backends implement the can_be_deleted and it returns false, > Then the qmp_object_del won't delete the given backends. > > Signed-off-by: Lin Ma > --- > include/qom/object_interfaces.h | 3 +++ > qmp.c | 13 + > 2 f

Re: [Qemu-devel] E5-2620v2 - emulation stop error

2015-03-26 Thread Radim Krčmář
2015-03-26 21:24+0300, Andrey Korolyov: > On Thu, Mar 26, 2015 at 8:40 PM, Radim Krčmář wrote: > > 2015-03-26 20:08+0300, Andrey Korolyov: > >> KVM internal error. Suberror: 2 > >> extra data[0]: 80ef > >> extra data[1]: 8b0d > > > > Btw. does this part ever change? > > > > I see that firs

Re: [Qemu-devel] [Qemu-discuss] error - Guest has not initialized the display yet.

2015-03-26 Thread Peter Maydell
On 26 March 2015 at 20:31, Mark Cave-Ayland wrote: > I've just done some testing here and I see exactly the same issue - > something is preventing OpenBIOS from executing. A quick session with > git bisect points to the following: > > > c3c1bb99d1c11978d9ce94d1bdcf0705378c1459 is the first bad com

Re: [Qemu-devel] [Qemu-discuss] error - Guest has not initialized the display yet.

2015-03-26 Thread Paolo Bonzini
On 26/03/2015 21:55, Peter Maydell wrote: > I feel like we're recapitulating history here -- is > c3c1bb99d undoing the fix that a87f39543a made for when we > tried this a year ago in 360e607, or is there something > more subtle going on ? It's more subtle. The patch should only make a differen

<    1   2   3   >