[Qemu-devel] [PATCH 08/10] usb: parallelize usb3 streams

2013-08-28 Thread Gerd Hoffmann
usb3 bulk endpoints with streams are implicitly pipelined now, so the requests will actually be processed in parallel. Also allow them to complete out-of-order. Fixes stalls in the uas driver. Cc: qemu-sta...@nongnu.org Signed-off-by: Gerd Hoffmann --- hw/usb/core.c | 7 --- 1 file changed

[Qemu-devel] [PATCH 10/10] Revert "usb-hub: report status changes only once"

2013-08-28 Thread Gerd Hoffmann
This reverts commit a309ee6e0a256f690760abfba44fceaa52a7c2f3. This isn't in line with the usb specification and adds regressions, win7 fails to drive the usb hub for example. Was added because it "solved" the issue of hubs interacting badly with the xhci host controller. Now with the root cause

[Qemu-devel] [PATCH 09/10] usb-hub: add tracepoint for status reports

2013-08-28 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/usb/dev-hub.c | 1 + trace-events | 1 + 2 files changed, 2 insertions(+) diff --git a/hw/usb/dev-hub.c b/hw/usb/dev-hub.c index e865a98..54f63c0 100644 --- a/hw/usb/dev-hub.c +++ b/hw/usb/dev-hub.c @@ -475,6 +475,7 @@ static void usb_hub_handle_data(USBDe

Re: [Qemu-devel] [PATCH V18 01/25] qemu-option: add def_value_str in QemuOptDesc struct and rewrite qemu_opts_print

2013-08-28 Thread Eric Blake
On 08/12/2013 10:31 PM, Dong Xu Wang wrote: > qemu_opts_print has no user now, so can re-write the function safely. > > qemu_opts_print is used while using "qemu-img create", it > produces the same output as previous code. > > The behavior of this function has changed: > > 1. Print every possibl

Re: [Qemu-devel] [edk2] OVMF hung on qemu 1.6.0 with KVM

2013-08-28 Thread Andreas Färber
Am 28.08.2013 14:10, schrieb Laszlo Ersek: > On 08/28/13 13:49, Andreas Färber wrote: >> Am 28.08.2013 13:45, schrieb Laszlo Ersek: >>> (qemu-devel CC'd) >>> >>> On 08/28/13 12:35, Gary Ching-Pang Lin wrote: Hi, I recently updated qemu to 1.6.0 and found OVMF just showed a blank

Re: [Qemu-devel] [PATCH v2] spapr: add "stop-self" RTAS call required to support hot CPU unplug

2013-08-28 Thread David Gibson
On Wed, Aug 28, 2013 at 07:32:51PM +1000, Alexey Kardashevskiy wrote: > PAPR+ requires two RTAS calls to be supported by the hypervisor in > order to allow hotplugging VCPUs from the guest. The "start-cpu" RTAS > call was already there but "stop-self" was not. > > This adds the "stop-self" RTAS ca

Re: [Qemu-devel] [PATCH V18 02/25] qemu-option: avoid duplication of default value in QemuOpts

2013-08-28 Thread Eric Blake
On 08/12/2013 10:31 PM, Dong Xu Wang wrote: > This patch moves the default value entirely to QemuOptDesc. > > When getting the value of an option that hasn't been set, and > QemuOptDesc has a default value, return that. Else, behave as > before. > ... >Else, return NULL. > > Signed-off-by:

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Paolo Bonzini
Il 28/08/2013 11:07, Erik Rull ha scritto: >>> It could be a real difference, actually. An unexpectedly fast disk >>> might screw a sloppy driver. IIRC you're not the first person reporting >>> it. Stefan, do you think using block throttling could fix it (with some >>> trial and error)? >> >> Th

Re: [Qemu-devel] [PATCH v2 0/7] introduce BSD-licensed block driver for "raw"

2013-08-28 Thread Kevin Wolf
Am 21.08.2013 um 12:41 hat Laszlo Ersek geschrieben: > v1->v2: > - added comment to raw_probe() [Kevin] > - fixed raw_reopen_prepare() [Paolo & Kevin] > - keeping BSDL: according to the v1 discussion, LGPLv2+ could work too, > but "but most of the block layer is BSD" [Paolo] and I haven't been >

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Stefan Hajnoczi
On Wed, Aug 28, 2013 at 11:07:55AM +0200, Erik Rull wrote: > To exclude a damage of the image meanwhile, I went back to 1.2.0 and it boots > perfectly. If you have any doubts about image corruption or differences, try: $ qemu-img compare /spinning-disk/vm.img /ssd/vm.img Their contents should

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Benoît Canet
Le Wednesday 28 Aug 2013 à 15:14:41 (+0200), Paolo Bonzini a écrit : > Il 28/08/2013 11:07, Erik Rull ha scritto: > >>> It could be a real difference, actually. An unexpectedly fast disk > >>> might screw a sloppy driver. IIRC you're not the first person reporting > >>> it. Stefan, do you think

[Qemu-devel] [ANNOUNCE] QEMU 1.5.3 Stable released

2013-08-28 Thread Michael Roth
Hi everyone, I am pleased to announce that the QEMU v1.5.3 stable release is now available at: http://wiki.qemu.org/download/qemu-1.5.3.tar.bz2 v1.5.3 is now tagged in the official qemu.git repository, and the stable-1.5 branch has been updated accordingly: http://git.qemu.org/?p=qemu.git;a=sho

Re: [Qemu-devel] Problems with QEMU sdcard while using glib 2.33.8

2013-08-28 Thread Stefan Hajnoczi
On Wed, Aug 28, 2013 at 04:17:24PM +0500, Taimoor Mirza wrote: > Thanks for your reply. Below are answers > > $ grep CONFIG_COROUTINE_BACKEND config-host.mak > CONFIG_COROUTINE_BACKEND=win32 > > (gdb) r > Starting program: C:\tools\qemu\qemu-system-arm.exe > -M realview-eb -m 256 -kernel Debug\\\

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Paolo Bonzini
Il 28/08/2013 15:34, Benoît Canet ha scritto: >> On second thought that is expected. Until throttling kicks in, I/O will >> complete just as fast as without throttling. Maybe limiting the number >> of bytes per second instead of I/O ops would be better. Can you try >> -drive ...,bps=1048576 (pos

Re: [Qemu-devel] [PATCH V9 06/12] NUMA: Add Linux libnuma detection

2013-08-28 Thread Paolo Bonzini
Il 26/08/2013 10:43, Andrew Jones ha scritto: > > - Original Message - >> > On 08/26/2013 03:46 PM, Andrew Jones wrote: > > >>> Is this patch still necessary? I thought that dropping the >>> > >>> > > numa_num_configured_nodes() calls from patch 8/12 got rid >>> > >>> > > of th

Re: [Qemu-devel] [PATCH] pcnet-pci: mark I/O and MMIO as LITTLE_ENDIAN

2013-08-28 Thread Stefan Hajnoczi
On Wed, Aug 28, 2013 at 02:17:39PM +0200, Aurelien Jarno wrote: > Now that the memory subsystem is propagating the endianness correctly, > the pcnet-pci device should have its I/O ports and MMIO memory marked > as LITTLE_ENDIAN, as PCI devices are little endian. > > This makes the pcnet-pci NIC to

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Benoît Canet
> What is the command line to use for avg bps = 1MB/s, max bps = 0? On the monitor it would be: block_set_io_throttle 1048576 0 0 0 0 0 When configuring throttle on the command line it would be: -drive file=foo.raw,if=virtio,cache=none,bps=1048576 Also remember that the code is setting bps_max

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Paolo Bonzini
Il 28/08/2013 15:51, Benoît Canet ha scritto: >> What is the command line to use for avg bps = 1MB/s, max bps = 0? > On the monitor it would be: > > block_set_io_throttle 1048576 0 0 0 0 0 > > When configuring throttle on the command line it would be: > > -drive file=foo.raw,if=virtio,cache=none

Re: [Qemu-devel] [PATCH] pseries: Add H_SET_MODE hcall to change guest exception endianness

2013-08-28 Thread Alexander Graf
On 19.08.2013, at 13:04, Anton Blanchard wrote: > > Hi Anthony, > >>> +if (resource == 4) { >> >> This ought to be a #define. There's no else here, is that expected? >> Should you return failure for a different resource? > > Good point, I made it a define. We were returning H_P2 for a di

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Benoît Canet
> Yes, I'm afraid that the burst is problematic here since the current > throttling algorithm doesn't help (and IIUC it behaves as if it had > max=avg/10 due to the 100ms slice time). This is Windows so no CFQ > here. Do you need to set bps_max=1 or will bps_max=0 work too? In it's current state

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Paolo Bonzini
Il 28/08/2013 16:05, Benoît Canet ha scritto: >> Yes, I'm afraid that the burst is problematic here since the current >> > throttling algorithm doesn't help (and IIUC it behaves as if it had >> > max=avg/10 due to the 100ms slice time). This is Windows so no CFQ >> > here. Do you need to set bps_

Re: [Qemu-devel] [PATCH V6 1/5] throttle: Add a new throttling API implementing continuous leaky bucket.

2013-08-28 Thread Stefan Hajnoczi
On Mon, Aug 26, 2013 at 04:42:48PM +0200, Benoît Canet wrote: > +/* fix bucket parameters */ > +static void throttle_fix_bucket(LeakyBucket *bkt) > +{ > +double min; > + > +/* zero bucket level */ > +bkt->level = 0; > + > +/* The following is done to cope with the cfg block schedule

Re: [Qemu-devel] [PATCH v3 0/3] vfio: fixes for better support for 128 bit memory section sizes

2013-08-28 Thread Alex Williamson
On Wed, 2013-08-28 at 13:09 +0200, Paolo Bonzini wrote: > Il 28/08/2013 11:46, Alexey Kardashevskiy ha scritto: > > On 08/22/2013 09:29 PM, Alexey Kardashevskiy wrote: > >> I made a couple of small patches while debugging VFIO on SPAPR > >> which uses IOMMU MemoryRegion 2^64 bytes long. > >> > >> C

Re: [Qemu-devel] [PATCH V6 3/5] block: Enable the new throttling code in the block layer.

2013-08-28 Thread Stefan Hajnoczi
On Mon, Aug 26, 2013 at 04:42:50PM +0200, Benoît Canet wrote: > @@ -1887,7 +1920,8 @@ int bdrv_commit_all(void) > * > * This function should be called when a tracked request is completing. > */ > -static void tracked_request_end(BdrvTrackedRequest *req) > +static void tracked_request_end(Bloc

Re: [Qemu-devel] [PATCH V6 4/5] block: Add support for throttling burst max in QMP and the command line.

2013-08-28 Thread Stefan Hajnoczi
On Mon, Aug 26, 2013 at 04:42:51PM +0200, Benoît Canet wrote: > @@ -1404,10 +1404,16 @@ Arguments: > - "device": device name (json-string) > - "bps": total throughput limit in bytes per second(json-int) > - "bps_rd": read throughput limit in bytes per second(json-int) > -- "bps_wr": read thro

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Benoît Canet
> Can you whip up a patch to avoid that? Or to honor bps_max if it is > specified (making avg/10 simply the default)? Pushed in the same branch (it honor bps_max if specified). Best regards Benoît

Re: [Qemu-devel] [PATCH V6 5/5] block: Add iops_size to do the iops accounting for a given io size.

2013-08-28 Thread Stefan Hajnoczi
On Mon, Aug 26, 2013 at 04:42:52PM +0200, Benoît Canet wrote: > @@ -1414,6 +1414,7 @@ Arguments: > - "iops_max": total I/O operations max(json-int) > - "iops_rd_max": read I/O operations max(json-int) > - "iops_wr_max": write I/O operations max(json-int) > +- "iops_size": I/O size in bytes w

[Qemu-devel] Direct guest device access from nested guest

2013-08-28 Thread Lluís Vilanova
Hi, I want to get the following setup, but don't know how (or if it's even possible): * A guest VM with two AHCI controllers, with one device each. One of the AHCI controllers provides the VM's disk ("system"), while the other provides another disk ("nested") and uses a different emulation dr

Re: [Qemu-devel] [PATCH v3 0/3] vfio: fixes for better support for 128 bit memory section sizes

2013-08-28 Thread Paolo Bonzini
Il 28/08/2013 16:10, Alex Williamson ha scritto: > On Wed, 2013-08-28 at 13:09 +0200, Paolo Bonzini wrote: >> Il 28/08/2013 11:46, Alexey Kardashevskiy ha scritto: >>> On 08/22/2013 09:29 PM, Alexey Kardashevskiy wrote: I made a couple of small patches while debugging VFIO on SPAPR which

Re: [Qemu-devel] [PATCH] target-arm: Report unimplemented opcodes (LOG_UNIMP)

2013-08-28 Thread Richard Henderson
On 08/28/2013 01:15 AM, Peter Maydell wrote: > [*] not impossible, we already do something on the ppc > that's similar; however I'd really want to take the time to > figure out how to do endianness swapping "properly" > and what qemu does currently before messing with it. I've got a loose plan in

[Qemu-devel] [PATCH v3 00/10] [PULL] qemu-kvm.git uq/master queue

2013-08-28 Thread Gleb Natapov
Anthony, This obsoletes "[PULL v2 0/9] KVM changes for 2013-08-23" The following changes since commit f03d07d4683b2e8325a7cb60b4e14b977b1a869c: Merge remote-tracking branch 'quintela/migration.next' into staging (2013-07-23 10:57:23 -0500) are available in the git repository at: git://gi

[Qemu-devel] [PATCH 09/10] kvm: shorten the parameter list for get_real_device()

2013-08-28 Thread Gleb Natapov
From: Wei Yang get_real_device() has 5 parameters with the last 4 is contained in the first structure. This patch removes the last 4 parameters and directly use them from the first parameter. Acked-by: Alex Williamson Signed-off-by: Wei Yang Signed-off-by: Paolo Bonzini --- hw/i386/kvm/pci-

[Qemu-devel] [PATCH 03/10] kvm: migrate vPMU state

2013-08-28 Thread Gleb Natapov
From: Paolo Bonzini Reviewed-by: Gleb Natapov Signed-off-by: Paolo Bonzini --- target-i386/cpu.h | 23 target-i386/kvm.c | 93 ++--- target-i386/machine.c | 44 +++ 3 files changed, 155 insertions(+), 5

[Qemu-devel] [PATCH 08/10] kvm: i386: fix LAPIC TSC deadline timer save/restore

2013-08-28 Thread Gleb Natapov
From: Marcelo Tosatti The configuration of the timer represented by MSR_IA32_TSCDEADLINE depends on: - APIC LVT Timer register. - TSC value. Change the order to respect the dependency. Signed-off-by: Marcelo Tosatti Signed-off-by: Paolo Bonzini --- target-i386/kvm.c | 29 +

[Qemu-devel] [PATCH 10/10] kvm-stub: fix compilation

2013-08-28 Thread Gleb Natapov
From: Paolo Bonzini Non-KVM targets fail compilation on the uq/master branch. Fix the prototype of kvm_irqchip_add_irqfd_notifier to match the one in kvm-all.c. Signed-off-by: Paolo Bonzini Signed-off-by: Gleb Natapov --- kvm-stub.c |3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)

[Qemu-devel] [PATCH 04/10] kvm: add KVM_IRQFD_FLAG_RESAMPLE support

2013-08-28 Thread Gleb Natapov
From: Vincenzo Maffione Added an EventNotifier* parameter to kvm-all.c:kvm_irqchip_add_irqfd_notifier(), in order to give KVM another eventfd to be used as "resamplefd". See the documentation in the linux kernel sources in Documentation/virtual/kvm/api.txt (section 4.75) for more details. When th

Re: [Qemu-devel] [PATCH] target-arm: Report unimplemented opcodes (LOG_UNIMP)

2013-08-28 Thread Peter Maydell
On 28 August 2013 15:31, Richard Henderson wrote: > On 08/28/2013 01:15 AM, Peter Maydell wrote: >> [*] not impossible, we already do something on the ppc >> that's similar; however I'd really want to take the time to >> figure out how to do endianness swapping "properly" >> and what qemu does cur

Re: [Qemu-devel] [PATCH V6 4/5] block: Add support for throttling burst max in QMP and the command line.

2013-08-28 Thread Benoît Canet
> Space before (json-int). Also we might want to document in which QEMU > version the *_max fields were added. The place to document the version seems to be qapi-schema.json and it's done. Best regards Benoît

[Qemu-devel] [PATCH v2 0/5] qcow2: Add metadata overlap checks

2013-08-28 Thread Max Reitz
If a qcow2 image file becomes corrupted, any write may inadvertently overwrite important metadata structures such as the L1 table. This series adds functionality for detecting, preventing and (to some extent) repairing such collisions. v2: - Generally implemented Kevin's comments, especially:

[Qemu-devel] [PATCH v2 1/5] qcow2: Add corrupt bit

2013-08-28 Thread Max Reitz
This adds an incompatible bit indicating corruption to qcow2. Any image with this bit set may not be written to unless for repairing (and subsequently clearing the bit if the repair has been successful). Signed-off-by: Max Reitz --- block/qcow2.c | 45 +++

[Qemu-devel] [PATCH v2 5/5] qemu-iotests: Overlapping cluster allocations

2013-08-28 Thread Max Reitz
A new test on corrupted images with overlapping cluster allocations. Signed-off-by: Max Reitz --- tests/qemu-iotests/060 | 111 + tests/qemu-iotests/060.out | 37 +++ tests/qemu-iotests/group | 1 + 3 files changed, 149 insertions(

[Qemu-devel] [PATCH v2 4/5] qcow2: More complete consistency check

2013-08-28 Thread Max Reitz
The qcow2_check_refcounts function has been extended to be able to fix OFLAG_COPIED errors and multiple references on refcount blocks. If no corruptions remain after an image repair (and no errors have been encountered), clear the corrupt flag in qcow2_check. Signed-off-by: Max Reitz --- block/

[Qemu-devel] [PATCH V7 0/5] Continuous Leaky Bucket Throttling

2013-08-28 Thread Benoît Canet
This patchset implement continous leaky bucket throttling. It use two requests queue to enable to do silly unbalanced throttling like block_set_io_throttle 0 0 0 0 6000 1 It use two timer to get the timer callbacks and the throttle.c code simple in this version: The throttling core is pretty so

[Qemu-devel] [PATCH V7 1/5] throttle: Add a new throttling API implementing continuous leaky bucket.

2013-08-28 Thread Benoît Canet
Implement the continuous leaky bucket algorithm devised on IRC as a separate module. Signed-off-by: Benoit Canet --- include/qemu/throttle.h | 103 + util/Makefile.objs |1 + util/throttle.c | 389 +++ 3 files changed, 49

[Qemu-devel] [PATCH V7 2/5] throttle: Add units tests

2013-08-28 Thread Benoît Canet
Signed-off-by: Benoit Canet --- tests/Makefile|2 + tests/test-throttle.c | 481 + 2 files changed, 483 insertions(+) create mode 100644 tests/test-throttle.c diff --git a/tests/Makefile b/tests/Makefile index b0200fd..6d2f3ad 100644

[Qemu-devel] [PATCH V7 5/5] block: Add iops_size to do the iops accounting for a given io size.

2013-08-28 Thread Benoît Canet
This feature can be used in case where users are avoiding the iops limit by doing jumbo I/Os hammering the storage backend. Signed-off-by: Benoit Canet --- block/qapi.c |3 +++ blockdev.c | 21 ++--- hmp.c|8 ++-- qapi-schema.json | 10 ++

[Qemu-devel] [PATCH V7 3/5] block: Enable the new throttling code in the block layer.

2013-08-28 Thread Benoît Canet
Signed-off-by: Benoit Canet --- block.c | 356 +++-- block/qapi.c | 21 ++- blockdev.c| 100 +++-- include/block/block.h |1 - include/block/block_int.h | 32 +--- 5 files changed, 183 ins

[Qemu-devel] [PATCH V7 4/5] block: Add support for throttling burst max in QMP and the command line.

2013-08-28 Thread Benoît Canet
The max parameter of the leaky bucket throttling algorithm can be used to allow the guest to do bursts. The max value is a pool of I/O that the guest can use without being throttled at all. Throttling is triggered once this pool is empty. Signed-off-by: Benoit Canet --- block/qapi.c | 26 +

Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-28 Thread Alex Williamson
On Thu, 2013-08-22 at 21:29 +1000, Alexey Kardashevskiy wrote: > Upcoming VFIO on SPAPR PPC64 support will initialize the IOMMU > memory region with UINT64_MAX (2^64 bytes) size so int128_get64() > will assert. > > The patch takes care of this check. The existing type1 IOMMU code > is not expected

Re: [Qemu-devel] [PATCH qom-cpu/arm-devs] hw/cpu/a15mpcore: Use qemu_get_cpu() for generic timers

2013-08-28 Thread Andreas Färber
Am 21.08.2013 18:45, schrieb Andreas Färber: > This simplifies the loop and aids with refactoring of CPU list. > > Requested-by: Peter Maydell > Signed-off-by: Andreas Färber > --- > hw/cpu/a15mpcore.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) Seeing no objection or pick-up

Re: [Qemu-devel] [PATCH qom-cpu/arm-devs] hw/cpu/a15mpcore: Use qemu_get_cpu() for generic timers

2013-08-28 Thread Peter Maydell
On 28 August 2013 16:19, Andreas Färber wrote: > Am 21.08.2013 18:45, schrieb Andreas Färber: >> This simplifies the loop and aids with refactoring of CPU list. >> >> Requested-by: Peter Maydell >> Signed-off-by: Andreas Färber >> --- >> hw/cpu/a15mpcore.c | 5 ++--- >> 1 file changed, 2 insert

[Qemu-devel] [RFC] Streamlining endian handling in TCG

2013-08-28 Thread Richard Henderson
On 08/28/2013 07:34 AM, Peter Maydell wrote: > On 28 August 2013 15:31, Richard Henderson wrote: >> On 08/28/2013 01:15 AM, Peter Maydell wrote: >>> [*] not impossible, we already do something on the ppc >>> that's similar; however I'd really want to take the time to >>> figure out how to do endia

Re: [Qemu-devel] Would virtio support 64 bit address for vring virtqueue?

2013-08-28 Thread Xie, Huawei
I know it is PFN, that is why I want to use the high 12bit for combined write in another reply, to fully address 64 bit address. Is the 16TB address space what it is originally designed for? If it is, that will basically solve the problem. I will try later. Thanks for reminder -Original Mess

Re: [Qemu-devel] [PATCH 10/10] Revert "usb-hub: report status changes only once"

2013-08-28 Thread Gerd Hoffmann
On Mi, 2013-08-28 at 17:13 +0200, Hans de Goede wrote: > Hi, > > On 08/28/2013 02:43 PM, Gerd Hoffmann wrote: > > This reverts commit a309ee6e0a256f690760abfba44fceaa52a7c2f3. > > > > This isn't in line with the usb specification and adds regressions, > > win7 fails to drive the usb hub for exampl

Re: [Qemu-devel] [PATCH qom-cpu/arm-devs] hw/cpu/a15mpcore: Use qemu_get_cpu() for generic timers

2013-08-28 Thread Andreas Färber
Am 28.08.2013 17:22, schrieb Peter Maydell: > On 28 August 2013 16:19, Andreas Färber wrote: >> Am 21.08.2013 18:45, schrieb Andreas Färber: >>> This simplifies the loop and aids with refactoring of CPU list. >>> >>> Requested-by: Peter Maydell >>> Signed-off-by: Andreas Färber >>> --- >>> hw/c

Re: [Qemu-devel] [PATCH 0/2] Make mixer emulation configurable at runtime

2013-08-28 Thread Bandan Das
Markus Armbruster writes: > Bandan Das writes: > >> Currently, hda-codec mixer emulation can only be enabled by using the >> "--enable-mixemu" option to configure at compile time. These patches add >> the option to make it configurable at runtime as well. >> >> An example usage could be a qemu

[Qemu-devel] [RFC PATCH] convert ram_list to RCU DQ

2013-08-28 Thread Mike Day
Allow "unlocked" reads of the ram_list by using an RCU-enabled DQ. Most readers of the list no longer require holding the list mutex. The ram_list now uses a QLIST instead of a QTAILQ. The difference is minimal. This patch has been built and make-checked for the x86_64, ppc64, s390x, and arm targ

Re: [Qemu-devel] [PATCH qom-cpu/arm-devs] hw/cpu/a15mpcore: Use qemu_get_cpu() for generic timers

2013-08-28 Thread Peter Maydell
On 28 August 2013 16:35, Andreas Färber wrote: > For the MPCore series in my ARM/Tegra tree you wanted an assert for > object_initialize(). I am waiting for you to comment on my more > invasive/complete series (last part being optional), which would then > with any suggested changes go through my

Re: [Qemu-devel] [PATCH qom-cpu/arm-devs] hw/cpu/a15mpcore: Use qemu_get_cpu() for generic timers

2013-08-28 Thread Andreas Färber
Am 28.08.2013 18:11, schrieb Peter Maydell: > On 28 August 2013 16:35, Andreas Färber wrote: >> For the MPCore series in my ARM/Tegra tree you wanted an assert for >> object_initialize(). I am waiting for you to comment on my more >> invasive/complete series (last part being optional), which would

Re: [Qemu-devel] [PATCH 10/10] Revert "usb-hub: report status changes only once"

2013-08-28 Thread Hans de Goede
Hi, On 08/28/2013 02:43 PM, Gerd Hoffmann wrote: This reverts commit a309ee6e0a256f690760abfba44fceaa52a7c2f3. This isn't in line with the usb specification and adds regressions, win7 fails to drive the usb hub for example. Was added because it "solved" the issue of hubs interacting badly with

[Qemu-devel] [PATCH] qemu-qa: fix build with mingw

2013-08-28 Thread Yan Vugenfirer
Fixing broken stand alone build of qemu-ga using mingw. The problem was introduced by commit e8ef31a35. Signed-off-by: Yan Vugenfirer --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index 0a55c20..20becfa 100755 --- a/configure +++ b/config

[Qemu-devel] [PATCH v2 2/5] qcow2: Metadata overlap checks

2013-08-28 Thread Max Reitz
Two new functions are added; the first one checks a given range in the image file for overlaps with metadata (main header, L1 tables, L2 tables, refcount table and blocks). The second one should be used immediately before writing to the image file as it calls the first function and, upon collision

[Qemu-devel] [PATCH 01/10] Initialize IA32_FEATURE_CONTROL MSR in reset and migration

2013-08-28 Thread Gleb Natapov
From: Arthur Chunqi Li The recent KVM patch adds IA32_FEATURE_CONTROL support. QEMU needs to clear this MSR when reset vCPU and keep the value of it when migration. This patch add this feature. Signed-off-by: Arthur Chunqi Li Signed-off-by: Gleb Natapov --- target-i386/cpu.h |2 ++ ta

Re: [Qemu-devel] [RFC PATCH] convert ram_list to RCU DQ

2013-08-28 Thread Paolo Bonzini
Il 28/08/2013 18:02, Mike Day ha scritto: > @@ -457,8 +459,9 @@ static int ram_save_block(QEMUFile *f, bool last_stage) > MemoryRegion *mr; > ram_addr_t current_addr; > > +rcu_read_lock(); > if (!block) > -block = QTAILQ_FIRST(&ram_list.blocks); > +block = QLIST

Re: [Qemu-devel] [PATCH 7/7] tcg-i386: Perform tail call to qemu_ret_ld*_mmu

2013-08-28 Thread Richard Henderson
On 08/27/2013 02:46 PM, Richard Henderson wrote: > -{ INDEX_op_qemu_ld8u, { "r", "L" } }, > -{ INDEX_op_qemu_ld8s, { "r", "L" } }, > -{ INDEX_op_qemu_ld16u, { "r", "L" } }, > -{ INDEX_op_qemu_ld16s, { "r", "L" } }, > -{ INDEX_op_qemu_ld32, { "r", "L" } }, > -{ INDEX_op_qemu_

Re: [Qemu-devel] [RFC PATCH] convert ram_list to RCU DQ

2013-08-28 Thread Paolo Bonzini
Il 28/08/2013 18:02, Mike Day ha scritto: > @@ -1102,15 +1110,15 @@ void qemu_ram_set_idstr(ram_addr_t addr, const char > *name, DeviceState *dev) > pstrcat(new_block->idstr, sizeof(new_block->idstr), name); > > /* This assumes the iothread lock is taken here too. */ > -qemu_mutex

Re: [Qemu-devel] [RFC] Streamlining endian handling in TCG

2013-08-28 Thread Peter Maydell
On 28 August 2013 16:26, Richard Henderson wrote: > On 08/28/2013 07:34 AM, Peter Maydell wrote: >> On 28 August 2013 15:31, Richard Henderson wrote: >>> On 08/28/2013 01:15 AM, Peter Maydell wrote: [*] not impossible, we already do something on the ppc that's similar; however I'd reall

Re: [Qemu-devel] [PATCH 0/2] Make mixer emulation configurable at runtime

2013-08-28 Thread Markus Armbruster
Bandan Das writes: > Markus Armbruster writes: > >> Bandan Das writes: >> >>> Currently, hda-codec mixer emulation can only be enabled by using the >>> "--enable-mixemu" option to configure at compile time. These patches add >>> the option to make it configurable at runtime as well. >>> >>> A

[Qemu-devel] [PATCH 07/10] kvm-all.c: max_cpus should not exceed KVM vcpu limit

2013-08-28 Thread Gleb Natapov
From: Marcelo Tosatti maxcpus, which specifies the maximum number of hotpluggable CPUs, should not exceed KVM's vcpu limit. Signed-off-by: Marcelo Tosatti [Reword message. - Paolo] Signed-off-by: Paolo Bonzini --- kvm-all.c |7 +++ 1 file changed, 7 insertions(+) diff --git a/kvm-all

Re: [Qemu-devel] [PATCH] mips_malta: support up to 2GiB RAM

2013-08-28 Thread Aurelien Jarno
On Fri, Aug 23, 2013 at 04:09:46PM +0100, Yongbok Kim wrote: > From: Paul Burton > > A Malta board can support up to 2GiB of RAM. Since the unmapped kseg0/1 > regions are only 512MiB large & the latter 256MiB of those are taken up > by the IO region, access to RAM beyond 256MiB must be done throu

[Qemu-devel] [PATCH v2 3/5] qcow2: Employ metadata overlap checks

2013-08-28 Thread Max Reitz
The pre-write overlap check function is now called before most of the qcow2 writes (aborting it on collision or other error). Signed-off-by: Max Reitz --- block/qcow2-cache.c| 17 + block/qcow2-cluster.c | 21 + block/qcow2-snapshot.c | 22 +++

Re: [Qemu-devel] [PATCH] hw: fix to display correct memory size

2013-08-28 Thread Aurelien Jarno
On Fri, Aug 23, 2013 at 03:57:18PM +0100, Yongbok Kim wrote: > A parenthesis placed inappropriately caused displaying > wrong memory size bigger than 4GB. > > Signed-off-by: Yongbok Kim > --- > hw/mips/mips_malta.c |2 +- > hw/mips/mips_r4k.c|2 +- > hw/ppc/mac_oldworld.c |2 +-

Re: [Qemu-devel] Direct guest device access from nested guest

2013-08-28 Thread Jan Kiszka
On 2013-08-28 16:28, Lluís Vilanova wrote: > Hi, > > I want to get the following setup, but don't know how (or if it's even > possible): > > * A guest VM with two AHCI controllers, with one device each. One of the AHCI > controllers provides the VM's disk ("system"), while the other provides >

[Qemu-devel] [PATCH 02/10] target-i386: remove tabs from target-i386/cpu.h

2013-08-28 Thread Gleb Natapov
From: Paolo Bonzini Signed-off-by: Paolo Bonzini --- target-i386/cpu.h | 192 ++--- 1 file changed, 96 insertions(+), 96 deletions(-) diff --git a/target-i386/cpu.h b/target-i386/cpu.h index 3a52f94..af4c0f7 100644 --- a/target-i386/cpu.h +++ b/

Re: [Qemu-devel] [RFC] Streamlining endian handling in TCG

2013-08-28 Thread Richard Henderson
On 08/28/2013 09:38 AM, Peter Maydell wrote: >> (B) Add an additional bit to the "opc" to indicate which endianness is >> desired. >> E.g. 0 = LE, 8 = BE. Expose the opc interface to the translators. At which >> point generating a load becomes more like >> >> tcg_gen_qemu_ld_tl(dest, addr,

[Qemu-devel] [PATCH 05/10] kvm: x86: fix setting IA32_FEATURE_CONTROL with nested VMX disabled

2013-08-28 Thread Gleb Natapov
From: Liu Jinsong This patch is to fix the bug https://bugs.launchpad.net/qemu-kvm/+bug/1207623 IA32_FEATURE_CONTROL is pointless if not expose VMX or SMX bits to cpuid.1.ecx of vcpu. Current qemu-kvm will error return when kvm_put_msrs or kvm_get_msrs. Signed-off-by: Liu Jinsong Signed-off-by

Re: [Qemu-devel] [PATCH v4 0/3] slirp: fill mainloop with more precise timeout value

2013-08-28 Thread Jan Kiszka
On 2013-08-25 04:01, Liu Ping Fan wrote: > With this series, we can set the mainloop timeout more precisely when slirp > has > to emulate tcp timeout problem. > > v4: > use macro TIMEOUT_DEFAULT to define the default timeout of slirp and > document it. > > v3: > fix comment: document timeou

Re: [Qemu-devel] [PATCH v2 2/2] qemu-timer: make qemu_timer_mod_ns() and qemu_timer_del() thread-safe

2013-08-28 Thread Paolo Bonzini
Il 27/08/2013 10:55, Alex Bligh ha scritto: >> + * Note that this function should not be used when other threads also access >> + * the timer list. The return value may be outdated by the time it is acted >> + * upon. >> + * > > I'm in two minds as to whether there is a problem with the comment o

[Qemu-devel] [PATCH 06/10] kvm: Simplify kvm_handle_io

2013-08-28 Thread Gleb Natapov
From: Jan Kiszka Now that cpu_in/out is just a wrapper around address_space_rw, we can also call the latter directly. As host endianness == guest endianness, there is no need for the memory access helpers st*_p/ld*_p as well. Signed-off-by: Jan Kiszka Signed-off-by: Paolo Bonzini --- kvm-all.

[Qemu-devel] [PATCH] tci: Remove function tcg_out64 (fix broken build)

2013-08-28 Thread Stefan Weil
Commit ac26eb69a311396668809eadbf7ff4e623447d4c added tcg_out64 to tcg/tcg.c. tcg/tci/tcg-target.c already had a nearly identical implementation which is now removed to fix a compiler error. Signed-off-by: Stefan Weil --- tcg/tci/tcg-target.c |7 --- 1 file changed, 7 deletions(-) diff

Re: [Qemu-devel] [RFC] Streamlining endian handling in TCG

2013-08-28 Thread Peter Maydell
On 28 August 2013 18:16, Richard Henderson wrote: > On 08/28/2013 09:38 AM, Peter Maydell wrote: >>> (B) Add an additional bit to the "opc" to indicate which endianness is >>> desired. >>> E.g. 0 = LE, 8 = BE. Expose the opc interface to the translators. At >>> which >>> point generating a lo

Re: [Qemu-devel] [PATCH 0/2] Make mixer emulation configurable at runtime

2013-08-28 Thread Jan Kiszka
On 2013-08-28 18:37, Markus Armbruster wrote: >>> 3. Why does CONFIG_MIXEMU exist? >>> >> I can post a patch for it (again) on top of these changes and >> see where it goes. If the default value of the "mixer" property stays >> off, malc's concerns mentioned elsewhere in this thread will be taken

Re: [Qemu-devel] Would virtio support 64 bit address for vring virtqueue?

2013-08-28 Thread Anthony Liguori
Yes, it was originally designed with the 16TB limit in mind. PCI doesn't support 64-bit PIO operations so it would have required a high/low register and additional magic. When/if we switch to an MMIO region, we can switch to using a proper 64-bit register for setting up queues. Regards, Anthony

Re: [Qemu-devel] [RFC] Streamlining endian handling in TCG

2013-08-28 Thread Stefan Weil
Am 28.08.2013 18:38, schrieb Peter Maydell: > On 28 August 2013 16:26, Richard Henderson wrote: > >> (D) Profit! I'm not sure what will be left of TARGET_WORDS_BIGENDIAN at this >> point. Possibly only if we leave the current translator interface in place >> in >> step A. > I think there are a

Re: [Qemu-devel] [RFC] Streamlining endian handling in TCG

2013-08-28 Thread Richard Henderson
On 08/28/2013 10:28 AM, Peter Maydell wrote: > Well, what do ldl_p or ldl_phys or any of the other functions > without an le/be qualifier mean any more if "is this CPU in > big endian mode?" now requires you to have a CPUState > to ask? I guess we can tackle that separately from getting > the assum

Re: [Qemu-devel] [PATCH v2] mips/malta: allow volatile writes to reset flash

2013-08-28 Thread Aurelien Jarno
On Wed, Aug 28, 2013 at 01:39:52PM +0100, Leon Alrae wrote: > From: James Hogan > > Commit a427338 (mips_malta: correct reading MIPS revision at 0x1fc00010) > altered the behaviour of the monitor flash mapping at the reset address > by making it read only. However this causes data bus error excep

Re: [Qemu-devel] [BUG] GTK terminal is broken

2013-08-28 Thread Stefan Weil
Am 30.07.2013 00:35, schrieb Laszlo Ersek: > On 07/29/13 20:18, Stefan Weil wrote: >> Am 29.07.2013 20:05, schrieb Anthony Liguori: >>> Stefan Weil writes: >>> Hello, maybe most developers will already have noticed that the terminal output in QEMU's GTK user interface is broken

Re: [Qemu-devel] [PATCH] tci: Remove function tcg_out64 (fix broken build)

2013-08-28 Thread Richard Henderson
On 08/28/2013 10:28 AM, Stefan Weil wrote: > Commit ac26eb69a311396668809eadbf7ff4e623447d4c added tcg_out64 to tcg/tcg.c. > tcg/tci/tcg-target.c already had a nearly identical implementation which is > now removed to fix a compiler error. > > Signed-off-by: Stefan Weil Oops, yes. Reviewed-by:

Re: [Qemu-devel] Direct guest device access from nested guest

2013-08-28 Thread Lluís Vilanova
Jan Kiszka writes: [...] >> Is it possible to give a nested guest direct access to a device on the guest? >> (more specifically, an AHCI controller). > Nope, we are lacking support for emulating or (securely) forwarding > VT-d/IOMMU features to the first level guest. Would be cool to have, > just

Re: [Qemu-devel] Direct guest device access from nested guest

2013-08-28 Thread Jan Kiszka
On 2013-08-28 20:12, Lluís Vilanova wrote: > Jan Kiszka writes: > [...] >>> Is it possible to give a nested guest direct access to a device on the >>> guest? >>> (more specifically, an AHCI controller). > >> Nope, we are lacking support for emulating or (securely) forwarding >> VT-d/IOMMU feature

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Erik Rull
Benoît Canet wrote: Can you whip up a patch to avoid that? Or to honor bps_max if it is specified (making avg/10 simply the default)? Pushed in the same branch (it honor bps_max if specified). Best regards Benoît Hi all, thanks for your help. I cloned the git and compiled it - but I'm no

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Benoît Canet
> thanks for your help. I cloned the git and compiled it - but I'm not > completely sure how to enable the throttling finally - there were > several mails regarding averages and max values... And the "unit" of > the values would be interesting. Hi Erik, The main settings are bps, bps_rd and bps_w

Re: [Qemu-devel] Problems with QEMU sdcard while using glib 2.33.8

2013-08-28 Thread Taimoor Mirza
Hi Stefan, Below is result of bt: Breakpoint 1, 0x006ac304 in abort () (gdb) bt #0 0x006ac304 in abort () #1 0x00553052 in _fu10846stack_chk_guard () at qemu-coroutine.c:111 #2 0x0040d746 in _fu473stack_chk_guard () at block.c:4294 #3 0x00413cc7 in _fu805stack_chk_guard () at bloc

Re: [Qemu-devel] Direct guest device access from nested guest

2013-08-28 Thread Lluís Vilanova
Jan Kiszka writes: > On 2013-08-28 20:12, Lluís Vilanova wrote: >> Jan Kiszka writes: >> [...] Is it possible to give a nested guest direct access to a device on the guest? (more specifically, an AHCI controller). >> >>> Nope, we are lacking support for emulating or (securely) for

Re: [Qemu-devel] Boot Problems Windows XP guest

2013-08-28 Thread Erik Rull
Benoît Canet wrote: thanks for your help. I cloned the git and compiled it - but I'm not completely sure how to enable the throttling finally - there were several mails regarding averages and max values... And the "unit" of the values would be interesting. Hi Erik, The main settings are bps, b

Re: [Qemu-devel] [RFC] Streamlining endian handling in TCG

2013-08-28 Thread Edgar E. Iglesias
On Wed, Aug 28, 2013 at 08:26:43AM -0700, Richard Henderson wrote: > On 08/28/2013 07:34 AM, Peter Maydell wrote: > > On 28 August 2013 15:31, Richard Henderson wrote: > >> On 08/28/2013 01:15 AM, Peter Maydell wrote: > >>> [*] not impossible, we already do something on the ppc > >>> that's simila

Re: [Qemu-devel] [PATCH 3/4] tcg-ppc64: Implement muluh, mulsh

2013-08-28 Thread Aurelien Jarno
On Sat, Aug 17, 2013 at 04:26:45PM -0700, Richard Henderson wrote: > Using these instead of mulu2 and muls2 lets us avoid having to argument > overlap analysis in the backend. Normal register allocation will DTRT. > > Signed-off-by: Richard Henderson > --- > tcg/ppc64/tcg-target.c | 32 +++-

Re: [Qemu-devel] [PATCH 1/4] tcg: Add muluh and mulsh opcodes

2013-08-28 Thread Aurelien Jarno
On Sat, Aug 17, 2013 at 04:26:43PM -0700, Richard Henderson wrote: > Use them in places where mulu2 and muls2 are used. > Optimize mulx2 with dead low part to mulxh. > > Signed-off-by: Richard Henderson > --- > tcg/aarch64/tcg-target.h | 4 > tcg/arm/tcg-target.h | 2 ++ > tcg/hppa/tc

Re: [Qemu-devel] [PATCH 2/4] tcg-mips: Implement mulsh, muluh

2013-08-28 Thread Aurelien Jarno
On Sat, Aug 17, 2013 at 04:26:44PM -0700, Richard Henderson wrote: > With the optimization in tcg_liveness_analysis, > we can avoid the MFLO when it is unused. > > Signed-off-by: Richard Henderson > --- > tcg/mips/tcg-target.c | 10 ++ > tcg/mips/tcg-target.h | 4 ++-- > 2 files changed

Re: [Qemu-devel] [PATCH 4/4] tcg: Constant fold div, rem

2013-08-28 Thread Aurelien Jarno
On Sat, Aug 17, 2013 at 04:26:46PM -0700, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > tcg/optimize.c | 23 +++ > 1 file changed, 23 insertions(+) > > diff --git a/tcg/optimize.c b/tcg/optimize.c > index e8dedf3..b29bf25 100644 > --- a/tcg/optimize.c >

<    1   2   3   >