Re: [Qemu-devel] [PATCH] linux-user: ppc64: use the correct values for F_*LK64s

2018-07-12 Thread Shivaprasad G Bhat
On 07/12/2018 12:36 PM, Laurent Vivier wrote: Le 12/07/2018 à 09:00, Shivaprasad G Bhat a écrit : On 07/12/2018 02:21 AM, Laurent Vivier wrote: Le 11/07/2018 à 15:04, Laurent Vivier a écrit : Le 11/07/2018 à 12:55, Shivaprasad G Bhat a écrit : Qemu includes the glibc headers for the host

[Qemu-devel] [PATCH v2] linux-user: ppc64: use the correct values for F_*LK64s

2018-07-12 Thread Shivaprasad G Bhat
Qemu includes the glibc headers for the host defines and target headers are part of the qemu source themselves. The glibc has the F_GETLK64, F_SETLK64 and F_SETLKW64 defined to 12, 13 and 14 for all archs in sysdeps/unix/sysv/linux/bits/fcntl-linux.h. The linux kernel generic definition for F_*LK

Re: [Qemu-devel] [PATCH v0 0/7] Background snapshots

2018-07-12 Thread Peter Xu
On Fri, Jun 29, 2018 at 11:03:13AM +0300, Denis Plotnikov wrote: > The patch set adds the ability to make external snapshots while VM is running. > > The workflow to make a snapshot is the following: > 1. Pause the vm > 2. Make a snapshot of block devices using the scheme of your choice > 3. Turn

Re: [Qemu-devel] [virtio-dev] Re: [PATCH v3 0/3] Use of unique identifier for pairing virtio and passthrough devices...

2018-07-12 Thread Michael S. Tsirkin
On Thu, Jul 12, 2018 at 09:20:41PM -0400, Samudrala, Sridhar wrote: > On 7/12/2018 6:19 PM, Siwei Liu wrote: > > On Thu, Jul 12, 2018 at 2:00 PM, Michael S. Tsirkin wrote: > > > On Thu, Jul 12, 2018 at 01:52:53PM -0700, Siwei Liu wrote: > > > > The definition is incomplete due to lack of spec.

Re: [Qemu-devel] [PATCH 15/20] tests: New helper qtest_qmp_receive_success()

2018-07-12 Thread Stefan Berger
On 07/12/2018 07:12 AM, Markus Armbruster wrote: Commit b21373d0713 copied wait_command() from tests/migration-test.c to tests/tpm-util.c. Replace both copies by new libqtest helper qtest_qmp_receive_success(). Also use it to simplify qtest_qmp_device_del(). Bonus: gets rid of a non-literal

Re: [Qemu-devel] [virtio-dev] Re: [PATCH v3 0/3] Use of unique identifier for pairing virtio and passthrough devices...

2018-07-12 Thread Samudrala, Sridhar
On 7/12/2018 6:19 PM, Siwei Liu wrote: On Thu, Jul 12, 2018 at 2:00 PM, Michael S. Tsirkin wrote: On Thu, Jul 12, 2018 at 01:52:53PM -0700, Siwei Liu wrote: The definition is incomplete due to lack of spec. There's no "host" part defined yet in the host-guest interface. If match by MAC is an

Re: [Qemu-devel] [PATCH 1/1] etsec: fix IRQ (un)masking

2018-07-12 Thread David Gibson
On Thu, Jul 12, 2018 at 02:00:52PM -0700, Michael Davidsaver wrote: > Interrupt conditions occurring while masked are not being > signaled when later unmasked. > The fix is to raise/lower IRQs when IMASK is changed. > > To avoid problems like this in future, consolidate > IRQ pin update logic in

Re: [Qemu-devel] [PATCH] ppc/xics: fix ICP reset path

2018-07-12 Thread David Gibson
On Thu, Jul 12, 2018 at 12:01:49PM +0200, Greg Kurz wrote: > Recent cleanup in commit a028dd423ee6 dropped the ICPStateClass::reset > handler. It is now up to child ICP classes to call the DeviceClass::reset > handler of the parent class, thanks to device_class_set_parent_reset(). > This is a

Re: [Qemu-devel] [virtio-dev] Re: [PATCH v3 0/3] Use of unique identifier for pairing virtio and passthrough devices...

2018-07-12 Thread Siwei Liu
On Thu, Jul 12, 2018 at 2:00 PM, Michael S. Tsirkin wrote: > On Thu, Jul 12, 2018 at 01:52:53PM -0700, Siwei Liu wrote: >> The definition is incomplete due to lack of spec. There's no "host" >> part defined yet in the host-guest interface. If match by MAC is an >> interface, the same must be done

[Qemu-devel] qemu-iotests RC0+ status

2018-07-12 Thread John Snow
Hi, on Fedora 28 x64 host, as of 68f1b569 I'm seeing: `./check -v -qcow` - occasional stall on 052 - stalls on 216 `./check -v -qed` - stalls on 200 `./check -v -luks` - failures on 226. 052 is something I can't reproduce. The test takes quite a while, so maybe

[Qemu-devel] [PATCH] iotests: remove LUKS support from test 226

2018-07-12 Thread John Snow
This test doesn't actually care about the format anyway, it just supports "all formats" as a convenience. LUKS however does not use a simple image filename which confuses this iotest. We can simply remove the LUKS "support" and be happier for it. Signed-off-by: John Snow ---

Re: [Qemu-devel] [PATCH v3 0/3] Use of unique identifier for pairing virtio and passthrough devices...

2018-07-12 Thread Michael S. Tsirkin
On Tue, Jul 10, 2018 at 09:28:57AM -0500, Venu Busireddy wrote: > On 2018-07-10 05:11:18 +0300, Michael S. Tsirkin wrote: > > On Fri, Jun 29, 2018 at 05:19:03PM -0500, Venu Busireddy wrote: > > > The current patch set includes all the feedback received for proposals [3] > > > and [4]. For the sake

