Re: [Qemu-devel] [PATCH v3] scripts/checkpatch.pl: add check for `while` and `for`

2018-02-28 Thread Darren Kenny
On Wed, Feb 28, 2018 at 11:31:29AM +0800, Su Hang wrote: Adding check for `while` and `for` statements, which condition has more than one line. The former checkpatch.pl can check `if` statement, which condition has more than one line, whether block misses brace round, like this: ''' if (cond1 ||

Re: [Qemu-devel] [qemu-s390x] [PATCH] vfio-ccw: license text should indicate GPL v2 or later

2018-02-28 Thread Christian Borntraeger
On 02/27/2018 06:32 PM, Cornelia Huck wrote: > The license text currently specifies "any version" of the GPL. It > is unlikely that GPL v1 was ever intended; change this to the > standard "or any later version" text. > > Cc: Dong Jia Shi > Cc: Xiao Feng Ren > Cc: Pierre Morel > Signed-off-by: C

Re: [Qemu-devel] [RFC QEMU PATCH v4 05/10] xen-hvm: initialize fw_cfg interface

2018-02-28 Thread Haozhong Zhang
On 02/27/18 16:46 +, Anthony PERARD wrote: > On Thu, Dec 07, 2017 at 06:18:07PM +0800, Haozhong Zhang wrote: > > Xen is going to reuse QEMU to build ACPI of some devices (e.g., NFIT > > and SSDT for NVDIMM) for HVM domains. The existing QEMU ACPI build > > code requires a fw_cfg interface which

Re: [Qemu-devel] [PATCH V6 3/4] tests/migration: Add migration-test header file

2018-02-28 Thread Andrew Jones
On Tue, Feb 27, 2018 at 04:27:33PM +, Dr. David Alan Gilbert wrote: > * Wei Huang (w...@redhat.com) wrote: > > > > > > On 02/27/2018 05:57 AM, Dr. David Alan Gilbert wrote: > > > * Wei Huang (w...@redhat.com) wrote: > > >> This patch moves the settings related migration-test from the > > >> m

Re: [Qemu-devel] [PATCH v3 09/29] postcopy: Allow registering of fd handler

2018-02-28 Thread Peter Xu
On Fri, Feb 16, 2018 at 01:16:05PM +, Dr. David Alan Gilbert (git) wrote: [...] > diff --git a/migration/postcopy-ram.h b/migration/postcopy-ram.h > index bee21d4401..4bda5aa509 100644 > --- a/migration/postcopy-ram.h > +++ b/migration/postcopy-ram.h > @@ -141,4 +141,25 @@ void postcopy_remov

Re: [Qemu-devel] [PATCH v3 11/29] vhost+postcopy: Transmit 'listen' to client

2018-02-28 Thread Peter Xu
On Fri, Feb 16, 2018 at 01:16:07PM +, Dr. David Alan Gilbert (git) wrote: [...] > typedef struct VuVirtqElement { > diff --git a/docs/interop/vhost-user.txt b/docs/interop/vhost-user.txt > index 621543e654..bdec9ec0e8 100644 > --- a/docs/interop/vhost-user.txt > +++ b/docs/interop/vhost-user

Re: [Qemu-devel] [PATCH v9 00/14] ARM SMMUv3 Emulation Support

2018-02-28 Thread Auger Eric
Hi Peter, On 27/02/18 20:02, Peter Maydell wrote: > On 17 February 2018 at 18:46, Eric Auger wrote: >> This series implements the emulation code for ARM SMMUv3. >> >> SMMUv3 gets instantiated by adding ",iommu=smmuv3" to the virt >> machine option. >> >> VHOST integration will be handled in a sep

Re: [Qemu-devel] [PATCH v3 10/29] vhost+postcopy: Register shared ufd with postcopy

2018-02-28 Thread Peter Xu
On Fri, Feb 16, 2018 at 01:16:06PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Register the UFD that comes in as the response to the 'advise' method > with the postcopy code. > > Signed-off-by: Dr. David Alan Gilbert > --- > hw/virtio/vhost-user.c | 21 +++

Re: [Qemu-devel] [PATCH v3 12/29] postcopy+vhost-user: Split set_mem_table for postcopy

2018-02-28 Thread Peter Xu
On Fri, Feb 16, 2018 at 01:16:08PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Split the set_mem_table routines in both qemu and libvhost-user > because the postcopy versions are going to be quite different > once changes in the later patches are added. > > Si

Re: [Qemu-devel] [PATCH v3 13/29] migration/ram: ramblock_recv_bitmap_test_byte_offset

2018-02-28 Thread Peter Xu
On Fri, Feb 16, 2018 at 01:16:09PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Utility for testing the map when you already know the offset > in the RAMBlock. > > Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Peter Xu > --- > migration/ram.c | 5

Re: [Qemu-devel] [PATCH 03/14] qio: introduce qio_channel_add_watch_full()

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 01:06:22PM +0800, Peter Xu wrote: > It's a more powerful version of qio_channel_add_watch(), which supports > non-default gcontext. It's stripped from the old one, then we have > g_source_get_id() to fetch the tag ID to keep the old interface. > > Note that the new API wil

Re: [Qemu-devel] [PATCH 04/14] migration: let incoming side use thread context

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 01:06:23PM +0800, Peter Xu wrote: > The old incoming migration is running in main thread and default > gcontext. With the new qio_channel_add_watch_full() we can now let it > run in the thread's own gcontext (if there is one). > > Currently this patch does nothing alone.

Re: [Qemu-devel] [PATCH 10/14] qio: refcount QIOTask

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 01:06:29PM +0800, Peter Xu wrote: > It will be used in multiple threads in follow-up patches. Let it start > to have refcounts. > > Signed-off-by: Peter Xu > --- > include/io/task.h | 3 +++ > io/task.c | 23 ++- > 2 files changed, 25 inserti

Re: [Qemu-devel] [PATCH 11/14] qio/chardev: return QIOTask when connect async

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 01:06:30PM +0800, Peter Xu wrote: > Let qio_channel_socket_connect_async() return the created QIOTask object > for the async connection. In tcp chardev, cache that in SocketChardev > for further use. With the QIOTask refcount, this is pretty safe. Why do you want to retur

Re: [Qemu-devel] [PATCH 13/14] qio: allow threaded qiotask to switch contexts

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 01:06:32PM +0800, Peter Xu wrote: > This is the part of work to allow the QIOTask to use a different > gcontext rather than the default main gcontext, by providing > qio_task_context_set() API. > > We have done some work before on doing similar things to add non-default > g

Re: [Qemu-devel] [PATCH 07/14] qio/chardev: update net listener gcontext

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 01:06:26PM +0800, Peter Xu wrote: > TCP chardevs can be using QIO network listeners working in the > background when in listening mode. However the network listeners are > always running in main context. This can race with chardevs that are > running in non-main contexts.

Re: [Qemu-devel] [PATCH 01/14] chardev: fix leak in tcp_chr_telnet_init_io()

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 01:06:20PM +0800, Peter Xu wrote: > Need to free TCPChardevTelnetInit when session established. > > Since at it, switch to use G_SOURCE_* macros. > > Signed-off-by: Peter Xu > --- > chardev/char-socket.c | 10 +++--- > 1 file changed, 7 insertions(+), 3 deletions(-)

Re: [Qemu-devel] [PATCH 02/14] qio: rename qio_task_thread_result

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 01:06:21PM +0800, Peter Xu wrote: > It is strange that it was called gio_task_thread_result. Rename it to > follow the naming rule of the file. > > Signed-off-by: Peter Xu > --- > io/task.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) Reviewed-by: Daniel

[Qemu-devel] [PATCH] hw/i386: make IOMMUs configurable via default-configs/

2018-02-28 Thread Paolo Bonzini
Allow distributions to disable the Intel and/or AMD IOMMU devices. Signed-off-by: Paolo Bonzini --- default-configs/i386-softmmu.mak | 2 ++ default-configs/x86_64-softmmu.mak | 2 ++ hw/i386/Makefile.objs | 5 +++-- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/d

Re: [Qemu-devel] [RFC QEMU PATCH v4 00/10] Implement vNVDIMM for Xen HVM guest

2018-02-28 Thread Haozhong Zhang
On 02/27/18 17:22 +, Anthony PERARD wrote: > On Thu, Dec 07, 2017 at 06:18:02PM +0800, Haozhong Zhang wrote: > > This is the QEMU part patches that works with the associated Xen > > patches to enable vNVDIMM support for Xen HVM domains. Xen relies on > > QEMU to build guest NFIT and NVDIMM name

Re: [Qemu-devel] [Qemu-block] [PATCH] vl: introduce vm_shutdown()

2018-02-28 Thread Stefan Hajnoczi
On Wed, Feb 28, 2018 at 09:58:13AM +0800, Fam Zheng wrote: > On Tue, 02/27 15:30, Stefan Hajnoczi wrote: > > On Fri, Feb 23, 2018 at 04:20:44PM +0800, Fam Zheng wrote: > > > On Tue, 02/20 13:10, Stefan Hajnoczi wrote: > > > > 1. virtio_scsi_handle_cmd_vq() racing with iothread_stop_all() hits the >

Re: [Qemu-devel] [PATCH v2 RFC] scripts/checkpatch.pl: add check for `while` and `for`

2018-02-28 Thread Stefan Hajnoczi
On Tue, Feb 27, 2018 at 05:42:50PM +, Peter Maydell wrote: > On 27 February 2018 at 17:32, Stefan Hajnoczi wrote: > > On Mon, Feb 26, 2018 at 10:53:18AM +0800, Su Hang wrote: > >> diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl > >> index 1b4b812e28fa..10c138344fa9 100755 > >> --- a

Re: [Qemu-devel] [PATCH v3 17/29] vhost+postcopy: Send requests to source for shared pages

2018-02-28 Thread Peter Xu
On Fri, Feb 16, 2018 at 01:16:13PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Send requests back to the source for shared page requests. > > Signed-off-by: Dr. David Alan Gilbert > --- > migration/migration.h| 2 ++ > migration/postcopy-ram.c | 31

Re: [Qemu-devel] [PATCH v4 2/5] qcow2: Document some maximum size constraints

2018-02-28 Thread Alberto Garcia
On Tue 27 Feb 2018 05:29:41 PM CET, Eric Blake wrote: > +The refcount table has implications on the maximum host file size; a > +larger cluster size is required for the refcount table to cover > larger +offsets. Why is this? Because of the refcount_table_clusters field ? I think the maximum offse

Re: [Qemu-devel] [PATCH v2 5/5] s390x/cpumodel: Set up CPU model for AP device support

2018-02-28 Thread David Hildenbrand
> KVM detects whether the AP instructions are installed on the host. If > the instructions are installed, the feature is allowed (enabled) and > can be turned on by userspace (QEMU). As mentioned in the KVM thread, I'd like to verify if there is not a AP interpretation facility. >> >> IOW: is thi

Re: [Qemu-devel] [PATCH v2 5/5] s390x/cpumodel: Set up CPU model for AP device support

2018-02-28 Thread David Hildenbrand
> The ap_bus has a function for determining if the ap instructions are > installed. I think it's basically trial execution. > Okay, just like CMM. Bad system design. But it is what it is. >> > > I think it's best modeled with a CPU model feature. In the end > it's about having or not having ap

Re: [Qemu-devel] [PATCH v2 3/3] virtio-balloon: add a timer to limit the free page report waiting time

2018-02-28 Thread Wei Wang
On 02/27/2018 09:08 PM, Liang Li wrote: On Tue, Feb 27, 2018 at 06:10:47PM +0800, Wei Wang wrote: On 02/27/2018 08:50 AM, Michael S. Tsirkin wrote: On Mon, Feb 26, 2018 at 12:35:31PM +0800, Wei Wang wrote: On 02/09/2018 08:15 PM, Dr. David Alan Gilbert wrote: * Wei Wang (wei.w.w...@intel.com)

Re: [Qemu-devel] [PATCH v2 3/3] virtio-balloon: add a timer to limit the free page report waiting time

2018-02-28 Thread Wei Wang
On 02/27/2018 06:34 PM, Dr. David Alan Gilbert wrote: * Wei Wang (wei.w.w...@intel.com) wrote: On 02/09/2018 08:15 PM, Dr. David Alan Gilbert wrote: * Wei Wang (wei.w.w...@intel.com) wrote: This patch adds a timer to limit the time that host waits for the free page hints reported by the guest.

Re: [Qemu-devel] Deprecate tilegx ?

2018-02-28 Thread Thomas Huth
On 28.02.2018 08:17, Paolo Bonzini wrote: > On 28/02/2018 07:11, Thomas Huth wrote: >> On 27.02.2018 12:51, Peter Maydell wrote: >>> I propose that we deprecate and plan to remove the unicore32 code: >> [...] >>> Essentially, it seems to be a largely-inactive university R&D project, >>> it's costin

Re: [Qemu-devel] [patches] Re: [PULL] RISC-V QEMU Port Submission

2018-02-28 Thread Igor Mammedov
On Wed, 28 Feb 2018 13:41:25 +1300 Michael Clark wrote: > On Wed, Feb 28, 2018 at 5:00 AM, Igor Mammedov wrote: > > > On Tue, 27 Feb 2018 14:01:05 + > > Peter Maydell wrote: > > > > > On 27 February 2018 at 00:15, Michael Clark wrote: > > > > -BEGIN PGP SIGNED MESSAGE- > > > >

[Qemu-devel] [PATCH v3 2/4] target/arm: Add "_S" suffix to the secure version of a sysreg

2018-02-28 Thread Abdallah Bouassida
This is a preparation for the coming feature of creating dynamically an XML description for the ARM sysregs. Add "_S" suffix to the secure version of sysregs that have both S and NS views Replace (S) and (NS) by _S and _NS for the register that are manually defined, so all the registers follow the

[Qemu-devel] [PATCH v3 1/4] target/arm: Add "ARM_CP_NO_GDB" as a new bit field for ARMCPRegInfo type

2018-02-28 Thread Abdallah Bouassida
This is a preparation for the coming feature of creating dynamically an XML description for the ARM sysregs. A register has ARM_CP_NO_GDB enabled will not be shown in the dynamic XML. This bit is enabled automatically when creating CP_ANY wildcard aliases. This bit could be enabled manually for any

[Qemu-devel] [PATCH v3 4/4] target/arm: Add arm_gdb_set_sysreg() callback

2018-02-28 Thread Abdallah Bouassida
This is a callback to set the cp-regs registered by the dynamic XML. Signed-off-by: Abdallah Bouassida --- >> Some of our customers need to connect to Qemu using our tool TRACE32® >> via GDB, >> and for some use case they need to have write access to some particular >> cpregs. >> So, it will be

[Qemu-devel] [PATCH v3 0/4] target/arm: Add a dynamic XML-description of the cp-registers to GDB

2018-02-28 Thread Abdallah Bouassida
The last exchange: https://lists.gnu.org/archive/html/qemu-devel/2018-02/msg03618.html - Add a new "ARM_CP_NO_GDB" bit field and enable it when creating CP_ANY wildcard aliases. - Add "_S" suffix to the secure version of a sysreg and fix the reg names that were manually containing (S) or (NS).

[Qemu-devel] [PATCH v3 3/4] target/arm: Add the XML dynamic generation

2018-02-28 Thread Abdallah Bouassida
Generate an XML description for the cp-regs. Register these regs with the gdb_register_coprocessor(). Add arm_gdb_get_sysreg() to use it as a callback to read those regs. Signed-off-by: Abdallah Bouassida --- gdbstub.c| 7 include/qom/cpu.h| 9 - target/arm/cpu.c |

Re: [Qemu-devel] [qemu-s390x] [PATCH] hw/s390x: Add the possibility to specify the netboot image on the command line

2018-02-28 Thread David Hildenbrand
On 27.02.2018 12:32, Thomas Huth wrote: > The file name of the netboot binary is currently hard-coded to > "s390-netboot.img", without a possibility for the user to select > an alternative firmware image here. That's unfortunate, especially > since the basics are already there: The filename is a pr

Re: [Qemu-devel] [PULL 00/12] Ui 20180227 patches

2018-02-28 Thread Peter Maydell
On 28 February 2018 at 06:26, Gerd Hoffmann wrote: > Hi, > >> Hi. This failed to build on my OpenBSD test box: >> >> CC qga/guest-agent-command-state.o >> In file included from /home/qemu/include/qemu/osdep.h:30:0, >> from /home/qemu/qga/guest-agent-command-state.c:12: >>

Re: [Qemu-devel] [PATCH v2 5/5] s390x/cpumodel: Set up CPU model for AP device support

2018-02-28 Thread Cornelia Huck
On Wed, 28 Feb 2018 11:26:30 +0100 David Hildenbrand wrote: > Then I request the following change in KVM: > > If KVM_S390_VM_CPU_FEAT_AP is enabled in KVM, ECA.28 is _always_ set > (not just if an AP device is configured). This especially makes things a > lot easier when it comes to handling hot

Re: [Qemu-devel] [PATCH] i386: Allow monitor / mwait cpuid override

2018-02-28 Thread Paolo Bonzini
On 28/02/2018 00:55, Alexander Graf wrote: > > > On 27.02.18 10:52, Gonglei (Arei) wrote: >> Hi all, >> >> Guests could achive good performance in 'Message Passing Workloads' >> scenarios when knowing the X86_FEATURE_MWAIT feature which is presented by >> qemu. >> the reason is that after know

Re: [Qemu-devel] [patches] Re: [PULL] RISC-V QEMU Port Submission

2018-02-28 Thread Peter Maydell
On 28 February 2018 at 00:09, Michael Clark wrote: > I've just talked to SiFive about this. They have agreed that we can remove > the sifive_e300 and sifive_u500 boards from the patch series that we are > going to submit upstream again later this week or early next week. These > machines and their

Re: [Qemu-devel] [patches] Re: [PULL] RISC-V QEMU Port Submission

2018-02-28 Thread Peter Maydell
On 28 February 2018 at 11:53, Peter Maydell wrote: > With my 'upstream dev' hat on, I tend to be suspicious of this > line of argument, because in a lot of cases what tends to happen > is that the code for some new target or device goes in-tree, and > then the people who worked on submitting it di

[Qemu-devel] [PULL 11/11] curses: build as ui module

2018-02-28 Thread Gerd Hoffmann
Also drop curses libs from libs_softmmu. Add CURSES_{CFLAGS,LIBS} variables so we can use them for linking the curses module. Shared library dependencies dropped from qemu-system-*: libncursesw.so.5 => /lib64/libncursesw.so.5 libtinfo.so.5 => /lib64/libtinfo.so.5 Signed-off-by: Gerd Hoffmann M

[Qemu-devel] [PULL 06/11] console: add and use qemu_display_find_default

2018-02-28 Thread Gerd Hoffmann
Using the new display registry instead of #ifdefs in vl.c. Signed-off-by: Gerd Hoffmann Message-id: 20180221131537.31341-7-kra...@redhat.com --- include/ui/console.h | 1 + ui/console.c | 19 +++ vl.c | 15 +-- 3 files changed, 25 insertions(+

[Qemu-devel] [PULL 04/11] curses: switch over to new display registry

2018-02-28 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann Message-id: 20180221131537.31341-5-kra...@redhat.com --- include/ui/console.h | 12 ui/curses.c | 14 +- vl.c | 17 ++--- 3 files changed, 15 insertions(+), 28 deletions(-) diff --git a/include/ui/console.

[Qemu-devel] [PULL 05/11] egl-headless: switch over to new display registry

2018-02-28 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann Message-id: 20180221131537.31341-6-kra...@redhat.com --- include/ui/console.h | 3 --- ui/egl-headless.c| 20 +++- vl.c | 12 3 files changed, 19 insertions(+), 16 deletions(-) diff --git a/include/ui/console.h b/incl

[Qemu-devel] [PULL 02/11] sdl: switch over to new display registry

2018-02-28 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann Message-id: 20180221131537.31341-3-kra...@redhat.com --- include/ui/console.h | 19 --- ui/sdl.c | 24 +--- ui/sdl2.c| 17 +++-- vl.c | 15 +-- 4 files changed, 29 inse

[Qemu-devel] [PULL 03/11] cocoa: switch over to new display registry

2018-02-28 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann Message-id: 20180221131537.31341-4-kra...@redhat.com --- include/ui/console.h | 12 vl.c | 3 --- ui/cocoa.m | 14 +- 3 files changed, 13 insertions(+), 16 deletions(-) diff --git a/include/ui/console.h b/include/ui

[Qemu-devel] [PULL 08/11] configure: add X11 vars to config-host.mak

2018-02-28 Thread Gerd Hoffmann
Simplifies handling the X11 dependency, also makes ui/Makefile.objs more readable. Signed-off-by: Gerd Hoffmann Message-id: 20180221131537.31341-9-kra...@redhat.com --- configure| 10 -- ui/Makefile.objs | 5 - 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/

[Qemu-devel] [PULL 10/11] gtk: build as ui module

2018-02-28 Thread Gerd Hoffmann
Also drop gtk and vte libs from libs_softmmu, so the libs are not pulled in unless the gtk module actually gets loaded. Shared library dependencies dropped from qemu-system-*: libEGL.so.1 => /lib64/libEGL.so.1 libGL.so.1 => /lib64/libGL.so.1 libXcomposite.so.1 => /lib64/libXcomposite.so.1 libXcur

[Qemu-devel] [PULL 07/11] console: add ui module loading support

2018-02-28 Thread Gerd Hoffmann
If a requested user interface is not available, try loading it as module, simliar to block layer modules. Needed to keep things working when followup patches start to build user interfaces as modules. Signed-off-by: Gerd Hoffmann Message-id: 20180221131537.31341-8-kra...@redhat.com --- include/

[Qemu-devel] [PULL 09/11] configure: opengl doesn't depend on x11

2018-02-28 Thread Gerd Hoffmann
So remove x11 from pkg-config check and don't add x11 cflags/libs to opengl cflags/libs. Signed-off-by: Gerd Hoffmann Message-id: 20180221131537.31341-10-kra...@redhat.com --- configure | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/configure b/configure index f6dc1c92

Re: [Qemu-devel] [PATCH v4 3/5] qcow2: Reduce REFT_OFFSET_MASK

2018-02-28 Thread Alberto Garcia
On Tue 27 Feb 2018 05:29:42 PM CET, Eric Blake wrote: > Match our code to the spec change in the previous patch - there's > no reason for the refcount table to allow larger offsets than the > L1/L2 tables. In practice, no image has more than 64PB of > allocated clusters anyways, as anything beyond

[Qemu-devel] [PULL 00/11] Ui 20180228 patches

2018-02-28 Thread Gerd Hoffmann
The following changes since commit 0a773d55ac76c5aa89ed9187a3bc5af8c5c2a6d0: maintainers: Add myself as a OpenBSD maintainer (2018-02-23 12:05:07 +) are available in the git repository at: git://git.kraxel.org/qemu tags/ui-20180228-pull-request for you to fetch changes up to

[Qemu-devel] [PULL 01/11] console: add qemu display registry, add gtk

2018-02-28 Thread Gerd Hoffmann
Add a registry for user interfaces. Add qemu_display_init and qemu_display_early_init helper functions for display initialization. Hook up gtk ui as first user. Signed-off-by: Gerd Hoffmann Message-id: 20180221131537.31341-2-kra...@redhat.com --- include/ui/console.h | 32 -

Re: [Qemu-devel] [PATCH] i386: Allow monitor / mwait cpuid override

2018-02-28 Thread Wanpeng Li
On 2/28/18 7:50 PM, Paolo Bonzini wrote: > On 28/02/2018 00:55, Alexander Graf wrote: >> >> On 27.02.18 10:52, Gonglei (Arei) wrote: >>> Hi all, >>> >>> Guests could achive good performance in 'Message Passing Workloads' >>> scenarios when knowing the X86_FEATURE_MWAIT feature which is presented b

Re: [Qemu-devel] [PULL 00/12] Ui 20180227 patches

2018-02-28 Thread Gerd Hoffmann
> > I think modularizing SDL isn't that easy then. > > Can you just drop the "sdl: build as ui module" patch? > > I can't drop patches from signed pull requests -- you need > to respin it. Ah, right, that would invalidate the signature. Pull resent. cheers, Gerd

Re: [Qemu-devel] [PATCH v3 4/4] target/arm: Add arm_gdb_set_sysreg() callback

2018-02-28 Thread Peter Maydell
On 28 February 2018 at 11:01, Abdallah Bouassida wrote: > This is a callback to set the cp-regs registered by the dynamic XML. > > Signed-off-by: Abdallah Bouassida > --- >>> Some of our customers need to connect to Qemu using our tool TRACE32® >>> via GDB, >>> and for some use case they need to

Re: [Qemu-devel] [qemu-s390x] [PATCH] hw/s390x: Add the possibility to specify the netboot image on the command line

2018-02-28 Thread Thomas Huth
On 28.02.2018 12:02, David Hildenbrand wrote: > On 27.02.2018 12:32, Thomas Huth wrote: >> The file name of the netboot binary is currently hard-coded to >> "s390-netboot.img", without a possibility for the user to select >> an alternative firmware image here. That's unfortunate, especially >> sinc

[Qemu-devel] [PATCH v6 7/9] vfio/display: core & wireup

2018-02-28 Thread Gerd Hoffmann
Infrastructure for display support. Must be enabled using 'display' property. Signed-off-by: Gerd Hoffmann --- hw/vfio/pci.h | 4 hw/vfio/display.c | 56 +++ hw/vfio/pci.c | 10 + hw/vfio/Makefile.objs | 2 +- 4

[Qemu-devel] [PATCH v6 3/9] ui/pixman: add qemu_drm_format_to_pixman()

2018-02-28 Thread Gerd Hoffmann
Map drm fourcc codes to pixman formats. Signed-off-by: Gerd Hoffmann --- include/ui/qemu-pixman.h | 5 + ui/qemu-pixman.c | 22 ++ 2 files changed, 27 insertions(+) diff --git a/include/ui/qemu-pixman.h b/include/ui/qemu-pixman.h index 4a67e01232..b7c82d17fc 100

Re: [Qemu-devel] [PATCH v2] target-i386: add KVM_HINTS_DEDICATED performance hint

2018-02-28 Thread Wanpeng Li
Ping, 2018-02-09 22:15 GMT+08:00 Wanpeng Li : > From: Wanpeng Li > > Add KVM_HINTS_DEDICATED performance hint, guest checks this feature bit > to determine if they run on dedicated vCPUs, allowing optimizations such > as usage of qspinlocks. > > Cc: Paolo Bonzini > Cc: Radim Krčmář > Cc: Eduardo

[Qemu-devel] [PATCH v6 6/9] vfio/common: cleanup in vfio_region_finalize

2018-02-28 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/vfio/common.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/hw/vfio/common.c b/hw/vfio/common.c index f895e3c335..6a8203a532 100644 --- a/hw/vfio/common.c +++ b/hw/vfio/common.c @@ -858,6 +858,13 @@ void vfio_region_finalize(VFIORegion *region)

[Qemu-devel] [PATCH v6 8/9] vfio/display: adding region support

2018-02-28 Thread Gerd Hoffmann
Wire up region-based display. Signed-off-by: Gerd Hoffmann --- hw/vfio/pci.h | 1 + include/hw/vfio/vfio-common.h | 8 +++ hw/vfio/display.c | 116 +- 3 files changed, 123 insertions(+), 2 deletions(-) diff --git a/hw/vfio/

[Qemu-devel] [PATCH v6 4/9] console: minimal hotplug suport

2018-02-28 Thread Gerd Hoffmann
This patch allows to unbind devices from QemuConsoles, using the new graphic_console_close() function. The QemuConsole will show a static display then, saying the device was unplugged. When re-plugging a display later on the QemuConsole will be reused. Eventually we will allocate and release Qem

[Qemu-devel] [PATCH v6 9/9] vfio/display: adding dmabuf support

2018-02-28 Thread Gerd Hoffmann
Wire up dmabuf-based display. Signed-off-by: Gerd Hoffmann --- include/hw/vfio/vfio-common.h | 14 hw/vfio/display.c | 166 +- 2 files changed, 178 insertions(+), 2 deletions(-) diff --git a/include/hw/vfio/vfio-common.h b/include/hw/vfi

[Qemu-devel] [PATCH v6 2/9] standard-headers: add drm/drm_fourcc.h

2018-02-28 Thread Gerd Hoffmann
So we can use the drm fourcc codes without a dependency on libdrm-devel. Signed-off-by: Gerd Hoffmann --- include/standard-headers/drm/drm_fourcc.h | 411 ++ scripts/update-linux-headers.sh | 4 + 2 files changed, 415 insertions(+) create mode 100644 incl

[Qemu-devel] [PATCH v6 1/9] linux-headers: update to 4.16-rc1

2018-02-28 Thread Gerd Hoffmann
s390 has splitted syscall numbers into unistd_{32,64}.h files, so update scripts/update-linux-headers.sh accordingly. Also add a rewrite from __BITS_PER_LONG to HOST_LONG_BITS for linux/input.h Signed-off-by: Gerd Hoffmann --- include/standard-headers/linux/input-event-codes.h | 1 + include/

[Qemu-devel] [PATCH v6 0/9] vfio: add display support

2018-02-28 Thread Gerd Hoffmann
This series adds support for a vgpu display to the qemu vfio code. v6: - add support for hotplugging QemuConsoles. - drop vfio-pci-display device, re-add OnOffAuto display property. - add proper cleanup in finalize. v5: - rebase to latest master - drop DeviceState->hotpluggable patch, use se

[Qemu-devel] [PATCH v6 5/9] secondary-vga: properly close QemuConsole on unplug

2018-02-28 Thread Gerd Hoffmann
Using the new graphic_console_close() function. Signed-off-by: Gerd Hoffmann --- hw/display/vga-pci.c | 9 + 1 file changed, 9 insertions(+) diff --git a/hw/display/vga-pci.c b/hw/display/vga-pci.c index 1674bd3581..f312930664 100644 --- a/hw/display/vga-pci.c +++ b/hw/display/vga-pci.c

Re: [Qemu-devel] Deprecate tilegx ?

2018-02-28 Thread Bastian Koppelmann
On 02/28/2018 07:11 AM, Thomas Huth wrote: > On 27.02.2018 12:51, Peter Maydell wrote: >> I propose that we deprecate and plan to remove the unicore32 code: > [...] [...] > > Sounds reasonable to me, but let's wait a week or two for feedback from > Guan Xuetao. Agreed. > >> Possibly there are o

Re: [Qemu-devel] [PATCH 0/5] Versatile Express SiI9022 emulation

2018-02-28 Thread Linus Walleij
On Tue, Feb 27, 2018 at 6:26 PM, Peter Maydell wrote: > On 27 February 2018 at 10:48, Linus Walleij wrote: >> This series adds proper display bridge/connector emulation >> for the Versatile Express, implementing a simple Silicon >> Image 9022 emulation spawning a DDC I2C child. >> >> After the se

Re: [Qemu-devel] [PATCH 03/14] qio: introduce qio_channel_add_watch_full()

2018-02-28 Thread Peter Xu
On Wed, Feb 28, 2018 at 09:08:45AM +, Daniel P. Berrangé wrote: > On Wed, Feb 28, 2018 at 01:06:22PM +0800, Peter Xu wrote: > > It's a more powerful version of qio_channel_add_watch(), which supports > > non-default gcontext. It's stripped from the old one, then we have > > g_source_get_id() t

Re: [Qemu-devel] [PATCH 03/14] qio: introduce qio_channel_add_watch_full()

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 08:44:24PM +0800, Peter Xu wrote: > On Wed, Feb 28, 2018 at 09:08:45AM +, Daniel P. Berrangé wrote: > > On Wed, Feb 28, 2018 at 01:06:22PM +0800, Peter Xu wrote: > > > It's a more powerful version of qio_channel_add_watch(), which supports > > > non-default gcontext. It

Re: [Qemu-devel] [PATCH v6 0/9] vfio: add display support

2018-02-28 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20180228123110.6507-1-kra...@redhat.com Subject: [Qemu-devel] [PATCH v6 0/9] vfio: add display support === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1 total=$(git log --

Re: [Qemu-devel] [PATCH 07/14] qio/chardev: update net listener gcontext

2018-02-28 Thread Peter Xu
On Wed, Feb 28, 2018 at 09:25:11AM +, Daniel P. Berrangé wrote: > On Wed, Feb 28, 2018 at 01:06:26PM +0800, Peter Xu wrote: > > TCP chardevs can be using QIO network listeners working in the > > background when in listening mode. However the network listeners are > > always running in main con

Re: [Qemu-devel] [PATCH 10/14] qio: refcount QIOTask

2018-02-28 Thread Peter Xu
On Wed, Feb 28, 2018 at 09:16:59AM +, Daniel P. Berrangé wrote: > On Wed, Feb 28, 2018 at 01:06:29PM +0800, Peter Xu wrote: > > It will be used in multiple threads in follow-up patches. Let it start > > to have refcounts. > > > > Signed-off-by: Peter Xu > > --- > > include/io/task.h | 3 ++

Re: [Qemu-devel] [PATCH 03/14] qio: introduce qio_channel_add_watch_full()

2018-02-28 Thread Peter Xu
On Wed, Feb 28, 2018 at 12:47:43PM +, Daniel P. Berrangé wrote: > On Wed, Feb 28, 2018 at 08:44:24PM +0800, Peter Xu wrote: > > On Wed, Feb 28, 2018 at 09:08:45AM +, Daniel P. Berrangé wrote: > > > On Wed, Feb 28, 2018 at 01:06:22PM +0800, Peter Xu wrote: > > > > It's a more powerful versio

Re: [Qemu-devel] [PATCH 13/14] qio: allow threaded qiotask to switch contexts

2018-02-28 Thread Peter Xu
On Wed, Feb 28, 2018 at 09:23:56AM +, Daniel P. Berrangé wrote: > On Wed, Feb 28, 2018 at 01:06:32PM +0800, Peter Xu wrote: > > This is the part of work to allow the QIOTask to use a different > > gcontext rather than the default main gcontext, by providing > > qio_task_context_set() API. > >

Re: [Qemu-devel] [PATCH 07/14] qio/chardev: update net listener gcontext

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 08:52:16PM +0800, Peter Xu wrote: > On Wed, Feb 28, 2018 at 09:25:11AM +, Daniel P. Berrangé wrote: > > On Wed, Feb 28, 2018 at 01:06:26PM +0800, Peter Xu wrote: > > > TCP chardevs can be using QIO network listeners working in the > > > background when in listening mode.

Re: [Qemu-devel] [PATCH 11/14] qio/chardev: return QIOTask when connect async

2018-02-28 Thread Peter Xu
On Wed, Feb 28, 2018 at 09:20:47AM +, Daniel P. Berrangé wrote: > On Wed, Feb 28, 2018 at 01:06:30PM +0800, Peter Xu wrote: > > Let qio_channel_socket_connect_async() return the created QIOTask object > > for the async connection. In tcp chardev, cache that in SocketChardev > > for further use

Re: [Qemu-devel] [PATCH 10/14] qio: refcount QIOTask

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 08:54:00PM +0800, Peter Xu wrote: > On Wed, Feb 28, 2018 at 09:16:59AM +, Daniel P. Berrangé wrote: > > On Wed, Feb 28, 2018 at 01:06:29PM +0800, Peter Xu wrote: > > > It will be used in multiple threads in follow-up patches. Let it start > > > to have refcounts. > > >

Re: [Qemu-devel] [Nbd] [PATCH] Further tidy-up on block status

2018-02-28 Thread Wouter Verhelst
Hi, Sorry, I forgot to reply to this earlier. On Fri, Feb 16, 2018 at 10:10:59AM -0600, Eric Blake wrote: > On 02/16/2018 07:53 AM, Vladimir Sementsov-Ogievskiy wrote: > > Good idea. But it would be tricky thing to maintain backward > > compatibility with published versions of virtuozzo product.

[Qemu-devel] [PATCH 2/2] iotests: Test preallocated truncate of 2G image

2018-02-28 Thread Max Reitz
Signed-off-by: Max Reitz --- tests/qemu-iotests/106 | 24 tests/qemu-iotests/106.out | 10 ++ 2 files changed, 34 insertions(+) diff --git a/tests/qemu-iotests/106 b/tests/qemu-iotests/106 index bfe71f4e60..5e51f88a78 100755 --- a/tests/qemu-iotests/106 +++ b

[Qemu-devel] [PATCH 0/2] block/file-posix: Fix fully preallocated truncate

2018-02-28 Thread Max Reitz
Fully preallocated truncation has a 50 % chance of working on images files over file-posix. It works if $SIZE % 4G < 2G, and it fails otherwise. To make things even more interesting, often you would not even notice because qemu reported success even though it did nothing (because after the succes

[Qemu-devel] [PATCH 1/2] block/file-posix: Fix fully preallocated truncate

2018-02-28 Thread Max Reitz
Storing the lseek() result in an int results in it overflowing when the file is at least 2 GB big. Then, we have a 50 % chance of the result being "negative" and thus thinking an error occurred when actually everything went just fine. So we should use the correct type for storing the result: off_

Re: [Qemu-devel] [PATCH 10/14] qio: refcount QIOTask

2018-02-28 Thread Peter Xu
On Wed, Feb 28, 2018 at 01:07:44PM +, Daniel P. Berrangé wrote: > On Wed, Feb 28, 2018 at 08:54:00PM +0800, Peter Xu wrote: > > On Wed, Feb 28, 2018 at 09:16:59AM +, Daniel P. Berrangé wrote: > > > On Wed, Feb 28, 2018 at 01:06:29PM +0800, Peter Xu wrote: > > > > It will be used in multiple

Re: [Qemu-devel] [PATCH 13/14] qio: allow threaded qiotask to switch contexts

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 09:05:26PM +0800, Peter Xu wrote: > On Wed, Feb 28, 2018 at 09:23:56AM +, Daniel P. Berrangé wrote: > > On Wed, Feb 28, 2018 at 01:06:32PM +0800, Peter Xu wrote: > > > This is the part of work to allow the QIOTask to use a different > > > gcontext rather than the default

Re: [Qemu-devel] [PATCH 14/14] qio/chardev: specify gcontext for TLS handshake

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 01:06:33PM +0800, Peter Xu wrote: > We allow the TLS code to be run with non-default gcontext by providing a > new qio_channel_tls_handshake_full() API. > > With the new API, we can re-setup the TLS handshake GSource by calling > it again with the correct gcontext. Any cal

Re: [Qemu-devel] [Qemu-arm] [PATCH v4 00/31] Add ARMv8.2 half-precision functions

2018-02-28 Thread Alex Bennée
Peter Maydell writes: > On 27 February 2018 at 14:38, Alex Bennée wrote: >> A few minor fixes and a chunk of Richard's r-b tags. Now all that is >> left is: >> >> patch 0014/arm translate a64 add FP16 FMULX MLS FMLA to simd.patch needs >> review >> >> Otherwise see comments bellow --- for ot

[Qemu-devel] [PATCH] fw_cfg: avoid unused function warning

2018-02-28 Thread Arnd Bergmann
The newly introduced fw_cfg_dma_transfer() function is unused when CONFIG_CRASH_CORE is disabled: drivers/firmware/qemu_fw_cfg.c:89:16: error: 'fw_cfg_dma_transfer' defined but not used [-Werror=unused-function] static ssize_t fw_cfg_dma_transfer(void *address, u32 length, u32 control) This mov

Re: [Qemu-devel] [PATCH 1/2] block/file-posix: Fix fully preallocated truncate

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 02:13:14PM +0100, Max Reitz wrote: > Storing the lseek() result in an int results in it overflowing when the > file is at least 2 GB big. Then, we have a 50 % chance of the result > being "negative" and thus thinking an error occurred when actually > everything went just fi

Re: [Qemu-devel] [PATCH 1/2] block/file-posix: Fix fully preallocated truncate

2018-02-28 Thread Max Reitz
On 2018-02-28 14:34, Daniel P. Berrangé wrote: > On Wed, Feb 28, 2018 at 02:13:14PM +0100, Max Reitz wrote: >> Storing the lseek() result in an int results in it overflowing when the >> file is at least 2 GB big. Then, we have a 50 % chance of the result >> being "negative" and thus thinking an er

Re: [Qemu-devel] [PATCH 1/2] block/file-posix: Fix fully preallocated truncate

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 02:45:49PM +0100, Max Reitz wrote: > On 2018-02-28 14:34, Daniel P. Berrangé wrote: > > On Wed, Feb 28, 2018 at 02:13:14PM +0100, Max Reitz wrote: > >> Storing the lseek() result in an int results in it overflowing when the > >> file is at least 2 GB big. Then, we have a 50

Re: [Qemu-devel] [PATCH 1/2] block/file-posix: Fix fully preallocated truncate

2018-02-28 Thread Max Reitz
On 2018-02-28 14:53, Daniel P. Berrangé wrote: > On Wed, Feb 28, 2018 at 02:45:49PM +0100, Max Reitz wrote: >> On 2018-02-28 14:34, Daniel P. Berrangé wrote: >>> On Wed, Feb 28, 2018 at 02:13:14PM +0100, Max Reitz wrote: Storing the lseek() result in an int results in it overflowing when the >

Re: [Qemu-devel] [PATCH 1/2] block/file-posix: Fix fully preallocated truncate

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 02:13:14PM +0100, Max Reitz wrote: > Storing the lseek() result in an int results in it overflowing when the > file is at least 2 GB big. Then, we have a 50 % chance of the result > being "negative" and thus thinking an error occurred when actually > everything went just fi

Re: [Qemu-devel] [PATCH 1/2] block/file-posix: Fix fully preallocated truncate

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 02:55:22PM +0100, Max Reitz wrote: > On 2018-02-28 14:53, Daniel P. Berrangé wrote: > > On Wed, Feb 28, 2018 at 02:45:49PM +0100, Max Reitz wrote: > >> On 2018-02-28 14:34, Daniel P. Berrangé wrote: > >>> On Wed, Feb 28, 2018 at 02:13:14PM +0100, Max Reitz wrote: > Stor

Re: [Qemu-devel] [PATCH v4 2/5] qcow2: Document some maximum size constraints

2018-02-28 Thread Eric Blake
On 02/28/2018 04:26 AM, Alberto Garcia wrote: On Tue 27 Feb 2018 05:29:41 PM CET, Eric Blake wrote: +The refcount table has implications on the maximum host file size; a +larger cluster size is required for the refcount table to cover larger +offsets. Why is this? Because of the refcount_table

Re: [Qemu-devel] [PATCH 2/2] iotests: Test preallocated truncate of 2G image

2018-02-28 Thread Daniel P . Berrangé
On Wed, Feb 28, 2018 at 02:13:15PM +0100, Max Reitz wrote: > Signed-off-by: Max Reitz > --- > tests/qemu-iotests/106 | 24 > tests/qemu-iotests/106.out | 10 ++ > 2 files changed, 34 insertions(+) > > diff --git a/tests/qemu-iotests/106 b/tests/qemu-iotests/1

[Qemu-devel] [PATCH] crypto: ensure we use a predictable TLS priority setting

2018-02-28 Thread Daniel P . Berrangé
The TLS test cert generation relies on a fixed set of algorithms that are only usable under GNUTLS' default priority setting. When building QEMU with a custom distro specific priority setting, this can cause the TLS tests to fail. By forcing the tests to always use "NORMAL" priority we can make the

Re: [Qemu-devel] [PATCH v2 05/16] block/mirror: Convert to coroutines

2018-02-28 Thread Max Reitz
On 2018-02-27 08:44, Fam Zheng wrote: > On Mon, 01/22 23:07, Max Reitz wrote: >> @@ -101,7 +105,7 @@ static BlockErrorAction >> mirror_error_action(MirrorBlockJob *s, bool read, >> } >> } >> >> -static void mirror_iteration_done(MirrorOp *op, int ret) >> +static void coroutine_fn mirror_it

  1   2   3   4   >