~ubuntu-virt/qemu/+git/qemu-lp-import:stable-2.9

Last commit made on 2017-09-07
Get this branch:
git clone -b stable-2.9 https://git.launchpad.net/~ubuntu-virt/qemu/+git/qemu-lp-import

Branch merges

Branch information

Name:
stable-2.9
Repository:
lp:~ubuntu-virt/qemu/+git/qemu-lp-import

Recent commits

4cd4265... by Michael Roth

Update version for 2.9.1 release

Signed-off-by: Michael Roth <email address hidden>

c24c591... by Greg Kurz

virtfs: error out gracefully when mandatory suboptions are missing

We internally convert -virtfs to -fsdev/-device. If the user doesn't
provide the path or security_model suboptions, and the fsdev backend
requires them, we hit an assertion when populating the internal -fsdev
option:

util/qemu-option.c:547: opt_set: Assertion `opt->str' failed.
Aborted (core dumped)

Let's test the suboption presence on the command line before trying
to set it in the internal -fsdev option, and let the backend code
error out gracefully (ie, like it already does when the user passes
-fsdev on the command line).

Reported-by: Thomas Huth <email address hidden>
Signed-off-by: Greg Kurz <email address hidden>
Reviewed-by: Thomas Huth <email address hidden>
(cherry picked from commit 32b6943699948f7adc35ada233fbd25daffad5e9)
Signed-off-by: Michael Roth <email address hidden>

2d1bbf5... by Richard Henderson

target/arm: Fix aa64 ldp register writeback

For "ldp x0, x1, [x0]", if the second load is on a second page and
the second page is unmapped, the exception would be raised with x0
already modified. This means the instruction couldn't be restarted.

Cc: <email address hidden>
Cc: <email address hidden>
Reported-by: Andrew <email address hidden>
Signed-off-by: Richard Henderson <email address hidden>
Message-id: <email address hidden>
Fixes: https://bugs.launchpad.net/qemu/+bug/1713066
Signed-off-by: Richard Henderson <email address hidden>
[PMM: tweaked comment format]
Reviewed-by: Peter Maydell <email address hidden>
Signed-off-by: Peter Maydell <email address hidden>

(cherry picked from commit 3e4d91b94ce400326fae0850578d9e9f30a71adb)
Signed-off-by: Michael Roth <email address hidden>

30b76b2... by Anthony PERARD

exec: Add lock parameter to qemu_ram_ptr_length

Commit 04bf2526ce87f21b32c9acba1c5518708c243ad0 (exec: use
qemu_ram_ptr_length to access guest ram) start using qemu_ram_ptr_length
instead of qemu_map_ram_ptr, but when used with Xen, the behavior of
both function is different. They both call xen_map_cache, but one with
"lock", meaning the mapping of guest memory is never released
implicitly, and the second one without, which means, mapping can be
release later, when needed.

In the context of address_space_{read,write}_continue, the ptr to those
mapping should not be locked because it is used immediatly and never
used again.

The lock parameter make it explicit in which context qemu_ram_ptr_length
is called.

Signed-off-by: Anthony PERARD <email address hidden>
Message-Id: <email address hidden>
Reviewed-by: Stefano Stabellini <email address hidden>
Signed-off-by: Paolo Bonzini <email address hidden>
(cherry picked from commit f5aa69bdc3418773f26747ca282c291519626ece)
Signed-off-by: Michael Roth <email address hidden>

2f64063... by Stefano Stabellini <email address hidden>

xen/mapcache: store dma information in revmapcache entries for debugging

The Xen mapcache is able to create long term mappings, they are called
"locked" mappings. The third parameter of the xen_map_cache call
specifies if a mapping is a "locked" mapping.

>From the QEMU point of view there are two kinds of long term mappings:

[a] device memory mappings, such as option roms and video memory
[b] dma mappings, created by dma_memory_map & friends

After certain operations, ballooning a VM in particular, Xen asks QEMU
kindly to destroy all mappings. However, certainly [a] mappings are
present and cannot be removed. That's not a problem as they are not
affected by balloonning. The *real* problem is that if there are any
mappings of type [b], any outstanding dma operations could fail. This is
a known shortcoming. In other words, when Xen asks QEMU to destroy all
mappings, it is an error if any [b] mappings exist.

However today we have no way of distinguishing [a] from [b]. Because of
that, we cannot even print a decent warning.

This patch introduces a new "dma" bool field to MapCacheRev entires, to
remember if a given mapping is for dma or is a long term device memory
mapping. When xen_invalidate_map_cache is called, we print a warning if
any [b] mappings exist. We ignore [a] mappings.

Mappings created by qemu_map_ram_ptr are assumed to be [a], while
mappings created by address_space_map->qemu_ram_ptr_length are assumed
to be [b].

The goal of the patch is to make debugging and system understanding
easier.

Signed-off-by: Stefano Stabellini <email address hidden>
Acked-by: Paolo Bonzini <email address hidden>
Acked-by: Anthony PERARD <email address hidden>
(cherry picked from commit 1ff7c5986a515d2d936eba026ff19947bbc7cb92)
Signed-off-by: Michael Roth <email address hidden>

15d8f91... by P J P

exec: use qemu_ram_ptr_length to access guest ram

When accessing guest's ram block during DMA operation, use
'qemu_ram_ptr_length' to get ram block pointer. It ensures
that DMA operation of given length is possible; And avoids
any OOB memory access situations.

Reported-by: Alex <email address hidden>
Signed-off-by: Prasad J Pandit <email address hidden>
Message-Id: <email address hidden>
Signed-off-by: Paolo Bonzini <email address hidden>
(cherry picked from commit 04bf2526ce87f21b32c9acba1c5518708c243ad0)
Signed-off-by: Michael Roth <email address hidden>

f9c313f... by Gerd Hoffmann

xhci: only update dequeue ptr on completed transfers

The dequeue pointer should only be updated in case the transfer
is actually completed. If we update it for inflight transfers
we will not pick them up again after migration, which easily
triggers with HID devices as they typically have a pending
transfer, waiting for user input to happen.

Fixes: 243afe858b95765b98d16a1f0dd50dca262858ad
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1451631
Signed-off-by: Gerd Hoffmann <email address hidden>
Tested-by: Laurent Vivier <email address hidden>
Message-id: <email address hidden>
(cherry picked from commit d54fddea989ba4aa2912d49583d86ce01c0d27ea)
Signed-off-by: Michael Roth <email address hidden>

5320675... by Dr. David Alan Gilbert

vl.c/exit: pause cpus before closing block devices

There's a rare exit seg if the guest is accessing
IO during exit.
It's always hitting the atomic_inc(&bs->in_flight) with a NULL
bs. This was added recently in 99723548 but I don't see it
as the cause.

Flip vl.c around so we pause the cpus before closing the block devices,
that way we shouldn't have anything trying to access them when
they're gone.

This was originally Red Hat bz https://bugzilla.redhat.com/show_bug.cgi?id=1451015

Signed-off-by: Dr. David Alan Gilbert <email address hidden>
Reported-by: Cong Li <email address hidden>

--
This is a very rare race, I'll leave it running in a loop to see if
we hit anything else and to check this really fixes it.

I do worry if there are other cases that can trigger this - e.g.
hot-unplug or ejecting a CD.

Message-Id: <email address hidden>
Signed-off-by: Paolo Bonzini <email address hidden>
(cherry picked from commit 452589b6b47e8dc6353df257fc803dfc1383bed8)
Signed-off-by: Michael Roth <email address hidden>

167e764... by Michael Roth

PPC: E500: update u-boot to match shipped binary

Previous submodule commit contained some unused files with comments
that made redistribution requirements unclear, and the submodule commit
should really match the blob we're shipped anyway.

Suggested-by: Peter Maydell <email address hidden>
Signed-off-by: Michael Roth <email address hidden>

e22e199... by Farhan Ali <email address hidden>

s390-ccw: Fix alignment for CCW1

The commit 198c0d1f9df8c4 s390x/css: check ccw address validity
exposes an alignment issue in ccw bios.

According to PoP the CCW must be doubleword aligned. Let's fix
this in the bios.

Cc: <email address hidden>
Signed-off-by: Farhan Ali <email address hidden>
Reviewed-by: Halil Pasic <email address hidden>
Reviewed-by: Eric Farman <email address hidden>
Acked-by: Christian Borntraeger <email address hidden>
Message-Id: <email address hidden>
Signed-off-by: Cornelia Huck <email address hidden>
(cherry picked from commit 3a1e4561ad63b303b092387ae006bd41468ece63)
Signed-off-by: Michael Roth <email address hidden>