[Qemu-devel] [PATCH 1/1] etsec: fix IRQ (un)masking

2018-07-12 Thread Michael Davidsaver
Interrupt conditions occurring while masked are not being signaled when later unmasked. The fix is to raise/lower IRQs when IMASK is changed. To avoid problems like this in future, consolidate IRQ pin update logic in one function. Also fix probable typo "IEVENT_TXF | IEVENT_TXF", and update IRQ

Re: [Qemu-devel] [virtio-dev] Re: [PATCH v3 0/3] Use of unique identifier for pairing virtio and passthrough devices...

2018-07-12 Thread Michael S. Tsirkin
On Thu, Jul 12, 2018 at 01:52:53PM -0700, Siwei Liu wrote: > The definition is incomplete due to lack of spec. There's no "host" > part defined yet in the host-guest interface. If match by MAC is an > interface, the same must be done on the host(device) side as well, > which has been agreed not

Re: [Qemu-devel] [virtio-dev] Re: [PATCH v3 0/3] Use of unique identifier for pairing virtio and passthrough devices...

2018-07-12 Thread Siwei Liu
_ On Thu, Jul 12, 2018 at 4:31 AM, Cornelia Huck wrote: > On Thu, 12 Jul 2018 02:37:03 -0700 > Siwei Liu wrote: > >> On Wed, Jul 11, 2018 at 2:53 AM, Cornelia Huck wrote: >> > On Tue, 10 Jul 2018 17:07:37 -0700 >> > Siwei Liu wrote: >> > >> >> On Mon, Jul 9, 2018 at 6:54 PM, Michael S.

Re: [Qemu-devel] [PATCH] block: Fix typos in comments (found by codespell)

2018-07-12 Thread Jeff Cody
On Thu, Jul 12, 2018 at 09:51:20PM +0200, Stefan Weil wrote: > Signed-off-by: Stefan Weil > --- > block.c | 2 +- > block/backup.c | 4 ++-- > block/curl.c| 2 +- > block/gluster.c | 2 +- > block/vhdx.c| 2 +- > 5 files changed, 6 insertions(+), 6 deletions(-) > > diff --git

Re: [Qemu-devel] [Qemu-block] [PATCH] block: Fix typos in comments (found by codespell)

2018-07-12 Thread John Snow
On 07/12/2018 03:51 PM, Stefan Weil wrote: > Signed-off-by: Stefan Weil > --- > block.c | 2 +- > block/backup.c | 4 ++-- > block/curl.c| 2 +- > block/gluster.c | 2 +- > block/vhdx.c| 2 +- > 5 files changed, 6 insertions(+), 6 deletions(-) > > diff --git a/block.c

[Qemu-devel] [Bug 1779955] Re: qemu linux-user requires read permissions on memory passed to syscalls that should only need write access

2018-07-12 Thread Peter Maydell
Oh, yes, I see -- it's mmapping the file specifically in order to write the data to the file system. Yes, I agree that's a reasonable thing to do. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU.

Re: [Qemu-devel] [PATCH] docs: Fix some typos (most found by codespell)

2018-07-12 Thread Peter Maydell
On 12 July 2018 at 21:01, Stefan Weil wrote: > Signed-off-by: Stefan Weil > --- > docs/COLO-FT.txt | 2 +- > docs/config/mach-virt-graphical.cfg | 2 +- > docs/config/mach-virt-serial.cfg | 2 +- > docs/config/q35-emulated.cfg | 2 +- >

Re: [Qemu-devel] [PATCH 0/6] fix persistent bitmaps migration logic

2018-07-12 Thread John Snow
On 07/12/2018 03:00 PM, Vladimir Sementsov-Ogievskiy wrote: > Hi, what about this? > I'll be on vacation next two weeks. > Best regards, Vladimir. By the end of today. If there are fixes necessary I will take over the series if necessary so you can enjoy your vacation, if that's OK with you?

[Qemu-devel] [PATCH] accel: Fix typo and grammar in comment

2018-07-12 Thread Stefan Weil
The typo was found by codespell. Signed-off-by: Stefan Weil --- accel/tcg/translate-all.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/accel/tcg/translate-all.c b/accel/tcg/translate-all.c index 49d77fad44..1571987113 100644 --- a/accel/tcg/translate-all.c +++

[Qemu-devel] [PATCH] block: Fix typos in comments (found by codespell)

2018-07-12 Thread Stefan Weil
Signed-off-by: Stefan Weil --- block.c | 2 +- block/backup.c | 4 ++-- block/curl.c| 2 +- block/gluster.c | 2 +- block/vhdx.c| 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/block.c b/block.c index a2fe05ea96..39f373e035 100644 --- a/block.c +++

[Qemu-devel] [PATCH] docs: Fix some typos (most found by codespell)

2018-07-12 Thread Stefan Weil
Signed-off-by: Stefan Weil --- docs/COLO-FT.txt | 2 +- docs/config/mach-virt-graphical.cfg | 2 +- docs/config/mach-virt-serial.cfg | 2 +- docs/config/q35-emulated.cfg | 2 +- docs/config/q35-virtio-graphical.cfg | 2 +- docs/config/q35-virtio-serial.cfg| 2

[Qemu-devel] [Bug 1781463] Re: qemu don't start *.abs firmware files

2018-07-12 Thread David Martins
** Changed in: qemu Assignee: (unassigned) => David Martins (screamfox) ** Tags added: qemu ** Tags added: firmware ** Tags added: abs amiko emulation receiver ** Tags added: satelitereceiver stb -- You received this bug notification because you are a member of qemu- devel-ml, which is

[Qemu-devel] [RFC 2/3] qdev: Document ownership rules of qbus_create*()

