[Qemu-devel] [PULL 41/54] vhost-net: move stubs to a separate file

2018-12-12 Thread Paolo Bonzini
There is no reason for CONFIG_VHOST_NET to be specific to a single target; it is a host feature that can be add to all targets, as long as they support the virtio-net device. Currently CONFIG_VHOST_NET depends on CONFIG_KVM, but ioeventfd support is present in the core memory API and works with

Re: [Qemu-devel] [RFC 3/3] pvh: Boot uncompressed kernel using direct boot ABI

2018-12-12 Thread Stefano Garzarella
On Tue, Dec 11, 2018 at 7:35 PM Maran Wilson wrote: > > On 12/11/2018 9:11 AM, Stefano Garzarella wrote: > > Hi Liam, > > in order to support PVH also with SeaBIOS, I'm going to work on a new > > option rom (like linuxboot/multiboot) that can be used in this case. > > That is awesome. Yes, please

[Qemu-devel] [PULL 48/54] vhost-user: support cross-endian vnet headers

2018-12-12 Thread Paolo Bonzini
vhost-user already has a way to communicate the endianness of the guest via the vring endianness messages. The vring endianness always matches the vnet header endianness so there is no need to do anything else in the backend. Reviewed-by: Marc-André Lureau Signed-off-by: Paolo Bonzini

[Qemu-devel] [PULL 43/54] vhost: restrict Linux dependency to kernel vhost

2018-12-12 Thread Paolo Bonzini
vhost-user does not depend on Linux; it can run on any POSIX system. Restrict vhost-kernel to Linux in hw/virtio/vhost-backend.c, everything else can be compiled on all POSIX systems. Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Message-Id:

[Qemu-devel] [PULL 31/54] qemu/queue.h: simplify reverse access to QTAILQ

2018-12-12 Thread Paolo Bonzini
The new definition of QTAILQ does not require passing the headname, remove it. Signed-off-by: Paolo Bonzini --- cpus-common.c | 2 +- dump.c | 2 +- hw/core/qdev.c | 4 ++-- hw/scsi/scsi-bus.c | 2 +-

[Qemu-devel] [PULL 54/54] vhost-user-test: create a temporary directory per TestServer

2018-12-12 Thread Paolo Bonzini
This makes the tests more independent, and also the source and destination TestServers in the migration test. Reviewed-by: Marc-André Lureau Signed-off-by: Paolo Bonzini Message-Id: <1543851204-41186-15-git-send-email-pbonz...@redhat.com> --- tests/vhost-user-test.c | 75

[Qemu-devel] [PULL 47/54] vhost-user-test: signal data_cond when s->rings changes

2018-12-12 Thread Paolo Bonzini
This speeds up wait_for_rings_started, which currently is just waiting for the timeout before checking s->rings. Reviewed-by: Marc-André Lureau Signed-off-by: Paolo Bonzini Message-Id: <1543851204-41186-8-git-send-email-pbonz...@redhat.com> --- tests/vhost-user-test.c | 2 ++ 1 file changed, 2

[Qemu-devel] [PULL 34/54] configure: Remove obsolete check for Clang < 3.2

2018-12-12 Thread Paolo Bonzini
From: Thomas Huth Since we have got a check for Clang >= 3.4 now, we do not need to check for older Clang versions in the configure test for 128-bit ints anymore. Signed-off-by: Thomas Huth Reviewed-by: Richard Henderson Message-Id: <1543937577-28256-3-git-send-email-th...@redhat.com> ---

[Qemu-devel] [PULL 46/54] vhost-user-test: use g_cond_broadcast

2018-12-12 Thread Paolo Bonzini
g_cond_signal is rarely the right thing to do, it works now because vhost-user-test only has two threads but it is not correct in general. Fix it before adding more calls. Reviewed-by: Marc-André Lureau Signed-off-by: Paolo Bonzini Message-Id:

[Qemu-devel] [PULL 40/54] hw/watchdog/wdt_i6300esb : remove a unnecessary comment

2018-12-12 Thread Paolo Bonzini
From: Peng Hao The registered memory region of i6300esb is not suitable for coalesced mmio, because a write for the region may trigger an immediate action and can't be delayed. Signed-off-by: Peng Hao Message-Id: <1544253511-82742-1-git-send-email-peng.h...@zte.com.cn> Signed-off-by: Paolo

[Qemu-devel] [PULL 50/54] vhost-user-test: skip if there is no memory at address 0

2018-12-12 Thread Paolo Bonzini
The virt machine cannot run the vhost-user qtests because they hardcode the presence of memory at address 0. Report the tests as a skip so that they can be converted to use qgraph. Reviewed-by: Marc-André Lureau Signed-off-by: Paolo Bonzini Message-Id:

[Qemu-devel] [PULL 37/54] audio/alsaaudio: Remove compiler check around pragma

2018-12-12 Thread Paolo Bonzini
From: Thomas Huth Both GCC v4.8 and Clang v3.4 support the -Waddress option, so we do not need the compiler version check here anymore. Signed-off-by: Thomas Huth Reviewed-by: Richard Henderson Message-Id: <1543937577-28256-6-git-send-email-th...@redhat.com> --- audio/alsaaudio.c | 2 -- 1

[Qemu-devel] [PULL 36/54] tcg/tcg.h: Remove GCC check for tcg_debug_assert() macro

