[Qemu-devel] [PATCH v3] rcu tests: fix compilation on 32-bit ppc

2015-03-22 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] [PATCH] qemu-m68k: add support for interrupt masking/unmasking

2015-03-22 Thread Waldemar Brodkorb
Fixes following problem, when trying to boot linux: qemu: hardware error: mcf_intc_write: Bad write offset 28 CPU #0: D0 = 00ff A0 = 402ea5dc F0 = ( 0) D1 = 0004 A1 = 402ea5e0 F1 = ( 0) D2 = 0040 A2 = 40040752 F2 = 0

Re: [Qemu-devel] [PATCH] qemu-m68k: add support for interrupt masking/unmasking

2015-03-22 Thread Stefan Weil
Technically this implementation looks reasonable. I added some remarks below. Am 22.03.2015 um 10:09 schrieb Waldemar Brodkorb: Fixes following problem, when trying to boot linux: qemu: hardware error: mcf_intc_write: Bad write offset 28 CPU #0: D0 = 00ff A0 = 402ea5dc F0 = 000

Re: [Qemu-devel] [PATCH] qemu-m68k: add support for interrupt masking/unmasking

2015-03-22 Thread Peter Maydell
On 22 March 2015 at 09:09, Waldemar Brodkorb wrote: > Fixes following problem, when trying to boot linux: > qemu: hardware error: mcf_intc_write: Bad write offset 28 > > CPU #0: > D0 = 00ff A0 = 402ea5dc F0 = ( 0) > D1 = 0004 A1 = 402ea5e0 F1 = 00

Re: [Qemu-devel] [PATCH] qemu-m68k: add support for interrupt masking/unmasking