2018-07-12 Thread Eduardo Habkost
The ownership rules of those functions aren't trivial: the caller owns the new object if parent is NULL, otherwise ownership is transferred to the parent. Clarify that on comments. Signed-off-by: Eduardo Habkost --- include/hw/qdev-core.h | 24 hw/core/bus.c |

[Qemu-devel] [RFC 3/3] pci: Document ownership rules of pci_root_bus_new*()

2018-07-12 Thread Eduardo Habkost
The ownership rules of pci_root_bus_new*() aren't trivial: the caller owns the new object if parent is NULL, otherwise ownership is transferred to the parent. Clarify that on comments. Signed-off-by: Eduardo Habkost --- include/hw/pci/pci.h | 15 +++ 1 file changed, 15

[Qemu-devel] [RFC 1/3] qom: Document reference count ownership rules

2018-07-12 Thread Eduardo Habkost
The documentation for QOM is not clear about who owns references to objects (i.e. who is responsible for calling object_unref() later). This is important considering there are a few inconsistencies in the API (e.g. callers of object_new() need to call object_unref() later, but callers of

[Qemu-devel] [RFC 0/3] qom/qdev: Try to clarify ownership rules

2018-07-12 Thread Eduardo Habkost
The ownership rules of some QOM and qdev functions are not very clear. Some of the rules are not trivial because they depend on other arguments or flags specified when a property was created. This is an attempt to clarify the existing ownership rules of those functions to avoid confusion in the

[Qemu-devel] [Bug 1779955] Re: qemu linux-user requires read permissions on memory passed to syscalls that should only need write access

2018-07-12 Thread Ke Liu
Thanks Peter for your information. I was hit by the bug when trying to compile bazel (a build system open- sourced by Google: https://bazel.build) and the code is at https://github.com/bazelbuild/bazel/blob/master/third_party/ijar/mapped_file_unix.cc#L116 Of course I can send PR to fix that in

[Qemu-devel] [PATCH] configure: Support pkg-config for zlib

2018-07-12 Thread Stefan Weil
This is needed for builds with the mingw64-* packages from Cygwin, but also works for Linux. Move the zlib test also more to the end because users should get information on the really important missing packages (which also require zlib) first. Signed-off-by: Stefan Weil --- configure | 40

[Qemu-devel] [Bug 1781463] [NEW] qemu don't start *.abs firmware files

2018-07-12 Thread David Martins
Public bug reported: Hello Devs, I'm here to report this bug/issue because i'm using Win64 Qemu but i can't start a *.abs firmware at normally this firmware is based in Linux Kernel and this type of firmware is made for STB Receivers, So this is all information i provide to get support. Files

Re: [Qemu-devel] [virtio-dev] Re: [PATCH v3 0/3] Use of unique identifier for pairing virtio and passthrough devices...

2018-07-12 Thread Michael S. Tsirkin
On Wed, Jul 11, 2018 at 11:53:44AM +0200, Cornelia Huck wrote: > On Tue, 10 Jul 2018 17:07:37 -0700 > Siwei Liu wrote: > > > On Mon, Jul 9, 2018 at 6:54 PM, Michael S. Tsirkin wrote: > > > On Mon, Jul 09, 2018 at 06:11:53PM -0700, si-wei liu wrote: > > >> The plan is to enable group ID based

[Qemu-devel] [PATCH] qemu-img: avoid overflow of min_sparse parameter

2018-07-12 Thread Peter Lieven
the min_sparse convert parameter can overflow (e.g. -S 1024G) in the conversion from int64_t to int resulting in a negative min_sparse parameter. Avoid this by limiting the valid parameters to sane values. In fact anything exceeding the convert buffer size is also pointless. While at it also

Re: [Qemu-devel] [PATCH 0/6] fix persistent bitmaps migration logic

2018-07-12 Thread Vladimir Sementsov-Ogievskiy
Hi, what about this? I'll be on vacation next two weeks. Best regards, Vladimir. От: Vladimir Sementsov-Ogievskiy Отправлено: 26 июня 2018 г. 16:50:29 Кому: qemu-devel@nongnu.org; qemu-bl...@nongnu.org Копия: dgilb...@redhat.com; quint...@redhat.com;

Re: [Qemu-devel] [PATCH v0 7/7] migration: add background snapshotting

2018-07-12 Thread Dr. David Alan Gilbert
* Denis Plotnikov (dplotni...@virtuozzo.com) wrote: > The patch enables to save vmstate to a migration thread > in the background: ram is being saved while vCPUs are running. > This is done to reduce downtime on vm snapshotting: the majority > of vmstate is ram, the rest of devices consumes only a

Re: [Qemu-devel] [PATCH v2] Zero out the host's `msg_control` buffer

2018-07-12 Thread Laurent Vivier
Le 12/07/2018 à 20:22, Jonas Schievink a écrit : > Yes, I do. > See https://gist.github.com/jonas-schievink/cb6e6584a055539d2113f22d91068e2d > > The problem is that glibc's CMSG_NXTHDR macro will access the header of > the *next* message which isn't yet overwritten by QEMU, so it still > contains

Re: [Qemu-devel] [PATCH v2] Zero out the host's `msg_control` buffer

2018-07-12 Thread Jonas Schievink
Yes, I do. See https://gist.github.com/jonas-schievink/cb6e6584a055539d2113f22d91068e2d The problem is that glibc's CMSG_NXTHDR macro will access the header of the *next* message which isn't yet overwritten by QEMU, so it still contains garbage at that point. In particular, it will access the

Re: [Qemu-devel] [PATCH 05/20] qobject: Replace qobject_from_jsonf() by qobject_from_jsonf_nofail()

2018-07-12 Thread Thomas Huth
On 12.07.2018 13:12, Markus Armbruster wrote: > Commit ab45015a968 "qobject: Let qobject_from_jsonf() fail instead of > abort" removed only one of two ways qobject_from_jsonf() can abort. > Wrong. Wrong because it calls qobject_from_jsonv() with error_abort. Maybe mentioned that in the patch

Re: [Qemu-devel] [PATCH] hw/arm/bcm283x: Fix crash with device_add bcm2837 on unsupported machines

2018-07-12 Thread Eduardo Habkost
On Thu, Jul 12, 2018 at 10:05:46AM +0200, Paolo Bonzini wrote: > On 11/07/2018 22:23, Eduardo Habkost wrote: > > On Wed, Jul 11, 2018 at 10:16:42PM +0200, Paolo Bonzini wrote: > >> On 11/07/2018 20:30, Eduardo Habkost wrote: > The theoretical behavior should be: > >>> It's not clear below

Re: [Qemu-devel] [PATCH for-3.0 2/2] hw/intc/arm_gic: Fix handling of GICD_ITARGETSR

2018-07-12 Thread Richard Henderson
On 07/12/2018 10:41 AM, Peter Maydell wrote: > The GICD_ITARGETSR implementation still has some 11MPCore behaviour > that we were incorrectly using in our GICv1 and GICv2 implementations > for the case where the interrupt number is less than GIC_INTERNAL. > The desired behaviour here is: > * for

Re: [Qemu-devel] [PATCH for-3.0 1/2] hw/intc/arm_gic: Check interrupt number in gic_deactivate_irq()

2018-07-12 Thread Richard Henderson
On 07/12/2018 10:41 AM, Peter Maydell wrote: > In gic_deactivate_irq() the interrupt number comes from the guest > (on a write to the GICC_DIR register), so we need to sanity check > that it isn't out of range before we use it as an array index. > Handle this in a similar manner to the check we do

[Qemu-devel] [PATCH v2] dump: add kernel_gs_base to QEMU CPU state

2018-07-12 Thread Viktor Prutyanov
This patch adds field with content of KERNEL_GS_BASE MSR to QEMU note in ELF dump. On Windows, if all vCPUs are running usermode tasks at the time the dump is created, this can be helpful in the discovery of guest system structures during conversion ELF dump to MEMORY.DMP dump. Signed-off-by:

Re: [Qemu-devel] [Qemu-ppc] [PATCH v2 2/2] vga: don't pick cirrus by default

2018-07-12 Thread Eduardo Habkost
On Thu, Jul 12, 2018 at 06:57:46AM +0200, Thomas Huth wrote: > On 11.07.2018 20:43, Eduardo Habkost wrote: > > On Wed, Jul 11, 2018 at 07:00:54PM +0200, Sebastian Bauer wrote: > >> Am 2018-07-11 17:48, schrieb Eduardo Habkost: > >>> "none" looked like a false positive when I first looked, but now

Re: [Qemu-devel] [PULL 0/7] Block layer fixes for 3.0-rc1

2018-07-12 Thread Peter Maydell
On 12 July 2018 at 17:31, Kevin Wolf wrote: > The following changes since commit dc3c89d612252fc461a65f54885a1fe108e9ec05: > > ui/cocoa.m: replace scrollingDeltaY with deltaY (2018-07-12 16:03:50 +0100) > > are available in the git repository at: > > git://repo.or.cz/qemu/kevin.git

Re: [Qemu-devel] [PATCH 1/5] qom/object: Add a new function object_initialize_as_child()

2018-07-12 Thread Eduardo Habkost
On Thu, Jul 12, 2018 at 05:30:59PM +0200, Thomas Huth wrote: > A lot of code is using the object_initialize() function followed by a call to > object_property_add_child() to add the newly initialized object as a child of > the current object. Both functions increase the reference counter of the

[Qemu-devel] [PATCH] hw/arm/bcm2836: Mark the bcm2836 / bcm2837 devices with user_creatable = false

2018-07-12 Thread Thomas Huth
These devices are currently causing some problems when a user is trying to hot-plug or introspect them during runtime. Since these devices can not be instantiated by the user at all (they need to be wired up in code instead), we should mark them with user_creatable = false anyway, then we avoid at

Re: [Qemu-devel] [PATCH 1/5] qom/object: Add a new function object_initialize_as_child()

2018-07-12 Thread Peter Maydell
On 12 July 2018 at 17:55, Thomas Huth wrote: > On 12.07.2018 18:52, Eduardo Habkost wrote: >> On Thu, Jul 12, 2018 at 05:30:59PM +0200, Thomas Huth wrote: >>> @@ -749,6 +749,25 @@ int object_set_propv(Object *obj, >>> void object_initialize(void *obj, size_t size, const char *typename); >>> >>>

Re: [Qemu-devel] [PATCH 1/5] qom/object: Add a new function object_initialize_as_child()

2018-07-12 Thread Eduardo Habkost
On Thu, Jul 12, 2018 at 06:55:20PM +0200, Thomas Huth wrote: > On 12.07.2018 18:52, Eduardo Habkost wrote: > > On Thu, Jul 12, 2018 at 05:30:59PM +0200, Thomas Huth wrote: > >> A lot of code is using the object_initialize() function followed by a call > >> to > >> object_property_add_child() to

Re: [Qemu-devel] [PATCH 1/5] qom/object: Add a new function object_initialize_as_child()

2018-07-12 Thread Thomas Huth
On 12.07.2018 18:52, Eduardo Habkost wrote: > On Thu, Jul 12, 2018 at 05:30:59PM +0200, Thomas Huth wrote: >> A lot of code is using the object_initialize() function followed by a call to >> object_property_add_child() to add the newly initialized object as a child of >> the current object. Both

Re: [Qemu-devel] [PATCH 1/5] qom/object: Add a new function object_initialize_as_child()

2018-07-12 Thread Eduardo Habkost
On Thu, Jul 12, 2018 at 05:30:59PM +0200, Thomas Huth wrote: > A lot of code is using the object_initialize() function followed by a call to > object_property_add_child() to add the newly initialized object as a child of > the current object. Both functions increase the reference counter of the

[Qemu-devel] Native Memory Virtualization in qemu-system-aarch64

2018-07-12 Thread Kevin Loughlin
I know TrustZone has support for memory virtualization in AArch64, but I'm looking to create a different model. Namely, I'd like to fully virtualize the memory map for the "virt" board. As a basic example of what I want, assuming an execution environment that runs in a 1GB physical address space

Re: [Qemu-devel] [Qemu-arm] [PATCH 0/6] accel/tcg: Support execution from MMIO and small MMU regions

2018-07-12 Thread Peter Maydell
On 11 July 2018 at 05:21, Philippe Mathieu-Daudé wrote: > Hi Peter, > > On 07/10/2018 01:00 PM, Peter Maydell wrote: >> This series adds support to TCG for executing from MMIO regions >> and small MMU regions. The basic principle is that if get_page_addr_code() >> finds that the region is not

[Qemu-devel] [PULL 7/7] qemu-img: align result of is_allocated_sectors

2018-07-12 Thread Kevin Wolf
From: Peter Lieven We currently don't enforce that the sparse segments we detect during convert are aligned. This leads to unnecessary and costly read-modify-write cycles either internally in Qemu or in the background on the storage device as nearly all modern filesystems or hardware have a 4k

[Qemu-devel] [PULL 5/7] iotests: add test 226 for file driver types

2018-07-12 Thread Kevin Wolf
From: John Snow Test that we're rejecting what we ought to for file, host_driver and host_cdrom drivers. Test that we're seeing the deprecated message for block and chardevs on the file driver. Signed-off-by: John Snow Signed-off-by: Kevin Wolf --- tests/qemu-iotests/226 | 66

[Qemu-devel] [PULL 4/7] file-posix: specify expected filetypes

2018-07-12 Thread Kevin Wolf
From: John Snow Adjust each caller of raw_open_common to specify if they are expecting host and character devices or not. Tighten expectations of file types upon open in the common code and refuse types that are not expected. This has two effects: (1) Character and block devices are now

[Qemu-devel] [PULL 1/7] iotests: 153: Fix dead code

2018-07-12 Thread Kevin Wolf
From: Fam Zheng This step was left behind my mistake. As suggested by the echoed text, the intention was to test two devices with the same image, with different options. The behavior should be the same as two QEMU processes. Complete it. Signed-off-by: Fam Zheng Signed-off-by: Kevin Wolf ---

Re: [Qemu-devel] [PATCH] hw/arm/bcm283x: Fix crash with device_add bcm2837 on unsupported machines

2018-07-12 Thread Thomas Huth
On 12.07.2018 18:22, Peter Maydell wrote: > On 12 July 2018 at 17:16, Markus Armbruster wrote: >> Thomas Huth writes: >> >>> On 12.07.2018 14:06, Markus Armbruster wrote: Peter Maydell writes: > On 11 July 2018 at 17:12, Eduardo Habkost wrote: >> On Wed, Jul 11, 2018 at

[Qemu-devel] [PULL 0/7] Block layer fixes for 3.0-rc1

2018-07-12 Thread Kevin Wolf
The following changes since commit dc3c89d612252fc461a65f54885a1fe108e9ec05: ui/cocoa.m: replace scrollingDeltaY with deltaY (2018-07-12 16:03:50 +0100) are available in the git repository at: git://repo.or.cz/qemu/kevin.git tags/for-upstream for you to fetch changes up to

[Qemu-devel] [PULL 6/7] scsi-disk: Block Device Characteristics emulation fix

2018-07-12 Thread Kevin Wolf
From: Daniel Henrique Barboza The current BDC VPD page (page 0xb1) is too short. This can be seen running sg_utils: $ sg_vpd --page=bdc /dev/sda Block device characteristics VPD page (SBC): Block device characteristics VPD page length too short=8 By the SCSI spec, the expected size of the SBC

[Qemu-devel] [PULL 3/7] qemu-img: Document copy offloading implications with -S and -c

2018-07-12 Thread Kevin Wolf
From: Fam Zheng Explicitly enabling zero detection or compression suppresses copy offloading during convert. Document it. Suggested-by: Kevin Wolf Signed-off-by: Fam Zheng Reviewed-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf --- qemu-img.texi | 6 -- 1 file changed, 4 insertions(+),

[Qemu-devel] [PULL 2/7] iotests: nbd: Stop qemu-nbd before remaking image

2018-07-12 Thread Kevin Wolf
From: Fam Zheng 197 is one example where _make_test_img is used twice without stopping the NBD server in between. An error will occur like this: @@ -26,9 +26,13 @@ === Partial final cluster === +qemu-img: TEST_DIR/t.IMGFMT: Failed to get "resize" lock +Is another process

Re: [Qemu-devel] qemu-nbd vs 'simple' trace backend vs iotest 147

2018-07-12 Thread Stefan Hajnoczi
On Wed, Jul 11, 2018 at 03:33:21PM +0200, Cornelia Huck wrote: > The other qemu-nbds (the inet and the unix socket ones from the first > run, the second inet one from the second run) have a single thread with > the same backtrace I posted above. We just discussed this on IRC, but for the record:

Re: [Qemu-devel] [PATCH 04/20] libqtest: Clean up how we read the QMP greeting

2018-07-12 Thread Thomas Huth
On 12.07.2018 13:12, Markus Armbruster wrote: > qtest_init() still uses the qtest_qmp_discard_response(s, "") hack to > receive the greeting, even though we have qtest_qmp_receive() since > commit 66e0c7b187e. Put it to use. > > Bonus: gets rid of an empty format string. A step towards >

Re: [Qemu-devel] [PATCH 03/20] libqtest: Clean up how we read device_del messages

2018-07-12 Thread Thomas Huth
On 12.07.2018 13:12, Markus Armbruster wrote: > qtest_qmp_device_del() still uses the qmp("") hack to receive a > message, even though we have qmp_receive() since commit 66e0c7b187e. > Put it to use. > > Bonus: gets rid of empty format strings. A step towards compile-time > format string

Re: [Qemu-devel] [PATCH V6] qemu-img: align result of is_allocated_sectors

2018-07-12 Thread Kevin Wolf
Am 12.07.2018 um 15:00 hat Peter Lieven geschrieben: > We currently don't enforce that the sparse segments we detect during convert > are > aligned. This leads to unnecessary and costly read-modify-write cycles either > internally in Qemu or in the background on the storage device as nearly all >

Re: [Qemu-devel] [PATCH] hw/arm/bcm283x: Fix crash with device_add bcm2837 on unsupported machines

2018-07-12 Thread Peter Maydell
On 12 July 2018 at 17:16, Markus Armbruster wrote: > Thomas Huth writes: > >> On 12.07.2018 14:06, Markus Armbruster wrote: >>> Peter Maydell writes: >>> On 11 July 2018 at 17:12, Eduardo Habkost wrote: > On Wed, Jul 11, 2018 at 09:21:48AM +0200, Thomas Huth wrote: >> Hm, ok, so

Re: [Qemu-devel] [PATCH] aspeed: Implement write-1-{set, clear} for AST2500 strapping

2018-07-12 Thread Peter Maydell
On 12 July 2018 at 17:10, Andrew Jeffery wrote: > On Fri, 13 Jul 2018, at 01:28, Peter Maydell wrote: >> On 9 July 2018 at 15:35, Andrew Jeffery wrote: >> > The AST2500 SoC family changes the runtime behaviour of the hardware >> > strapping register (SCU70) to write-1-set/write-1-clear, with >>

Re: [Qemu-devel] [PATCH] hw/arm/bcm283x: Fix crash with device_add bcm2837 on unsupported machines

2018-07-12 Thread Markus Armbruster
Thomas Huth writes: > On 12.07.2018 14:06, Markus Armbruster wrote: >> Peter Maydell writes: >> >>> On 11 July 2018 at 17:12, Eduardo Habkost wrote: On Wed, Jul 11, 2018 at 09:21:48AM +0200, Thomas Huth wrote: > Hm, ok, so how to continue here now? Shall we at least mark the >

Re: [Qemu-devel] [PATCH] aspeed: Implement write-1-{set, clear} for AST2500 strapping

2018-07-12 Thread Andrew Jeffery
On Fri, 13 Jul 2018, at 01:28, Peter Maydell wrote: > On 9 July 2018 at 15:35, Andrew Jeffery wrote: > > The AST2500 SoC family changes the runtime behaviour of the hardware > > strapping register (SCU70) to write-1-set/write-1-clear, with > > write-1-clear implemented on the "read-only" SoC

Re: [Qemu-devel] [PATCH v2] Zero out the host's `msg_control` buffer

2018-07-12 Thread Laurent Vivier
Le 12/07/2018 à 00:12, Jonas Schievink a écrit : > If this is not done, qemu would drop any control message after the first > one. > > This is because glibc's `CMSG_NXTHDR` macro accesses the uninitialized > cmsghdr's length field in order to find out if the message fits into the > `msg_control`

Re: [Qemu-devel] [PATCH] aspeed: Implement write-1-{set, clear} for AST2500 strapping

2018-07-12 Thread Peter Maydell
On 9 July 2018 at 15:35, Andrew Jeffery wrote: > The AST2500 SoC family changes the runtime behaviour of the hardware > strapping register (SCU70) to write-1-set/write-1-clear, with > write-1-clear implemented on the "read-only" SoC revision register > (SCU7C). For the the AST2400, the hardware

Re: [Qemu-devel] [PATCH for-3.0] target/arm: Fix LD1W and LDFF1W (scalar plus vector)

2018-07-12 Thread Peter Maydell
On 11 July 2018 at 11:39, Richard Henderson wrote: > 'I' was being double-incremented; correctly within the inner loop > and incorrectly within the outer loop. > > Signed-off-by: Richard Henderson > --- > > Fixes a SIGSEGV within one of these generated helpers, > exposed by an armclang

Re: [Qemu-devel] [PATCH v3] ui/cocoa.m: replace scrollingDeltaY with deltaY

2018-07-12 Thread Peter Maydell
On 11 July 2018 at 22:18, Peter Maydell wrote: > On 9 July 2018 at 16:02, John Arbuckle wrote: >> The NSEvent class method scrollingDeltaY is available >> for Mac OS 10.7 and newer. Since QEMU supports Mac OS >> 10.5 and up, we need to be using a method that is >> available on these version of

Re: [Qemu-devel] [Spice-devel] Ongoing migration: gitlab.com/spice -> gitlab.freedesktop.org/spice

2018-07-12 Thread Victor Toso
Hi, JFYI, CC'ing: * qemu-devel * virt-tools-list * de...@ovirt.org If nobody complains, I'll finish whatever is pending next Monday morning (GMT+2). Cheers, toso On Thu, Jul 12, 2018 at 02:12:43PM +0200, Victor Toso wrote: > Hi, > > The official repository for Spice components should

Re: [Qemu-devel] [PATCH v1 0/5] Fix crashes with introspection

2018-07-12 Thread Peter Maydell
On 12 July 2018 at 16:30, Thomas Huth wrote: > As discovered recently, you can crash QEMU with a lot of devices > that do not get the reference counting of child objects right. > You just have to run 'device-list-properties' and call 'info qtree' > afterwards. > This patch series fixes a bunch of

Re: [Qemu-devel] [PATCH v2 2/5] i386: Add CPUID bit and feature words for IA32_ARCH_CAPABILITIES MSR

2018-07-12 Thread Paolo Bonzini
On 12/07/2018 11:18, Robert Hoo wrote: >>> And you'd like to set IA32_ARCH_CAPABILITIES.RSBA by default in qemu or >>> kvm layer? >> Probably we need to make this decision in QEMU. If KVM set RSBA >> automatically on .get_msr_feature(), QEMU won't be able to >> differentiate a host with RSBA set

Re: [Qemu-devel] [libvirt] [PULL 25/26] block: Remove deprecated -drive option serial

2018-07-12 Thread Thomas Huth
On 12.07.2018 08:32, Markus Armbruster wrote: > Daniel P. Berrangé writes: [...] >> For libvirt, I think whenever something is proposed for deprecation >> we could just CC libvir-list, or ask one of the libvirt people to >> confirm its not being used. If it is, then we should file BZ against >>

[Qemu-devel] [PATCH for-3.0 2/2] hw/intc/arm_gic: Fix handling of GICD_ITARGETSR

2018-07-12 Thread Peter Maydell
The GICD_ITARGETSR implementation still has some 11MPCore behaviour that we were incorrectly using in our GICv1 and GICv2 implementations for the case where the interrupt number is less than GIC_INTERNAL. The desired behaviour here is: * for 11MPCore: RAZ/WI for irqs 0..28; read a number matching

[Qemu-devel] [PATCH for-3.0 1/2] hw/intc/arm_gic: Check interrupt number in gic_deactivate_irq()

2018-07-12 Thread Peter Maydell
In gic_deactivate_irq() the interrupt number comes from the guest (on a write to the GICC_DIR register), so we need to sanity check that it isn't out of range before we use it as an array index. Handle this in a similar manner to the check we do in gic_complete_irq() for the GICC_EOI register.

[Qemu-devel] [PATCH for-3.0 0/2] a couple of GICv2 bug fixes

2018-07-12 Thread Peter Maydell
These patches fix bugs in our GICv2 implementation that we noticed in the course of reviewing Luc's patchset to add virtualization support to it. Patch 1 is a missing bounds check, effectively. Luckily there was a mask operation in place that means it's not actually possible to do anything nasty

Re: [Qemu-devel] [PATCH v1 0/5] Fix crashes with introspection

2018-07-12 Thread Paolo Bonzini
On 12/07/2018 17:30, Thomas Huth wrote: > As discovered recently, you can crash QEMU with a lot of devices > that do not get the reference counting of child objects right. > You just have to run 'device-list-properties' and call 'info qtree' > afterwards. > This patch series fixes a bunch of these

Re: [Qemu-devel] [PATCH 12/20] cpu-plug-test: Don't pass integers as strings to device_add

2018-07-12 Thread Thomas Huth
On 12.07.2018 13:12, Markus Armbruster wrote: > test_plug_with_device_add_x86() plugs Haswell-i386-cpu and > Haswell-x86_64-cpu with device_add. It passes socket-id, core-id, > thread-id as JSON strings. The properties are actually integers. > > test_plug_with_device_add_coreid() plugs

[Qemu-devel] [PATCH 5/5] hw/cpu/a15mpcore: Fix introspection problem with the a15mpcore_priv device

2018-07-12 Thread Thomas Huth
There is a memory management problem when introspecting the a15mpcore_priv device. It can be seen with valgrind when running QEMU like this: echo "{'execute':'qmp_capabilities'} {'execute':'device-list-properties'," \ "'arguments':{'typename':'a15mpcore_priv'}}"\ "{'execute':

[Qemu-devel] [PATCH 4/5] hw/arm/armv7: Fix crash when introspecting the "iotkit" device

2018-07-12 Thread Thomas Huth
QEMU currently crashes when introspecting the "iotkit" device and runnint "info qtree" afterwards, e.g. when running QEMU like this: echo "{'execute':'qmp_capabilities'} {'execute':'device-list-properties'," \ "'arguments':{'typename':'iotkit'}}" "{'execute': 'human-monitor-command', " \

[Qemu-devel] [PATCH 1/5] qom/object: Add a new function object_initialize_as_child()

2018-07-12 Thread Thomas Huth
A lot of code is using the object_initialize() function followed by a call to object_property_add_child() to add the newly initialized object as a child of the current object. Both functions increase the reference counter of the new object, but many spots that call these two functions then forget

[Qemu-devel] [PATCH 3/5] hw/arm/bcm2836: Fix crash with device_add bcm2837 on unsupported machines

2018-07-12 Thread Thomas Huth
When trying to "device_add bcm2837" on a machine that is not suitable for this device, you can quickly crash QEMU afterwards, e.g. with "info qtree": echo "{'execute':'qmp_capabilities'} {'execute':'device_add', " \ "'arguments':{'driver':'bcm2837'}} {'execute': 'human-monitor-command', " \

[Qemu-devel] [PATCH 2/5] hw/core/sysbus: Add a function for creating and attaching an object

2018-07-12 Thread Thomas Huth
A lot of functions are initializing an object and attach it immediately afterwards to the system bus. Provide a common function for this, which also uses object_initialize_as_child() to make sure that the reference counter is correctly initialized to 1 afterwards. Signed-off-by: Thomas Huth ---

[Qemu-devel] [PATCH v1 0/5] Fix crashes with introspection

2018-07-12 Thread Thomas Huth
As discovered recently, you can crash QEMU with a lot of devices that do not get the reference counting of child objects right. You just have to run 'device-list-properties' and call 'info qtree' afterwards. This patch series fixes a bunch of these problems in the ARM code. I did not fix all

Re: [Qemu-devel] [PATCH] hw/arm/bcm283x: Fix crash with device_add bcm2837 on unsupported machines

2018-07-12 Thread Thomas Huth
On 12.07.2018 14:06, Markus Armbruster wrote: > Peter Maydell writes: > >> On 11 July 2018 at 17:12, Eduardo Habkost wrote: >>> On Wed, Jul 11, 2018 at 09:21:48AM +0200, Thomas Huth wrote: Hm, ok, so how to continue here now? Shall we at least mark the bcm2836/7 devices with

Re: [Qemu-devel] [RFC v3 06/15] hw/arm/virt: Allocate device_memory

2018-07-12 Thread Andrew Jones
On Thu, Jul 12, 2018 at 04:53:01PM +0200, Auger Eric wrote: > Hi Drew, > > On 07/12/2018 04:45 PM, Andrew Jones wrote: > > On Thu, Jul 12, 2018 at 04:22:05PM +0200, Auger Eric wrote: > >> Hi Igor, > >> > >> On 07/11/2018 03:17 PM, Igor Mammedov wrote: > >>> On Thu, 5 Jul 2018 16:27:05 +0200 > >>>

Re: [Qemu-devel] [PATCH v1 1/1] scsi-disk: Block Device Characteristics emulation fix

2018-07-12 Thread Kevin Wolf
Am 12.07.2018 um 16:53 hat Paolo Bonzini geschrieben: > On 11/07/2018 22:58, Daniel Henrique Barboza wrote: > > The current BDC VPD page (page 0xb1) is too short. This can be > > seen running sg_utils: > > > > $ sg_vpd --page=bdc /dev/sda > > Block device characteristics VPD page (SBC): > > Block

Re: [Qemu-devel] [PATCH] migration: add capability to bypass the shared memory

2018-07-12 Thread Peng Tao
Hi Stefan, On Tue, Jul 10, 2018 at 9:40 PM, Stefan Hajnoczi wrote: > Two things come to mind: > > At that point both guest kernel and agent address-space layout > randomization (ASLR) is finished. ALSR makes it harder for memory > corruption bugs to lead to real exploits because the attacker

Re: [Qemu-devel] [PATCH v3 4/4] tests: Add centos VM testing

2018-07-12 Thread Philippe Mathieu-Daudé
Hi Fam, On 07/11/2018 10:28 PM, Fam Zheng wrote: > This one does docker testing in the VM. It is intended to replace the > native docker testing on patchew testers. > > Signed-off-by: Fam Zheng > --- > tests/vm/Makefile.include | 3 +- > tests/vm/centos | 84

Re: [Qemu-devel] [PULL 0/1] seccomp branch queue

2018-07-12 Thread Peter Maydell
bo/qemu.git tags/pull-seccomp-20180712 > > for you to fetch changes up to 056de1e894155fbb99e7b43c1c4382d4920cf437: > > seccomp: allow sched_setscheduler() with SCHED_IDLE policy (2018-07-12 > 14:52:39 +0200) > > --

Re: [Qemu-devel] [PATCH v3 20/20] arm/virt: Add support for GICv2 virtualization extensions

2018-07-12 Thread Peter Maydell
On 5 July 2018 at 09:46, Luc Michel wrote: > On 07/05/2018 10:00 AM, Jan Kiszka wrote: >> On 2018-07-05 08:51, Jan Kiszka wrote: >>> But now I'm running into troubles with reading back GICD ITARGETSR. >>> Maybe we are emulating an "early implementation" here? >>> >>> [from the related Jailhouse

Re: [Qemu-devel] [PATCH v1 1/1] scsi-disk: Block Device Characteristics emulation fix

2018-07-12 Thread Paolo Bonzini
On 11/07/2018 22:58, Daniel Henrique Barboza wrote: > The current BDC VPD page (page 0xb1) is too short. This can be > seen running sg_utils: > > $ sg_vpd --page=bdc /dev/sda > Block device characteristics VPD page (SBC): > Block device characteristics VPD page length too short=8 > > By the SCSI

Re: [Qemu-devel] [RFC v3 06/15] hw/arm/virt: Allocate device_memory

2018-07-12 Thread Auger Eric
Hi Drew, On 07/12/2018 04:45 PM, Andrew Jones wrote: > On Thu, Jul 12, 2018 at 04:22:05PM +0200, Auger Eric wrote: >> Hi Igor, >> >> On 07/11/2018 03:17 PM, Igor Mammedov wrote: >>> On Thu, 5 Jul 2018 16:27:05 +0200 >>> Auger Eric wrote: >>> Hi Shameer, On 07/05/2018 03:19 PM,

Re: [Qemu-devel] [PATCH v3 0/4] Add a CentOS test image to run docker tests

2018-07-12 Thread Philippe Mathieu-Daudé
On 07/11/2018 10:28 PM, Fam Zheng wrote: > v3: Add 'make vm-test' document. [Phil] > > v2: Drop archive-source.sh changes. > The new test depends on the iotests nbd fix I posted today to pass. > > Docker testing on patchew has long suffered from 'make check' hangings. The > cleanness of VM

Re: [Qemu-devel] [RFC v3 06/15] hw/arm/virt: Allocate device_memory

2018-07-12 Thread Andrew Jones
On Thu, Jul 12, 2018 at 04:22:05PM +0200, Auger Eric wrote: > Hi Igor, > > On 07/11/2018 03:17 PM, Igor Mammedov wrote: > > On Thu, 5 Jul 2018 16:27:05 +0200 > > Auger Eric wrote: > > > >> Hi Shameer, > >> > >> On 07/05/2018 03:19 PM, Shameerali Kolothum Thodi wrote: > >>> >

Re: [Qemu-devel] [PATCH v3 20/20] arm/virt: Add support for GICv2 virtualization extensions

2018-07-12 Thread Peter Maydell
On 29 June 2018 at 14:29, Luc Michel wrote: > Add support for GICv2 virtualization extensions by mapping the necessary > I/O regions and connecting the maintenance IRQ lines. > > Declare those additions in the device tree and in the ACPI tables. > > Signed-off-by: Luc Michel > --- >

  1   2   3   >