2018-12-12 Thread Paolo Bonzini
From: Thomas Huth Both GCC v4.8 and Clang v3.4 support (our minimum versions) support __builtin_unreachable(), so we can remove the version check here now. Reviewed-by: Richard Henderson Signed-off-by: Thomas Huth Message-Id: <1543937577-28256-5-git-send-email-th...@redhat.com> --- tcg/tcg.h

[Qemu-devel] [PULL 39/54] Remove QEMU_ARTIFICIAL macro

2018-12-12 Thread Paolo Bonzini
From: Thomas Huth The code that used it has already been removed a while ago with commit dc41aa7d34989b552ef ("tcg: Remove GET_TCGV_* and MAKE_TCGV_*"). Reviewed-by: Richard Henderson Signed-off-by: Thomas Huth Message-Id: <1543937577-28256-8-git-send-email-th...@redhat.com> ---

[Qemu-devel] [PULL 27/54] qemu/queue.h: leave head structs anonymous unless necessary

2018-12-12 Thread Paolo Bonzini
Most list head structs need not be given a name. In most cases the name is given just in case one is going to use QTAILQ_LAST, QTAILQ_PREV or reverse iteration, but this does not apply to lists of other kinds, and even for QTAILQ in practice this is only rarely needed. In addition, we will soon

[Qemu-devel] [PULL 23/54] test: replace gtester with a TAP driver