2015-03-22 Thread Peter Maydell
On 22 March 2015 at 09:49, Stefan Weil wrote: > Am 22.03.2015 um 10:09 schrieb Waldemar Brodkorb: >> >> +case 0x1c: > > > Add /* SIMR */ comment behind case statement like it was done for SWIACK. > Then either add a /* fall through */ comment or a return 0 (to satisfy > static > code analyzers

[Qemu-devel] Support for NetLogic XLP Processors

2015-03-22 Thread Duarte Silva
Hi guys, I have been struggling to get some binaries compiled for NetLogic XLP processor to run under QEMU. I have tried a bunch of things (most going back and forth) and always get the following error message: qemu: uncaught target signal 4 (Illegal instruction) - core dumped Illegal instructi

Re: [Qemu-devel] GSoC Proposal: ARM Virtualization Extensions

2015-03-22 Thread Sergey Fedorov
On 20.03.2015 21:49, Edgar E. Iglesias wrote: > Hi all, > > Sergey, that's good to hear! > > Peter, Yes I have quite a bit of patch material but unfortunately a lot of > it is not in a state for upstreaming. I know I've promised to clean > it up and submit more but I have not been able to find time

Re: [Qemu-devel] [PATCH 2/2] i6300esb: Fix signed integer overflow

2015-03-22 Thread David Gibson
On Fri, Mar 20, 2015 at 10:13:26AM +0100, Paolo Bonzini wrote: > > > On 20/03/2015 04:11, David Gibson wrote: > > 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 0x

Re: [Qemu-devel] [PATCH v6 07/15] spapr_rtas: add ibm, configure-connector RTAS interface

2015-03-22 Thread David Gibson
On Mon, Mar 16, 2015 at 10:31:29PM -0500, Michael Roth wrote: > Quoting David Gibson (2015-03-12 00:52:10) > > On Thu, Mar 05, 2015 at 08:12:58AM -0600, Michael Roth wrote: > > > Quoting David Gibson (2015-03-04 22:30:40) > > > > On Wed, Mar 04, 2015 at 07:37:08AM -0600, Michael Roth wrote: > > > >

[Qemu-devel] [v3][PATCH 0/2] libxl: try to support IGD passthrough for qemu upstream

2015-03-22 Thread Tiejun Chen
v3: * Refine some codes based on Campbell's feedback so thanks for Campbell's kind guideline to patch #2 * Update the manpages in patch #2 v2: * Refine patch #2's head description * Improve codes quality inside patch #1 based on Wei's comments * Refill the summary inside patch #0 based on Kon

[Qemu-devel] [v3][PATCH 1/2] libxl: introduce libxl__is_igd_vga_passthru

2015-03-22 Thread Tiejun Chen
While working with qemu, IGD is a specific device in the case of pass through so we need to identify that to handle more later. Here we define a table to record all IGD types currently we can support. Also we need to introduce two helper functions to get vendor and device ids to lookup that table.

[Qemu-devel] [v3][PATCH 2/2] libxl: introduce gfx_passthru_kind

2015-03-22 Thread Tiejun Chen
Although we already have 'gfx_passthru' in b_info, this doesn' suffice after we want to handle IGD specifically. Now we define a new field of type, gfx_passthru_kind, to indicate we're trying to pass IGD. Actually this means we can benefit this to support other specific devices just by extending gf

[Qemu-devel] [Bug 1435101] [NEW] Windows, QEMU 2.2.50 fails to boot XP CD

2015-03-22 Thread simon
Public bug reported: Running XP Pro SP3 host 32bit. When I launch qemu booting from CD, it fails to complete load, getting stuck at "Setup is starting Windows". It does not proceed past. I tried to disable floppy but still no go. Download older version 1.5.1-win32, 0.9.1, same problem. qemu-s

Re: [Qemu-devel] [PATCH v4 5/5] Qemu-Xen-vTPM: QEMU machine class is initialized before tpm_init()

2015-03-22 Thread Xu, Quan
> -Original Message- > From: Stefan Berger [mailto:stef...@linux.vnet.ibm.com] > Sent: Friday, March 20, 2015 7:26 PM > To: Xu, Quan; stefano.stabell...@eu.citrix.com; qemu-devel@nongnu.org; > arm...@redhat.com; lcapitul...@redhat.com; aligu...@amazon.com; > pbonz...@redhat.com; ebl...@re

Re: [Qemu-devel] [Xen-devel] [PATCH] SeaBios/vTPM: Enable Xen stubdom vTPM for HVM virtual machine

2015-03-22 Thread Xu, Quan
> -Original Message- > From: Stefan Berger [mailto:stef...@linux.vnet.ibm.com] > Sent: Friday, March 20, 2015 7:44 PM > To: Ian Campbell; Xu, Quan > Cc: ke...@koconnor.net; xen-de...@lists.xen.org; qemu-devel@nongnu.org; > stefano.stabell...@eu.citrix.com > Subject: Re: [Xen-devel] [PATCH

[Qemu-devel] [PATCH v2 0/2] Fix bugs in i6300esb watchdog timer

2015-03-22 Thread David Gibson
This series fixes two bugs in the i6300esb watchdog timer device. The first only affects big-endian targets (including targets like ppc which support both endians, but are considered big-endian by default). The second affects all targets, but only when the guest uses unusually large timeout values

[Qemu-devel] [PATCH v2 1/2] i6300esb: Correct endiannness

2015-03-22 Thread 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 driver exists on the

[Qemu-devel] [PATCH v2 2/2] i6300esb: Fix signed integer overflow

2015-03-22 Thread 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) / 3300; get_ticks

Re: [Qemu-devel] [PATCH v5 20/45] Modify savevm handlers for postcopy

2015-03-22 Thread David Gibson
On Fri, Mar 20, 2015 at 12:37:59PM +, Dr. David Alan Gilbert wrote: > * David Gibson (da...@gibson.dropbear.id.au) wrote: > > On Fri, Mar 13, 2015 at 10:19:54AM +, Dr. David Alan Gilbert wrote: > > > * David Gibson (da...@gibson.dropbear.id.au) wrote: > > > > On Wed, Feb 25, 2015 at 04:51:4

Re: [Qemu-devel] [PATCH v5 23/45] migrate_start_postcopy: Command to trigger transition to postcopy

2015-03-22 Thread David Gibson
On Thu, Mar 19, 2015 at 09:33:31AM +, Dr. David Alan Gilbert wrote: > * David Gibson (da...@gibson.dropbear.id.au) wrote: > > On Wed, Mar 18, 2015 at 05:59:51PM +, Dr. David Alan Gilbert wrote: > > > * David Gibson (da...@gibson.dropbear.id.au) wrote: > > > > On Fri, Mar 13, 2015 at 11:19:0

Re: [Qemu-devel] [PATCH v5 12/45] Return path: Source handling of return path

2015-03-22 Thread David Gibson
On Fri, Mar 20, 2015 at 06:17:31PM +, Dr. David Alan Gilbert wrote: > * David Gibson (da...@gibson.dropbear.id.au) wrote: > > On Wed, Feb 25, 2015 at 04:51:35PM +, Dr. David Alan Gilbert (git) > > wrote: > > > From: "Dr. David Alan Gilbert" > > > > > > Open a return path, and handle mess

Re: [Qemu-devel] [PATCH v5 26/45] Postcopy page-map-incoming (PMI) structure

2015-03-22 Thread David Gibson
On Wed, Mar 18, 2015 at 05:58:40PM +, Dr. David Alan Gilbert wrote: > * David Gibson (da...@gibson.dropbear.id.au) wrote: > > On Fri, Mar 13, 2015 at 01:47:53PM +, Dr. David Alan Gilbert wrote: > > > * David Gibson (da...@gibson.dropbear.id.au) wrote: > > > > On Wed, Feb 25, 2015 at 04:51:4

Re: [Qemu-devel] [PATCH v5 27/45] Postcopy: Maintain sentmap and calculate discard

2015-03-22 Thread David Gibson
On Wed, Feb 25, 2015 at 04:51:50PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Where postcopy is preceeded by a period of precopy, the destination will > have received pages that may have been dirtied on the source after the > page was sent. The destination mu

Re: [Qemu-devel] [PATCH v5 28/45] postcopy: Incoming initialisation

2015-03-22 Thread David Gibson
On Wed, Feb 25, 2015 at 04:51:51PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Signed-off-by: Dr. David Alan Gilbert Reviewed-by: David Gibson Looks ok, apart from a misspelled comment: [snip] > +/* > + * We need the whole of RAM to be truly empty

Re: [Qemu-devel] [PATCH v5 29/45] postcopy: ram_enable_notify to switch on userfault

2015-03-22 Thread David Gibson
On Wed, Feb 25, 2015 at 04:51:52PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Mark the area of RAM as 'userfault' > Start up a fault-thread to handle any userfaults we might receive > from it (to be filled in later) > > Signed-off-by: Dr. David Alan Gilbert

Re: [Qemu-devel] [PATCH v5 30/45] Postcopy: Postcopy startup in migration thread

2015-03-22 Thread David Gibson
On Wed, Feb 25, 2015 at 04:51:53PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Rework the migration thread to setup and start postcopy. > > Signed-off-by: Dr. David Alan Gilbert > --- > include/migration/migration.h | 3 + > migration/migration.c |

Re: [Qemu-devel] [PATCH v5 44/45] Disable mlock around incoming postcopy

2015-03-22 Thread David Gibson
On Wed, Feb 25, 2015 at 04:52:07PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Userfault doesn't work with mlock; mlock is designed to nail down pages > so they don't move, userfault is designed to tell you when they're not > there. > > munlock the pages we us

Re: [Qemu-devel] [PATCH v5 45/45] Inhibit ballooning during postcopy

2015-03-22 Thread David Gibson
On Wed, Feb 25, 2015 at 04:52:08PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > The userfault mechanism used for postcopy generates faults > for us on pages that are 'not present', inflating a balloon in > the guest causes host pages to be marked as 'not present

[Qemu-devel] [PATCH 0/2] block: Fix unaligned zero write

2015-03-22 Thread Fam Zheng
This fixes a segfault when doing unaligned zero write to a image that is 4k aligned. Reproducer: $ (echo "open -o file.align=4k blkdebug::img"; echo "write -z 512 1024") | qemu-io Fam Zheng (2): block: Fix unaligned zero write qemu-iotests: Test unaligned 4k zero write block.c

[Qemu-devel] [PATCH 2/2] qemu-iotests: Test unaligned 4k zero write

2015-03-22 Thread Fam Zheng
Signed-off-by: Fam Zheng --- tests/qemu-iotests/033 | 47 +- tests/qemu-iotests/033.out | 26 + 2 files changed, 56 insertions(+), 17 deletions(-) diff --git a/tests/qemu-iotests/033 b/tests/qemu-iotests/033 index ea3351c..4

[Qemu-devel] [PATCH 1/2] block: Fix unaligned zero write

2015-03-22 Thread Fam Zheng
If the zero write is not aligned, bdrv_co_do_pwritev will segfault because of accessing to the NULL qiov passed in by bdrv_co_write_zeroes. Fix this by allocating a local qiov in bdrv_co_do_pwritev if the request is not aligned. (In this case the padding iovs are necessary anyway, so it doesn't hur

Re: [Qemu-devel] [PATCH v5 32/45] Page request: Add MIG_RP_CMD_REQ_PAGES reverse command

2015-03-22 Thread David Gibson
On Wed, Feb 25, 2015 at 04:51:55PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Add MIG_RP_CMD_REQ_PAGES command on Return path for the postcopy > destination to request a page from the source. > > Signed-off-by: Dr. David Alan Gilbert > --- > include/migrati

Re: [Qemu-devel] [Qemu-ppc] [PATCH v2 1/3] VFIO: Clear stale MSIx table during EEH reset

2015-03-22 Thread David Gibson
On Fri, Mar 20, 2015 at 05:27:29PM +1100, Gavin Shan wrote: > On Fri, Mar 20, 2015 at 05:04:01PM +1100, David Gibson wrote: > >On Tue, Mar 17, 2015 at 03:31:24AM +1100, Gavin Shan wrote: > >> The PCI device MSIx table is cleaned out in hardware after EEH PE > >> reset. However, we still hold the st

Re: [Qemu-devel] [PATCH v2 1/3] VFIO: Clear stale MSIx table during EEH reset

2015-03-22 Thread Gavin Shan
On Wed, Mar 18, 2015 at 10:26:33AM +1100, Gavin Shan wrote: >On Tue, Mar 17, 2015 at 03:09:52PM -0600, Alex Williamson wrote: >>On Tue, 2015-03-17 at 03:31 +1100, Gavin Shan wrote: >>> The PCI device MSIx table is cleaned out in hardware after EEH PE >>> reset. However, we still hold the stale MSIx

[Qemu-devel] [PATCH v2] block: Switch to host monotonic clock for IO throttling

2015-03-22 Thread Fam Zheng
Currently, throttle timers won't make any progress when VCPU is not running, which would stall the request queue in utils, qtest, vm suspending, and live migration without special handling. For example in bdrv_drain_all, all requests are resumed immediately without taking throttling limit into acc

Re: [Qemu-devel] [Qemu-ppc] [PATCH v2 1/3] VFIO: Clear stale MSIx table during EEH reset

2015-03-22 Thread Gavin Shan
On Mon, Mar 23, 2015 at 04:06:56PM +1100, David Gibson wrote: >On Fri, Mar 20, 2015 at 05:27:29PM +1100, Gavin Shan wrote: >> On Fri, Mar 20, 2015 at 05:04:01PM +1100, David Gibson wrote: >> >On Tue, Mar 17, 2015 at 03:31:24AM +1100, Gavin Shan wrote: >> >> The PCI device MSIx table is cleaned out

Re: [Qemu-devel] [PATCH v3] rcu tests: fix compilation on 32-bit ppc

2015-03-22 Thread Fam Zheng
On Sun, 03/22 09:26, Paolo Bonzini wrote: > 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 th

[Qemu-devel] [PATCH v2 2/2] icc_bus: remove icc related files

2015-03-22 Thread Chen Fan
ICC bus impl has been droped, so all icc related files are not useful any more; delete them. Signed-off-by: Chen Fan --- default-configs/i386-softmmu.mak | 1 - default-configs/x86_64-softmmu.mak | 1 - hw/cpu/Makefile.objs | 2 - hw/cpu/icc_bus.c | 118 --

[Qemu-devel] [PATCH v2 1/2] cpu/apic: drop icc bus/bridge/

2015-03-22 Thread Chen Fan
ICC bus was invented only to provide hotplug capability to CPU and APIC because at the time being hotplug was available only for BUS attached devices. Now this patch is to drop ICC bus impl, and switch to bus-less CPU+APIC hotplug, handling them in the same manner as pc-dimm. Signed-off-by: Chen

[Qemu-devel] [PATCH v2 0/2] remove icc bus/bridge

2015-03-22 Thread Chen Fan
ICC Bus was used for providing a hotpluggable bus for APIC and CPU, but new we use HotplugHandler to make hotplug. so ICC Bus is unnecessary. this codes has passed the new pc-cpu-test. Chen Fan (2): cpu/apic: drop icc bus/bridge/ icc_bus: remove icc related files default-configs/i386-softmm

[Qemu-devel] [Bug 1186984] Re: large -initrd can wrap around in memory causing memory corruption

2015-03-22 Thread Bart Van Assche
Just saw something similar with qemu 2.2.1: KVM: injection failed, MSI lost (Input/output error) qemu-system-x86_64: /home/bart/software/qemu-2.2.1/hw/net/vhost_net.c:264: vhost_net_stop_one: Assertion `r >= 0' failed. 2015-03-23 02:44:44.952+: shutting down -- You received this bug notific