2018-12-12 Thread Paolo Bonzini
gtester is deprecated by upstream glib (see for example the announcement at https://blog.gtk.org/2018/07/11/news-from-glib-2-58/) and it does not support tests that call g_test_skip in some glib stable releases. glib suggests instead using Automake's TAP support, which gtest itself supports since

[Qemu-devel] [PULL 18/54] build-sys: don't include windows.h, osdep.h does it

2018-12-12 Thread Paolo Bonzini
From: Marc-André Lureau osdep.h will also define the available Windows API version for QEMU. Signed-off-by: Marc-André Lureau Message-Id: <20181122110039.15972-2-marcandre.lur...@redhat.com> Signed-off-by: Paolo Bonzini --- accel/tcg/translate-all.c | 4 1 file changed, 4 deletions(-)

[Qemu-devel] [PULL 38/54] includes: Replace QEMU_GNUC_PREREQ with "__has_builtin || !defined(__clang__)"

2018-12-12 Thread Paolo Bonzini
From: Thomas Huth Since we require GCC version 4.8 or newer now, we can be sure that the builtin functions are always available on GCC. And for Clang, we can check the availablility with __has_builtin instead. Reviewed-by: Richard Henderson Signed-off-by: Thomas Huth Message-Id:

[Qemu-devel] [PULL 33/54] configure: Add a test for the minimum compiler version

2018-12-12 Thread Paolo Bonzini
From: Thomas Huth So far we only had implicit requirements for the minimum compiler version, e.g. we require at least GCC 4.1 for the support of atomics. However, such old compiler versions are not tested anymore by the developers, so they are not really supported anymore. Since we recently

[Qemu-devel] [PULL 30/54] qemu/queue.h: reimplement QTAILQ without pointer-to-pointers

2018-12-12 Thread Paolo Bonzini
QTAILQ is a doubly linked list, with a pointer-to-pointer to the last element from the head, and the previous element from each node. But if you squint enough, QTAILQ becomes a combination of a singly-linked forwards list, and another singly-linked list which goes backwards and is circular. This

[Qemu-devel] [PULL 22/54] test: execute g_test_run when tests are skipped

2018-12-12 Thread Paolo Bonzini
Sometimes a test's main() function recognizes that the environment does not support the test, and therefore exits. In this case, we still should run g_test_run() so that a TAP harness will print the test plan ("1..0") and the test will be marked as skipped. Signed-off-by: Paolo Bonzini

[Qemu-devel] [PULL 32/54] checkpatch: warn about qemu/queue.h head structs that are not typedef-ed

2018-12-12 Thread Paolo Bonzini
These are just like any other struct or union, so they should have CamelCase typedefs. Signed-off-by: Paolo Bonzini --- scripts/checkpatch.pl | 5 + 1 file changed, 5 insertions(+) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index a8d6e44..b4b3495 100755 ---

[Qemu-devel] [PULL 35/54] configure: Remove old -fno-gcse workaround for GCC 4.6.x and 4.7.[012]

2018-12-12 Thread Paolo Bonzini
From: Thomas Huth Now that we require at least GCC 4.8, we don't need this als workaround for 4.6 and 4.7 anymore. Reviewed-by: Richard Henderson Signed-off-by: Thomas Huth Message-Id: <1543937577-28256-4-git-send-email-th...@redhat.com> --- Makefile.target | 3 --- configure | 16

[Qemu-devel] [PULL 29/54] qemu/queue.h: remove Q_TAILQ_{HEAD, ENTRY}

2018-12-12 Thread Paolo Bonzini
These are not present for other kinds of queue, and unused. Zap them before more changes are made to the QTAILQ implementation. Signed-off-by: Paolo Bonzini --- include/qemu/queue.h | 14 ++ scripts/cocci-macro-file.h | 10 -- 2 files changed, 6 insertions(+), 18

[Qemu-devel] [PULL 19/54] build-sys: move windows defines in osdep.h header

2018-12-12 Thread Paolo Bonzini
From: Marc-André Lureau This removes some clutter in compilation logging, and allows some easier tweaking per compilation unit/CFLAGS overriding. Note that we can't move those define in os-win32.h, since they must be set before the first system headers are included. Signed-off-by: Marc-André

[Qemu-devel] [PULL 28/54] qemu/queue.h: typedef QTAILQ heads

2018-12-12 Thread Paolo Bonzini
This will be needed when we change the QTAILQ head and elem structs to unions. However, it is also consistent with the usage elsewhere in QEMU for other list head structs (see for example FsMountList). Note that most QTAILQs only need their name in order to do backwards walks. Those do not

[Qemu-devel] [PULL 12/54] block/iscsi: drop unused IscsiAIOCB->buf field

2018-12-12 Thread Paolo Bonzini
From: Stefan Hajnoczi The IscsiAIOCB->buf field has not been used since commit e49ab19fcaa617ad6cdfe1ac401327326b6a2552 ("block/iscsi: bump libiscsi requirement to 1.9.0"). It used to be a linear buffer for old libiscsi versions that didn't support scatter-gather. The minimum libiscsi version

[Qemu-devel] [PULL 26/54] vfio: make vfio_address_spaces static

2018-12-12 Thread Paolo Bonzini
It is not used outside hw/vfio/common.c, so it does not need to be extern. Acked-by: Alex Williamson Signed-off-by: Paolo Bonzini --- hw/vfio/common.c | 2 +- include/hw/vfio/vfio-common.h | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/hw/vfio/common.c

[Qemu-devel] [PULL 16/54] esp-pci: Fix status register write erase control

2018-12-12 Thread Paolo Bonzini
From: Guenter Roeck Per AM53C974 datasheet, definition of "SCSI Bus and Control (SBAC)" register: Bit 24 'STATUS' Write Erase Control This bit controls the Write Erase feature on bits 3:1 and bit 6 of the DMA Status Register ((B)+54h). When this bit is programmed to '1', the state of bits 3:1

[Qemu-devel] [PULL 10/54] memory: update coalesced_range on transaction_commit

2018-12-12 Thread Paolo Bonzini
The e1000 driver calls memory_region_add_coalescing but kvm_coalesce_mmio_region is never called for those regions. The bug dates back to the introduction of the memory region API; to fix it, delete and re-add coalesced MMIO ranges when building the FlatViews. Because coalesced MMIO regions

[Qemu-devel] [PULL 25/54] qemu/queue.h: do not access tqe_prev directly

2018-12-12 Thread Paolo Bonzini
Use the QTAILQ_IN_USE macro instead, it does the same thing but the next patch will change it to a different definition. Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Markus Armbruster Signed-off-by: Paolo Bonzini --- blockdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

[Qemu-devel] [PULL 24/54] compiler.h: Add an explicit check for the compiler version

2018-12-12 Thread Paolo Bonzini
From: Thomas Huth The questions about our minimum compiler requirement pops up every couple of months, and we then have to recall the details each time. So let's document this in a proper way, by adding a comment and check for the right compiler version to our compiler.h header. Signed-off-by:

[Qemu-devel] [PULL 17/54] scsi: esp: Defer command completion until previous interrupts have been handled

2018-12-12 Thread Paolo Bonzini
From: Guenter Roeck The guest OS reads RSTAT, RSEQ, and RINTR, and expects those registers to reflect a consistent state. However, it is possible that the registers can change after RSTAT was read, but before RINTR is read, when esp_command_complete() is called. Guest OSqemu

[Qemu-devel] [PULL 21/54] RFC: qga: drop < Vista compatibility

2018-12-12 Thread Paolo Bonzini
From: Marc-André Lureau Building QGA for XP seems possible so far: the dependency on libqemuutil.a implies building qemu-thread-win32.c, which requires Vista API since commit 12f8def0 (v2.9). But qemu-thread isn't being used in QGA, the resulting binary may still work on XP. XP is no longer

[Qemu-devel] [PULL 03/54] checkpatch: fix premature exit when no input or --mailback

2018-12-12 Thread Paolo Bonzini
In some cases, checkpatch's process subroutine is exiting the whole process. This is wrong, just return from the subroutine instead. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Paolo Bonzini --- scripts/checkpatch.pl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff

[Qemu-devel] [PULL 06/54] checkpatch: colorize output to terminal

2018-12-12 Thread Paolo Bonzini
Add optional colors to make seeing message types a bit easier. The default is to show them on a tty. Inspired by Linux commits 57230297116fa ("checkpatch: colorize output to terminal") and 737c0767758b ("checkpatch: change format of --color argument to --color[=WHEN]"). Signed-off-by: Paolo

[Qemu-devel] [PULL 02/54] vhost-user-bridge: fix "unknown type name" compilation error

2018-12-12 Thread Paolo Bonzini
From: Marc-André Lureau osdep.h should be included first: CC tests/vhost-user-bridge.o In file included from /home/elmarco/src/qemu/tests/vhost-user-bridge.c:32: /home/elmarco/src/qemu/include/qemu/atomic.h:480:1: error: unknown type name ‘int64_t’ int64_t atomic_read_i64(const

[Qemu-devel] [PULL 13/54] block/iscsi: take iscsilun->mutex in iscsi_timed_check_events()

2018-12-12 Thread Paolo Bonzini
From: Stefan Hajnoczi Commit d045c466d9e62b4321fadf586d024d54ddfd8bd4 ("iscsi: do not use aio_context_acquire/release") introduced iscsilun->mutex but appears to have overlooked iscsi_timed_check_events() when introducing the mutex. iscsi_service() and iscsi_set_events() must be called with

[Qemu-devel] [PULL 08/54] memory: extract flat_range_coalesced_io_{del, add}

2018-12-12 Thread Paolo Bonzini
Extract two new functions from memory_region_update_coalesced_range_as. To avoid duplication in the creation of the MemoryRegionSection, use MEMORY_LISTENER_UPDATE_REGION instead of MEMORY_LISTENER_CALL to invoke the listener callback. Signed-off-by: Paolo Bonzini --- memory.c | 53

[Qemu-devel] [PULL 15/54] block/iscsi: cancel libiscsi task when ABORT TASK TMF completes

2018-12-12 Thread Paolo Bonzini
From: Stefan Hajnoczi The libiscsi iscsi_task_mgmt_async() API documentation says: abort_task will also cancel the scsi task. The callback for the scsi task will be invoked with SCSI_STATUS_CANCELLED The libiscsi implementation does not fulfil this promise. The task's callback is not

[Qemu-devel] [PULL 20/54] build-sys: build with Vista API by default

2018-12-12 Thread Paolo Bonzini
From: Marc-André Lureau Both qemu & qga build with Vista API by default already, by defining _WIN32_WINNT 0x0600. Set it globally in osdep.h instead. This replaces WINVER by _WIN32_WINNT in osdep.h. WINVER doesn't seem to be really useful these days. (see also

[Qemu-devel] [PULL 05/54] checkpatch: improve handling of multiple patches or files

2018-12-12 Thread Paolo Bonzini
Similar to how patchew output looks like for multiple patches, say what file or patch is being tested _before_ emitting errors. This is clearer to a human that scans the output from top to bottom. In addition, provide a truncated commit hash and subject instead of the full hash, and process the

[Qemu-devel] [PULL 11/54] hax: Support for Linux hosts

2018-12-12 Thread Paolo Bonzini
From: Alexandro Sanchez Bach Intel HAXM supports now 32-bit and 64-bit Linux hosts. This patch includes the corresponding userland changes. Since the Darwin userland backend is POSIX-compliant, the hax-darwin.{c,h} files have been renamed to hax-posix.{c,h}. This prefix is consistent with the

[Qemu-devel] [PULL 14/54] block/iscsi: fix ioctl cancel use-after-free

2018-12-12 Thread Paolo Bonzini
From: Stefan Hajnoczi iscsi_aio_cancel() does not increment the request's reference count, causing a use-after-free when ABORT TASK finishes after the request has already completed. There are some additional issues with iscsi_aio_cancel(): 1. Several ABORT TASKs may be sent for the same task if

[Qemu-devel] [PULL 07/54] pam: wrap MemoryRegion initialization in a transaction

2018-12-12 Thread Paolo Bonzini
This avoids a few re-rendering of the memory AddressSpace. Signed-off-by: Paolo Bonzini --- hw/pci-host/pam.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/pci-host/pam.c b/hw/pci-host/pam.c index e361ecb..aa5ecfd 100644 --- a/hw/pci-host/pam.c +++ b/hw/pci-host/pam.c @@ -52,11

[Qemu-devel] [PULL 01/54] accel: Improve selection of the default accelerator

2018-12-12 Thread Paolo Bonzini
From: Thomas Huth When compiling with "--disable-tcg", we currently still use "tcg" as default accelerator. "kvm" should be used in this case instead. Also, some downstream distros provide QEMU binaries which have "kvm" in their names (e.g. "qemu-kvm" on RHEL or "kvm" on Ubuntu) that use KVM by

[Qemu-devel] [PULL 09/54] memory: avoid unnecessary coalesced_io_del operations

2018-12-12 Thread Paolo Bonzini
Store whether the FlatRange has had any coalesced I/O ranges applied, and if not avoid calling coalesced_io_del. This is useful in preparation for the next patch, which will call coalesced_io_del when rendering memory regions. Signed-off-by: Paolo Bonzini --- memory.c | 11 +++ 1 file

[Qemu-devel] [PULL 04/54] checkpatch: check Signed-off-by in --mailback mode

2018-12-12 Thread Paolo Bonzini
Pull the test before the anticipated exits from the process sub. Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Paolo Bonzini --- scripts/checkpatch.pl | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index

[Qemu-devel] [PULL 00/54] Misc patches for 2018-12-12

2018-12-12 Thread Paolo Bonzini
The following changes since commit bb9bf94b3e8926553290bc9a7cb84315af422086: Merge remote-tracking branch 'remotes/ehabkost/tags/machine-next-pull-request' into staging (2018-12-11 19:18:58 +) are available in the git repository at: git://github.com/bonzini/qemu.git tags/for-upstream

Re: [Qemu-devel] [qemu-s390x] [PATCH 01/15] s390 vfio-ccw: Add bootindex property and IPLB data

2018-12-12 Thread Jason J. Herne
On 12/12/18 9:11 AM, Jason J. Herne wrote: ... diff --git a/hw/vfio/ccw.c b/hw/vfio/ccw.c index 9246729..6f480c6 100644 --- a/hw/vfio/ccw.c +++ b/hw/vfio/ccw.c @@ -20,23 +20,12 @@ #include "hw/sysbus.h" #include "hw/vfio/vfio.h" #include "hw/vfio/vfio-common.h" +#include "hw/vfio/ccw.h"

Re: [Qemu-devel] [PATCH for-4.0 00/71] qtest: qgraph driver framework

2018-12-12 Thread Philippe Mathieu-Daudé
Hi Paolo, On 12/3/18 4:32 PM, Paolo Bonzini wrote: > Patches 1-14 are actually a refactoring of vhost and vhost-user-test so > that it can be "qtested" on all targets that support virtio-net. > > Patches 15-18 are other small refactorings to the libqos library and fixes > to the Makefile. > >

Re: [Qemu-devel] [PATCH V6 0/6] nvdimm: support MAP_SYNC for memory-backend-file

2018-12-12 Thread Michael S. Tsirkin
On Wed, Dec 12, 2018 at 04:11:44PM +0800, Zhang Yi wrote: > Linux 4.15 introduces a new mmap flag MAP_SYNC, which can be used to > guarantee the write persistence to mmap'ed files supporting DAX (e.g., > files on ext4/xfs file system mounted with '-o dax'). > > A description of MAP_SYNC and

Re: [Qemu-devel] [qemu-s390x] [PATCH v2 2/3] s390: cpu feature for diagnose 318 andlimit max VCPUs to 247

2018-12-12 Thread Collin Walling
On 12/12/18 8:41 AM, Cornelia Huck wrote: > On Wed, 12 Dec 2018 12:20:08 +0100 > David Hildenbrand wrote: > >> On 11.12.18 22:12, Collin Walling wrote: >>> On 12/11/18 11:47 AM, Collin Walling wrote: On 12/7/18 7:08 AM, Cornelia Huck wrote: > On Thu, 6 Dec 2018 17:24:17 -0500 >

Re: [Qemu-devel] [RFC PATCH 0/7] virtio-fs: shared file system for virtual machines3

2018-12-12 Thread Stefan Hajnoczi
On Wed, Dec 12, 2018 at 01:58:25PM +, Daniel P. Berrangé wrote: > On Wed, Dec 12, 2018 at 01:52:03PM +, Dr. David Alan Gilbert wrote: > IMHO we need something whose support status is on a par with what you'd > get if we had the impl in-process for the main QEMU system emulator. I agree.

Re: [Qemu-devel] [PATCH 00/15] s390: vfio-ccw dasd ipl support

2018-12-12 Thread Jason J. Herne
On 12/12/18 9:34 AM, Cornelia Huck wrote: On Wed, 12 Dec 2018 09:11:03 -0500 "Jason J. Herne" wrote: Hm, I think you need to adjust your cc: list. I added some more folks (and removed Dong Jia, whose address is no longer valid AFAIK). Correct. I forgot to update my list before I sent.

Re: [Qemu-devel] [PATCH 22/71] tests/libqos: sdhci driver and interface nodes

2018-12-12 Thread Philippe Mathieu-Daudé
On 12/3/18 4:32 PM, Paolo Bonzini wrote: > From: Emanuele Giuseppe Esposito > > Add qgraph nodes for sdhci-pci and generic-sdhci (memory mapped) drivers. > Both drivers implement (produce) the same interface sdhci, that provides the > readw - readq - writeq functions. > > Signed-off-by:

Re: [Qemu-devel] [PATCH 00/15] s390: vfio-ccw dasd ipl support

2018-12-12 Thread Cornelia Huck
On Wed, 12 Dec 2018 09:11:03 -0500 "Jason J. Herne" wrote: Hm, I think you need to adjust your cc: list. I added some more folks (and removed Dong Jia, whose address is no longer valid AFAIK). > This is to support booting from vfio-ccw dasd devices. We basically implement > the real hardware

Re: [Qemu-devel] [PATCH] x86: host-phys-bits-limit option

2018-12-12 Thread Eduardo Habkost
On Wed, Dec 12, 2018 at 12:08:08PM -0200, Wainer dos Santos Moschetta wrote: > > On 12/11/2018 05:25 PM, Eduardo Habkost wrote: > > Some downstream distributions of QEMU set host-phys-bits=on by > > default. This worked very well for most use cases, because > > phys-bits really didn't have huge

Re: [Qemu-devel] [PATCH 28/71] qos-test: sdhci test node

2018-12-12 Thread Philippe Mathieu-Daudé
On 12/3/18 4:32 PM, Paolo Bonzini wrote: > From: Emanuele Giuseppe Esposito > > Convert tests/sdhci-test in first qgraph test node, sdhci-test. This test > consumes an sdhci interface and checks that its function return the > expected values. > > Note that this test does not allocate any sdhci

Re: [Qemu-devel] [PATCH 17/71] tests: remove rule for nonexisting qdev-monitor-test

2018-12-12 Thread Philippe Mathieu-Daudé
On 12/3/18 4:32 PM, Paolo Bonzini wrote: > This test was merged into drive_del-test in 2014. in e2f3f221885. > > Signed-off-by: Paolo Bonzini Reviewed-by: Philippe Mathieu-Daudé > --- > tests/Makefile.include | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/tests/Makefile.include

[Qemu-devel] [PATCH 15/15] s390-bios: Support booting from real dasd device

2018-12-12 Thread Jason J. Herne
Allows guest to boot from a vfio configured real dasd device. Signed-off-by: Jason J. Herne --- docs/devel/s390-dasd-ipl.txt | 132 +++ pc-bios/s390-ccw/Makefile| 2 +- pc-bios/s390-ccw/dasd-ipl.c | 249 +++

[Qemu-devel] [PATCH 14/15] s390-bios: Add channel command codes/structs needed for dasd-ipl

2018-12-12 Thread Jason J. Herne
The dasd IPL procedure needs to execute a few previously unused channel commands. Let's define them and their associated data structures. Signed-off-by: Jason J. Herne --- pc-bios/s390-ccw/cio.h | 23 +++ 1 file changed, 23 insertions(+) diff --git a/pc-bios/s390-ccw/cio.h

[Qemu-devel] [PATCH 09/15] s390-bios: ptr2u32 and u32toptr

2018-12-12 Thread Jason J. Herne
Introduce inline functions to convert between pointers and unsigned 32-bit ints. These are used to hide the ugliness required to avoid compiler warnings. Signed-off-by: Jason J. Herne --- pc-bios/s390-ccw/libc.h | 12 1 file changed, 12 insertions(+) diff --git

[Qemu-devel] [PATCH 11/15] s390-bios: cio error handling

2018-12-12 Thread Jason J. Herne
Add verbose error output for when unexpected i/o errors happen. This eases the burden of debugging and reporting i/o errors. No error information is printed in the success case, here is an example of what is output on error: vfio-ccw device I/O error - Interrupt Response Block Data: Function

[Qemu-devel] [PATCH 13/15] s390-bios: Use control unit type to determine boot method

2018-12-12 Thread Jason J. Herne
The boot method is different depending on which device type we are booting from. Let's examine the control unit type to determine if we're a virtio device. We'll eventually add a case to check for a real dasd device here as well. Signed-off-by: Jason J. Herne --- pc-bios/s390-ccw/main.c | 15

Re: [Qemu-devel] [PATCH] x86: host-phys-bits-limit option

2018-12-12 Thread Eduardo Habkost
On Wed, Dec 12, 2018 at 05:08:39PM +0800, Yu Zhang wrote: > On Tue, Dec 11, 2018 at 05:25:27PM -0200, Eduardo Habkost wrote: > > Some downstream distributions of QEMU set host-phys-bits=on by > > default. This worked very well for most use cases, because > > phys-bits really didn't have huge

[Qemu-devel] [PATCH 06/15] s390-bios: Clean up cio.h

2018-12-12 Thread Jason J. Herne
Add proper typedefs to all structs and modify all bit fields to use consistent formatting. Signed-off-by: Jason J. Herne Reviewed-by: Collin Walling --- pc-bios/s390-ccw/cio.h | 86 ++--- pc-bios/s390-ccw/s390-ccw.h | 8 - 2 files changed, 43

[Qemu-devel] [PATCH 04/15] s390-bios: Extend find_dev() for non-virtio devices

2018-12-12 Thread Jason J. Herne
We need a method for finding the subchannel of a dasd device. Let's modify find_dev to handle this since it mostly does what we need. Up to this point find_dev has been specific to only virtio devices. Signed-off-by: Jason J. Herne Acked-by: Halil Pasic --- pc-bios/s390-ccw/main.c | 16

[Qemu-devel] [PATCH 10/15] s390-bios: Support for running format-0/1 channel programs

2018-12-12 Thread Jason J. Herne
Add struct for format-0 ccws. Support executing format-0 channel programs and waiting for their completion before continuing execution. This will be used for real dasd ipl. Add cu_type() to channel io library. This will be used to query control unit type which is used to determine if we are

[Qemu-devel] [PATCH 00/15] s390: vfio-ccw dasd ipl support

2018-12-12 Thread Jason J. Herne
This is to support booting from vfio-ccw dasd devices. We basically implement the real hardware ipl procedure. This allows for booting Linux guests on vfio-ccw devices. vfio-ccw's channel program prefetch algorithm complicates ipl because most ipl channel programs dynamically modify themselves.

[Qemu-devel] [PATCH 07/15] s390-bios: Decouple channel i/o logic from virtio

2018-12-12 Thread Jason J. Herne
Create a separate library for channel i/o related code. This decouples channel i/o operations from virtio and allows us to make use of them for the real dasd boot path. Signed-off-by: Jason J. Herne --- pc-bios/s390-ccw/Makefile| 2 +- pc-bios/s390-ccw/cio.c | 41

[Qemu-devel] [PATCH 12/15] s390-bios: Refactor virtio to run channel programs via cio

2018-12-12 Thread Jason J. Herne
Now that we have a Channel I/O library let's modify virtio boot code to make use of it for running channel programs. Signed-off-by: Jason J. Herne --- pc-bios/s390-ccw/virtio.c | 21 ++--- 1 file changed, 2 insertions(+), 19 deletions(-) diff --git a/pc-bios/s390-ccw/virtio.c

[Qemu-devel] [PATCH 08/15] s390-bios: Map low core memory

2018-12-12 Thread Jason J. Herne
Create a new header for basic architecture specific definitions and add a mapping of low core memory. This mapping will be used by the real dasd boot process. Signed-off-by: Jason J. Herne --- pc-bios/s390-ccw/main.c | 2 + pc-bios/s390-ccw/s390-arch.h | 100

[Qemu-devel] [PATCH 01/15] s390 vfio-ccw: Add bootindex property and IPLB data

2018-12-12 Thread Jason J. Herne
Add bootindex property and iplb data for vfio-ccw devices. This allows us to forward boot information into the bios for vfio-ccw devices. Signed-off-by: Jason J. Herne Acked-by: Halil Pasic --- hw/s390x/ipl.c | 15 +++ hw/s390x/s390-ccw.c | 9 +

[Qemu-devel] [PATCH 05/15] s390-bios: Factor finding boot device out of virtio code path

2018-12-12 Thread Jason J. Herne
Make a new routine find_boot_device to locate the boot device for all cases. not just virtio. In one case no boot device is specified and a suitable boot device can not be auto detected. The error message for this case was specific to virtio devices. We update this message to remove virtio

[Qemu-devel] [PATCH 02/15] s390-bios: decouple cio setup from virtio

2018-12-12 Thread Jason J. Herne
Move channel i/o setup code out to a separate function. This decouples cio setup from the virtio code path and allows us to make use of it for booting dasd devices. Signed-off-by: Jason J. Herne Acked-by: Halil Pasic Reviewed-by: Collin Walling --- pc-bios/s390-ccw/main.c | 20

[Qemu-devel] [PATCH 03/15] s390-bios: decouple common boot logic from virtio

2018-12-12 Thread Jason J. Herne
Create a boot_setup function to handle getting boot information from the machine/hypervisor. This decouples common boot logic from the virtio code path and allows us to make use of it for the real dasd boot scenario. Signed-off-by: Jason J. Herne Acked-by: Halil Pasic Reviewed-by: Collin

Re: [Qemu-devel] [RFC PATCH 0/7] virtio-fs: shared file system for virtual machines3

2018-12-12 Thread Daniel P . Berrangé
On Wed, Dec 12, 2018 at 01:52:03PM +, Dr. David Alan Gilbert wrote: > * Daniel P. Berrangé (berra...@redhat.com) wrote: > > On Mon, Dec 10, 2018 at 05:31:44PM +, Dr. David Alan Gilbert (git) > > wrote: > > > From: "Dr. David Alan Gilbert" > > > > > > Hi, > > > This is the first RFC

[Qemu-devel] [PULL 33/41] block: Use bdrv_reopen_set_read_only() in the mirror driver

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia The 'block-commit' QMP command is implemented internally using two different drivers. If the source image is the active layer then the mirror driver is used (commit_active_start()), otherwise the commit driver is used (commit_start()). In both cases the destination image

Re: [Qemu-devel] [PATCH] x86: host-phys-bits-limit option

2018-12-12 Thread Wainer dos Santos Moschetta
On 12/11/2018 05:25 PM, Eduardo Habkost wrote: Some downstream distributions of QEMU set host-phys-bits=on by default. This worked very well for most use cases, because phys-bits really didn't have huge consequences. The only difference was on the CPUID data seen by guests, and on the

[Qemu-devel] [PULL 32/41] block: Use bdrv_reopen_set_read_only() in external_snapshot_commit()

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia This patch replaces the bdrv_reopen() call that set and remove the BDRV_O_RDWR flag with the new bdrv_reopen_set_read_only() function. Signed-off-by: Alberto Garcia Reviewed-by: Max Reitz Signed-off-by: Kevin Wolf --- blockdev.c | 3 +-- 1 file changed, 1 insertion(+),

[Qemu-devel] [PULL 30/41] block: Use bdrv_reopen_set_read_only() in stream_start/complete()

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia This patch replaces the bdrv_reopen() calls that set and remove the BDRV_O_RDWR flag with the new bdrv_reopen_set_read_only() function. Signed-off-by: Alberto Garcia Reviewed-by: Max Reitz Signed-off-by: Kevin Wolf --- block/stream.c | 20 ++-- 1 file

[Qemu-devel] [PULL 29/41] block: Use bdrv_reopen_set_read_only() in bdrv_commit()

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia This patch replaces the bdrv_reopen() calls that set and remove the BDRV_O_RDWR flag with the new bdrv_reopen_set_read_only() function. Signed-off-by: Alberto Garcia Reviewed-by: Max Reitz Signed-off-by: Kevin Wolf --- block/commit.c | 7 +++ 1 file changed, 3

[Qemu-devel] [PULL 31/41] block: Use bdrv_reopen_set_read_only() in qmp_change_backing_file()

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia This patch replaces the bdrv_reopen() calls that set and remove the BDRV_O_RDWR flag with the new bdrv_reopen_set_read_only() function. Signed-off-by: Alberto Garcia Reviewed-by: Max Reitz Signed-off-by: Kevin Wolf --- blockdev.c | 8 ++-- 1 file changed, 2

Re: [Qemu-devel] [PATCH 2/3] mac_newworld: enable access to EDID data for the VGA device

2018-12-12 Thread Gerd Hoffmann
On Wed, Dec 12, 2018 at 08:54:37AM +, Mark Cave-Ayland wrote: > On 12/12/2018 08:32, Gerd Hoffmann wrote: > > > On Fri, Dec 07, 2018 at 04:08:05PM +, Mark Cave-Ayland wrote: > >> This is in preparation for some upcoming QEMU NDRV driver changes that pass > >> display information from the

[Qemu-devel] [PULL 26/41] block: Add bdrv_reopen_set_read_only()

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia Most callers of bdrv_reopen() only use it to switch a BlockDriverState between read-only and read-write, so this patch adds a new function that does just that. We also want to get rid of the flags parameter in the bdrv_reopen() API, so this function sets the "read-only"

Re: [Qemu-devel] [RFC PATCH 0/7] virtio-fs: shared file system for virtual machines3

2018-12-12 Thread Dr. David Alan Gilbert
* Daniel P. Berrangé (berra...@redhat.com) wrote: > On Mon, Dec 10, 2018 at 05:31:44PM +, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > Hi, > > This is the first RFC for the QEMU side of 'virtio-fs'; > > a new mechanism for mounting host directories into

[Qemu-devel] [PULL 25/41] file-posix: Avoid aio_worker() for QEMU_AIO_IOCTL

2018-12-12 Thread Kevin Wolf
aio_worker() doesn't add anything interesting, it's only a useless indirection. Call the handler function directly instead. As we know that this handler function is only called from coroutine context and the coroutine stays around until the worker thread finishes, we can keep RawPosixAIOData on

Re: [Qemu-devel] [qemu-s390x] [PATCH v2 2/3] s390: cpu feature for diagnose 318 andlimit max VCPUs to 247

2018-12-12 Thread Cornelia Huck
On Wed, 12 Dec 2018 12:20:08 +0100 David Hildenbrand wrote: > On 11.12.18 22:12, Collin Walling wrote: > > On 12/11/18 11:47 AM, Collin Walling wrote: > >> On 12/7/18 7:08 AM, Cornelia Huck wrote: > >>> On Thu, 6 Dec 2018 17:24:17 -0500 > >>> Collin Walling wrote: > >>> > Diagnose

[Qemu-devel] [PULL 40/41] block: Assert that flags are up-to-date in bdrv_reopen_prepare()

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia Towards the end of bdrv_reopen_queue_child(), before starting to process the children, the update_flags_from_options() function is called in order to have BDRVReopenState.flags in sync with the options from the QDict. This is necessary because during the reopen process

[Qemu-devel] [PULL 23/41] file-posix: Remove paio_submit_co()

2018-12-12 Thread Kevin Wolf
The function is not used any more, remove it. Signed-off-by: Kevin Wolf --- block/file-posix.c | 34 -- 1 file changed, 34 deletions(-) diff --git a/block/file-posix.c b/block/file-posix.c index 0f64c83639..c8a085a911 100644 --- a/block/file-posix.c +++

[Qemu-devel] [PULL 37/41] block: Remove flags parameter from bdrv_reopen_queue()

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia Now that all callers are passing all flag changes as QDict options, the flags parameter is no longer necessary, so we can get rid of it. Signed-off-by: Alberto Garcia Reviewed-by: Max Reitz Signed-off-by: Kevin Wolf --- include/block/block.h | 3 +-- block.c

[Qemu-devel] [PULL 41/41] iotests: make 235 work on s390 (and others)

2018-12-12 Thread Kevin Wolf
From: Christian Borntraeger "-machine pc" will not work all architectures. Lets fall back to the default machine by not specifying it. In addition we also need to specify -no-shutdown on s390 as qemu will exit otherwise. Cc: qemu-sta...@nongnu.org Signed-off-by: Christian Borntraeger

[Qemu-devel] [PULL 22/41] file-posix: Avoid aio_worker() for QEMU_AIO_READ/WRITE

2018-12-12 Thread Kevin Wolf
aio_worker() doesn't add anything interesting, it's only a useless indirection. Call the handler function directly instead. As we know that this handler function is only called from coroutine context and the coroutine stays around until the worker thread finishes, we can keep RawPosixAIOData on

[Qemu-devel] [PULL 39/41] block: Remove assertions from update_flags_from_options()

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia This function takes four options (cache.direct, cache.no-flush, read-only and auto-read-only) from a QemuOpts object and updates the flags accordingly. If any of those options is not set (because it was missing from the original QDict or because it had an invalid value)

[Qemu-devel] [PULL 36/41] block: Clean up reopen_backing_file() in block/replication.c

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia This function is used to put the hidden and secondary disks in read-write mode before launching the backup job, and back in read-only mode afterwards. This patch does the following changes: - Use an options QDict with the "read-only" option instead of passing the

[Qemu-devel] [PULL 18/41] file-posix: Avoid aio_worker() for QEMU_AIO_WRITE_ZEROES

2018-12-12 Thread Kevin Wolf
aio_worker() doesn't add anything interesting, it's only a useless indirection. Call the handler function directly instead. As we know that this handler function is only called from coroutine context and the coroutine stays around until the worker thread finishes, we can keep RawPosixAIOData on

[Qemu-devel] [PULL 24/41] file-posix: Switch to .bdrv_co_ioctl

2018-12-12 Thread Kevin Wolf
No real reason to keep using the callback based mechanism here when the rest of the file-posix driver is coroutine based. Changing it brings ioctls more in line with how other request types work. Signed-off-by: Kevin Wolf --- include/scsi/pr-manager.h | 8 +++- block/file-posix.c|

[Qemu-devel] [PULL 27/41] block: Use bdrv_reopen_set_read_only() in bdrv_backing_update_filename()

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia This patch replaces the bdrv_reopen() calls that set and remove the BDRV_O_RDWR flag with the new bdrv_reopen_set_read_only() function. Signed-off-by: Alberto Garcia Reviewed-by: Max Reitz Signed-off-by: Kevin Wolf --- block.c | 10 +- 1 file changed, 5

[Qemu-devel] [PULL 35/41] qemu-io: Put flag changes in the options QDict in reopen_f()

2018-12-12 Thread Kevin Wolf
From: Alberto Garcia When reopen_f() puts a block device in the reopen queue, some of the new options are passed using a QDict, but others ("read-only" and the cache options) are passed as flags. This patch puts those flags in the QDict. This way the flags parameter becomes redundant and we'll

<    1   2   3   4   5   6   >