Re: [Qemu-devel] [PATCH v2 0/4] Updates based on feedback.

2018-01-29 Thread Stefan Hajnoczi
On Thu, Jan 25, 2018 at 08:12:57PM +, Justin Terry (VM) via Qemu-devel wrote: > I have only tried Ubuntu and Windows guests. Is there a set you would > recommend to try out? > > As for limitations, this set of patches allows for both bios and efi based > boots (we have been using TianoCore)

Re: [Qemu-devel] Help regarding configuring qemu with '--enable-ptnetmap' option

2018-01-29 Thread Stefan Hajnoczi
On Tue, Jan 16, 2018 at 02:47:41PM +0530, sagart wrote: > Hello, > I am trying to configure qemu with ptnet. But it seems like, now there is > no 'ptnet' branch to checkout, > so I am unable to configure using '--enable-ptnetmap' option. > please help in this regard. Please ask the author of the

[Qemu-devel] [PATCH v3 0/2] virtio: improve virtio devices initialization time

2018-01-29 Thread Gal Hammer
Using a cleanup callback function (Version 2 of this patches) in order to support transactions fails when the same event notifier fd was used by more than one Memory Region. This time I ask the caller to do the event notifier cleanup by himself. Gal Hammer (2): virtio: remove event notifier cle

[Qemu-devel] [PATCH v3 2/2] virtio: improve virtio devices initialization time

2018-01-29 Thread Gal Hammer
The loading time of a VM is quite significant when its virtio devices use a large amount of virt-queues (e.g. a virtio-serial device with max_ports=511). Most of the time is spend in the creation of all the required event notifiers (ioeventfd and memory regions). This patch pack all the changes to

Re: [Qemu-devel] [PATCH v3] hw/char: remove legacy interface escc_init()

2018-01-29 Thread Laurent Vivier
Paolo, I forgot to cc: you for the "MAINTAINERS/Character devices/Odd Fixes". Could you take this through your branch? Thanks, Laurent On 26/01/2018 16:41, Mark Cave-Ayland wrote: > On 26/01/18 14:47, Laurent Vivier wrote: > >> Move necessary stuff in escc.h and update type names. >> Remove sla

[Qemu-devel] [PATCH v3 1/2] virtio: remove event notifier cleanup call on de-assign

2018-01-29 Thread Gal Hammer
The virtio_bus_set_host_notifier function no longer calls event_notifier_cleanup when a event notifier is removed. The commit updates the code to match the new behavior and calls virtio_bus_cleanup_host_notifier after the notifier was de-assign and no longer in use. This change is a preparation t

Re: [Qemu-devel] [PATCH v3] tpm: add CRB device

2018-01-29 Thread Eric Blake
On 01/28/2018 07:38 AM, Stefan Berger wrote: > On 01/26/2018 08:19 AM, no-re...@patchew.org wrote: >> Hi, >> >> This series failed build test on s390x host. Please find the details >> below. > > We can ignore this and the other emails' errors since the patch's > dependencies are in my tpm-next tre

Re: [Qemu-devel] [qemu-s390x] [PATCH v4 08/10] s390-ccw: print zipl boot menu

2018-01-29 Thread Collin L. Walling
On 01/29/2018 05:15 AM, David Hildenbrand wrote: On 23.01.2018 19:26, Collin L. Walling wrote: When the boot menu options are present and the guest's disk has been configured by the zipl tool, then the user will be presented with an interactive boot menu with labeled entries. An example of what

Re: [Qemu-devel] [PULL 00/12] ppc-for-2.12 queue 20180129

2018-01-29 Thread Peter Maydell
> > are available in the Git repository at: > > git://github.com/dgibson/qemu.git tags/ppc-for-2.12-20180129 > > for you to fetch changes up to c59704b254734182c3202e0c261589ea2ccf485e: > > target/ppc/spapr: Add H-Call H_GET_

Re: [Qemu-devel] [PATCH 2/5] lockable: add QemuLockable

2018-01-29 Thread Paolo Bonzini
On 29/01/2018 12:42, Stefan Hajnoczi wrote: > On Thu, Jan 25, 2018 at 06:59:46PM +0100, Paolo Bonzini wrote: >> +struct QemuLockable { >> +void *object; >> +QemuLockUnlockFunc *lock; >> +QemuLockUnlockFunc *unlock; >> +}; > ... >> +/* In C, compound literals have the lifetime of an auto

Re: [Qemu-devel] [PATCH] docs: Add docs/devel/testing.rst

2018-01-29 Thread Eric Blake
On 01/29/2018 01:42 AM, Fam Zheng wrote: > On Mon, Jan 29, 2018 at 2:56 PM, Thomas Huth wrote: >> On 29.01.2018 04:31, Fam Zheng wrote: >> [...] >>> +1. Create a new source file. For example, ``tests/test-foo.c``. >> [...] >>> +1. Create a new source file for the test. (More than one file can be a

Re: [Qemu-devel] [qemu-s390x] [PATCH v4 09/10] s390-ccw: read user input for boot index via the SCLP console

2018-01-29 Thread Collin L. Walling
On 01/29/2018 08:08 AM, David Hildenbrand wrote: On 23.01.2018 19:26, Collin L. Walling wrote: Implements an sclp_read function to capture input from the console and a wrapper function that handles parsing certain characters and adding input to a buffer. The input is checked for any erroneous va

Re: [Qemu-devel] [PATCH] docs: Add docs/devel/testing.rst

2018-01-29 Thread Eric Blake
On 01/29/2018 05:04 AM, Stefan Hajnoczi wrote: > On Mon, Jan 29, 2018 at 11:31:33AM +0800, Fam Zheng wrote: > > Thanks for writing this! > > I have only reviewed some parts in detail. > >> + >> +On top of libqtest, a higher level library, ``libqos``, was created to >> +encapsulate common tasks

Re: [Qemu-devel] [PATCH] docs: Add docs/devel/testing.rst

2018-01-29 Thread Eric Blake
On 01/28/2018 09:31 PM, Fam Zheng wrote: > To make our efforts on QEMU testing easier to consume by contributors, > let's add a document. For example, Patchew reports build errors on > patches that should be relativly easy to reproduce with a few steps, and s/relativly/relatively/ > it is much ni

[Qemu-devel] [PATCH 1/2] tracetool: Update argument format regex to non-greedy star

2018-01-29 Thread Jon Emil Jahren
Using the greedy star matching, arguments like "...%"PRIx64 caused issues for functions with multiple PRI formats. The issue was only seen with the ust backend, as it is the only one using the format regex. The result for many functions was that the arguments coming after the greedy star end was

[Qemu-devel] [PATCH 0/2] tracetool: Fix ust tracepoint issues

2018-01-29 Thread Jon Emil Jahren
There are some issues with the argument parsing for ust. The first issue is that the regex pattern matching arguments with PRI types matched too much. This was fixed by using a non-greedy star, instead of a greedy. The second issue is that bool type is not recognized. This was fixed by adding the b

[Qemu-devel] [PATCH 2/2] tracetool: For ust trace bool type as ctf_integer

2018-01-29 Thread Jon Emil Jahren
Previously functions having arguments of type bool was not traced properly. The bool arguments were missing from the trace. Signed-off-by: Jon Emil Jahren --- scripts/tracetool/format/ust_events_h.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/tracetool/format/u

Re: [Qemu-devel] [PATCH 1/2] qemu-iotests: add missing rule to build socket_scm_helper

2018-01-29 Thread Max Reitz
On 2017-12-19 17:37, Philippe Mathieu-Daudé wrote: > 'make check-block' uses it on Linux. > > Signed-off-by: Philippe Mathieu-Daudé > --- > tests/Makefile.include | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/tests/Makefile.include b/tests/Makefile.include > index b4b

Re: [Qemu-devel] [PATCH 2/2] qemu-iotests: check socket_scm_helper is available

2018-01-29 Thread Max Reitz
On 2017-12-19 17:37, Philippe Mathieu-Daudé wrote: > This now throws a more helpful error message when not found: > > tests/qemu-iotests$ ./check 045 > QEMU -- "/qemu/build/x86_64-softmmu/qemu-system-x86_64" > -nodefaults -machine accel=qtest > QEMU_IMG -- "/qemu/build/qemu-im

Re: [Qemu-devel] [Qemu-block] [PATCH] hmp: Add nbd_server_remove to mirror QMP command

2018-01-29 Thread Kevin Wolf
Am 25.01.2018 um 15:45 hat Eric Blake geschrieben: > Since everything else about the nbd-server-* QMP commands is > accessible from HMP, we might as well make removing an export > available as well. For now, I went with a bool flag rather > than a mode string for choosing between safe (default) an

Re: [Qemu-devel] [qemu-s390x] [PATCH v4 09/10] s390-ccw: read user input for boot index via the SCLP console

2018-01-29 Thread Collin L. Walling
On 01/29/2018 05:07 AM, David Hildenbrand wrote: On 23.01.2018 19:26, Collin L. Walling wrote: Implements an sclp_read function to capture input from the console and a wrapper function that handles parsing certain characters and adding input to a buffer. The input is checked for any erroneous va

Re: [Qemu-devel] [qemu-s390x] [PATCH v4 09/10] s390-ccw: read user input for boot index via the SCLP console

2018-01-29 Thread David Hildenbrand
On 29.01.2018 15:38, Collin L. Walling wrote: > On 01/29/2018 08:08 AM, David Hildenbrand wrote: >> On 23.01.2018 19:26, Collin L. Walling wrote: >>> Implements an sclp_read function to capture input from the >>> console and a wrapper function that handles parsing certain >>> characters and adding

Re: [Qemu-devel] [PATCH] docs: Add docs/devel/testing.rst

2018-01-29 Thread Thomas Huth
On 29.01.2018 15:36, Eric Blake wrote: > On 01/29/2018 01:42 AM, Fam Zheng wrote: >> On Mon, Jan 29, 2018 at 2:56 PM, Thomas Huth wrote: >>> On 29.01.2018 04:31, Fam Zheng wrote: >>> [...] +1. Create a new source file. For example, ``tests/test-foo.c``. >>> [...] +1. Create a new source

Re: [Qemu-devel] [RFC v1] block/NVMe: introduce a new vhost NVMe host device to QEMU

2018-01-29 Thread Stefan Hajnoczi
On Mon, Jan 15, 2018 at 04:01:55PM +0800, Changpeng Liu wrote: > NVMe 1.3 specification introduces a new NVMe ADMIN command: > doorbell buffer config, which can write shadow doorbell buffer > instead of MMIO registers, so it can improve the Guest performance > a lot for emulated NVMe devices inside

Re: [Qemu-devel] [Qemu-block] [RFC] block-backend: fix double inc/dec inflight requests number

2018-01-29 Thread Kevin Wolf
Am 25.01.2018 um 12:37 hat Stefan Hajnoczi geschrieben: > On Mon, Jan 22, 2018 at 05:45:49PM +0300, Vladimir Sementsov-Ogievskiy wrote: > > Is it a bug or a feature? Why do we call inc/dec twice for read/write? > > We don't do this for flush and discard.. > > It's non-obvious and I asked Paolo the

Re: [Qemu-devel] [PATCH 1/2] qcow2: add overlap check for bitmap directory

2018-01-29 Thread Max Reitz
On 2017-11-30 17:47, Vladimir Sementsov-Ogievskiy wrote: > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > block/qcow2.h | 7 +-- > block/qcow2-refcount.c | 12 > block/qcow2.c | 6 ++ > 3 files changed, 23 insertions(+), 2 deletions(-) > > diff --git

Re: [Qemu-devel] [PATCH v2 03/21] RISC-V CPU Core Definition

2018-01-29 Thread Igor Mammedov
On Wed, 24 Jan 2018 10:21:01 -0800 Michael Clark wrote: > On Mon, Jan 15, 2018 at 5:44 AM, Igor Mammedov wrote: > > > On Wed, 10 Jan 2018 15:46:22 -0800 > > Michael Clark wrote: > > > > > Add CPU state header, CPU definitions and initialization routines > > > > > > Signed-off-by: Michael Cla

Re: [Qemu-devel] [RFC v1] block/NVMe: introduce a new vhost NVMe host device to QEMU

2018-01-29 Thread Harris, James R
On 1/29/18, 8:29 AM, "Stefan Hajnoczi" wrote: Each new feature has a cost in terms of maintainance, testing, documentation, and support. Users need to be educated about the role of each available storage controller and how to choose between them. I'm not sure why QEM

Re: [Qemu-devel] [Qemu-block] [PATCH] virtio-blk: check for NULL BlockDriverState

2018-01-29 Thread Kevin Wolf
Am 24.01.2018 um 12:31 hat Stefan Hajnoczi geschrieben: > On Mon, Jan 22, 2018 at 09:01:49AM -0600, Mark Kanda wrote: > > Add a BlockDriverState NULL check to virtio_blk_handle_request() > > to prevent a segfault if the drive is forcibly removed using HMP > > 'drive_del' (without performing a hotpl

Re: [Qemu-devel] [PATCH] iotests: Fix CID for VMDK afl image

2018-01-29 Thread Kevin Wolf
Am 24.01.2018 um 05:42 hat Fam Zheng geschrieben: > The descriptor block in the image, which includes the CID to verify, has been > invalid since the reference image was added. Since commit 9877860e7bd we > report > this error earlier than the "file too large", so 059.out mismatches. > > Instead

Re: [Qemu-devel] [PATCH v3 19/22] fpu/softfloat: re-factor scalbn

2018-01-29 Thread Richard Henderson
On 01/29/2018 03:59 AM, Alex Bennée wrote: > > Richard Henderson writes: > >> On 01/24/2018 05:13 AM, Alex Bennée wrote: >>> +/* Multiply A by 2 raised to the power N. */ >>> +static FloatParts scalbn_decomposed(FloatParts a, int n, >>> + float_status *s

Re: [Qemu-devel] [Qemu-block] [PATCH v2] block: Fix qemu crash when using scsi-block

2018-01-29 Thread Stefan Hajnoczi
On Fri, Dec 15, 2017 at 04:59:13PM -0800, Deepa Srinivasan wrote: > Starting qemu with the following arguments causes qemu to segfault: > ... -device lsi,id=lsi0 -drive file=iscsi:<...>,format=raw,if=none,node-name= > iscsi1 -device scsi-block,bus=lsi0.0,id=<...>,drive=iscsi1 > > This patch fixes

Re: [Qemu-devel] [PATCH v5 3/5] tests: Migration ppc now inlines its program

2018-01-29 Thread Laurent Vivier
On 29/01/2018 13:17, Juan Quintela wrote: > No need to write it to a file. Just need a proper firmware O:-) > > Signed-off-by: Juan Quintela > CC: Laurent Vivier > --- > tests/migration-test.c | 41 + > 1 file changed, 5 insertions(+), 36 deletions(-) >

Re: [Qemu-devel] [PULL 0/6] Net patches

2018-01-29 Thread Peter Maydell
On 29 January 2018 at 08:16, Jason Wang wrote: > The following changes since commit e607bbee553cfe73072870cef458cfa4e78133e2: > > Merge remote-tracking branch > 'remotes/edgar/tags/edgar/xilinx-next-2018-01-26.for-upstream' into staging > (2018-01-26 14:24:25 +) > > are available in the gi

Re: [Qemu-devel] [PATCH v3 19/22] fpu/softfloat: re-factor scalbn

2018-01-29 Thread Richard Henderson
On 01/29/2018 07:50 AM, Richard Henderson wrote: > On 01/29/2018 03:59 AM, Alex Bennée wrote: >> >> Richard Henderson writes: >> >>> On 01/24/2018 05:13 AM, Alex Bennée wrote: +/* Multiply A by 2 raised to the power N. */ +static FloatParts scalbn_decomposed(FloatParts a, int n, +

qemu-devel@nongnu.org

2018-01-29 Thread Stefan Hajnoczi
On Wed, Dec 13, 2017 at 03:33:01PM +, Fernando Casas Schössow wrote: > Maybe I’m missing something here but, if I recall correctly, the qemu process > for the guest is terminated when this problem happens. So how a debugger will > be attached to a process that is gone? Sorry, this got lost i

Re: [Qemu-devel] [PATCH v5 2/2] qemu-img: Document --force-share / -U

2018-01-29 Thread Max Reitz
On 2017-12-26 03:52, Fam Zheng wrote: > Signed-off-by: Fam Zheng > Reviewed-by: Stefan Hajnoczi > Reviewed-by: Kashyap Chamarthy > Signed-off-by: Kevin Wolf > --- > qemu-img.texi | 9 + > 1 file changed, 9 insertions(+) > > diff --git a/qemu-img.texi b/qemu-img.texi > index 60a0e080c6

[Qemu-devel] [PULL 0/3] Tracing patches

2018-01-29 Thread Stefan Hajnoczi
The following changes since commit 6233b4a8c2a32ef6955a921246fa08705bbb3676: Merge remote-tracking branch 'remotes/ericb/tags/pull-nbd-2018-01-26' into staging (2018-01-26 17:29:14 +) are available in the Git repository at: git://github.com/stefanha/qemu.git tags/tracing-pull-request f

[Qemu-devel] [PULL 2/3] tracetool: clarify that "formats" means "format strings"

2018-01-29 Thread Stefan Hajnoczi
The terminology used by tracetool is not consistent with C sprintf or docs/devel/tracing.txt. The word "formats" is sometimes used to mean "format strings". This patch clarifies comments and error messages that contain this word. Note that the error message lines are longer than 80 characters bu

[Qemu-devel] [PULL 1/3] tracetool: prefix parse errors with line numbers

2018-01-29 Thread Stefan Hajnoczi
Include the file line number in the message that is printed when trace-events parse errors are raised. [Use enumerate(fobj, 1) to avoid having to increment a 0-based index later, as suggested by Eric Blake. --Stefan] Suggested-by: Dr. David Alan Gilbert Signed-off-by: Stefan Hajnoczi Reviewed-b

[Qemu-devel] [PULL 3/3] tracetool: report error on foo() instead of foo(void)

2018-01-29 Thread Stefan Hajnoczi
C functions with no arguments must be declared foo(void) instead of foo(). The tracetool argument list parser has never accepted an empty argument list. This patch adds a clear error message for this error case. Signed-off-by: Stefan Hajnoczi Reviewed-by: Eric Blake Message-id: 20180110202553.

Re: [Qemu-devel] [Qemu-block] [PATCH] virtio-blk: check for NULL BlockDriverState

2018-01-29 Thread Mark Kanda
On 1/29/2018 9:41 AM, Kevin Wolf wrote: Am 24.01.2018 um 12:31 hat Stefan Hajnoczi geschrieben: On Mon, Jan 22, 2018 at 09:01:49AM -0600, Mark Kanda wrote: Add a BlockDriverState NULL check to virtio_blk_handle_request() to prevent a segfault if the drive is forcibly removed using HMP 'drive_

Re: [Qemu-devel] [PATCH] docs: Add docs/devel/testing.rst

2018-01-29 Thread Stefan Hajnoczi
On Mon, Jan 29, 2018 at 08:38:29AM -0600, Eric Blake wrote: > On 01/29/2018 05:04 AM, Stefan Hajnoczi wrote: > > On Mon, Jan 29, 2018 at 11:31:33AM +0800, Fam Zheng wrote: > > > > Thanks for writing this! > > > > I have only reviewed some parts in detail. > > > > >> + > >> +On top of libqtest,

Re: [Qemu-devel] [RFC 0/2] Use SDL to create an OpenGL ES context for virglrenderer.

2018-01-29 Thread Elie Tournier
On Wed, Jan 17, 2018 at 02:50:27PM +, Elie Tournier wrote: > Hello everyone, > > At Collabora, we are working on adding an OpenGL ES backend on virglrenderer > [1]. > I submit these patches as an RFC because our work didn't land in > virglrenderer yet. > Currently, we support OpenGL ES 2.0 o

Re: [Qemu-devel] [PULL 0/3] Tracing patches

2018-01-29 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20180129160740.1195-1-stefa...@redhat.com Subject: [Qemu-devel] [PULL 0/3] Tracing patches === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1 total=$(git log --oneline $BAS

[Qemu-devel] [PATCH] char-pty: fix glib assert

2018-01-29 Thread Juan Quintela
I am having this assert over and over: (process:30804): GLib-CRITICAL **: g_source_unref: assertion 'source != NULL' failed gdb points to the line changed on this patch, and my reading of commit: 2c716ba1506769c9be2caa02f0f6d6e7c00f4304 is that it should be timer_src what is unrefered there.

[Qemu-devel] [PATCH v2 03/12] vl: rename DisplayType to LegacyDisplayType

2018-01-29 Thread Gerd Hoffmann
qapi DisplayType will replace the current enum. For the transition both will coexist though, so rename it so we don't have a name clash. Signed-off-by: Gerd Hoffmann --- vl.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/vl.c b/vl.c index fa19a61500..a2478412c7

[Qemu-devel] [PATCH v2 12/12] vl: drop request_opengl variable

2018-01-29 Thread Gerd Hoffmann
Switch over the one leftover user to qapi DisplayType. The delete the unused request_opengl variable. Signed-off-by: Gerd Hoffmann --- vl.c | 8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/vl.c b/vl.c index 827ab2a3b0..42867d60f8 100644 --- a/vl.c +++ b/vl.c @@ -135,7 +

[Qemu-devel] [PATCH v2 06/12] vl: drop no_quit variable

2018-01-29 Thread Gerd Hoffmann
Not used any more, delete it. Signed-off-by: Gerd Hoffmann --- vl.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/vl.c b/vl.c index 25e784be63..c17dedfa4e 100644 --- a/vl.c +++ b/vl.c @@ -152,7 +152,6 @@ int vga_interface_type = VGA_NONE; static int full_screen = 0;

[Qemu-devel] [PATCH v2 11/12] vl: drop display_type variable

2018-01-29 Thread Gerd Hoffmann
Switch over all leftover users to qapi DisplayType. Then delete the unused display_type variable. Signed-off-by: Gerd Hoffmann --- vl.c | 54 ++ 1 file changed, 14 insertions(+), 40 deletions(-) diff --git a/vl.c b/vl.c index 899fcad75e..827ab

[Qemu-devel] [PATCH v2 01/12] vl: deprecate -no-frame

2018-01-29 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- vl.c | 4 qemu-doc.texi | 7 +++ 2 files changed, 11 insertions(+) diff --git a/vl.c b/vl.c index e517a8d995..ac0efca708 100644 --- a/vl.c +++ b/vl.c @@ -2104,6 +2104,8 @@ static DisplayType select_display(const char *p) const char

[Qemu-devel] [PATCH v2 07/12] egl-headless: use DisplayOptions

2018-01-29 Thread Gerd Hoffmann
Switch egl-headless ui to use qapi DisplayOptions for configuration. Signed-off-by: Gerd Hoffmann --- include/ui/console.h | 2 +- ui/egl-headless.c| 2 +- vl.c | 3 ++- qapi/ui.json | 5 +++-- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/include/ui/

[Qemu-devel] [PATCH v2 02/12] vl: deprecate -alt-grab and -ctrl-grab

2018-01-29 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- vl.c | 8 qemu-doc.texi | 6 ++ 2 files changed, 14 insertions(+) diff --git a/vl.c b/vl.c index ac0efca708..fa19a61500 100644 --- a/vl.c +++ b/vl.c @@ -2115,6 +2115,8 @@ static DisplayType select_display(const char *p)

[Qemu-devel] [PATCH v2 10/12] vl: drop full_screen variable

2018-01-29 Thread Gerd Hoffmann
Not used any more, delete it. Signed-off-by: Gerd Hoffmann --- vl.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/vl.c b/vl.c index eb8aca9479..899fcad75e 100644 --- a/vl.c +++ b/vl.c @@ -149,7 +149,6 @@ static int rtc_utc = 1; static int rtc_date_offset = -1; /* -1 means no change */ Q

[Qemu-devel] [PATCH v2 00/12] rework display initialization, part one

2018-01-29 Thread Gerd Hoffmann
Hi, This series is the first part of my the qemu display initialization update. Changes: * Create a QAPI DisplayOptions type for display configuration. * Switch all display initialization calls to accept DisplayOptions instead of a bunch of bools. Coming soon, building on top of the a

[Qemu-devel] [PATCH v2 05/12] sdl: use DisplayOptions

2018-01-29 Thread Gerd Hoffmann
Switch sdl ui to use qapi DisplayOptions for configuration. Signed-off-by: Gerd Hoffmann --- include/ui/console.h | 8 ui/sdl.c | 19 +-- ui/sdl2.c| 33 +++-- vl.c | 13 +++-- qapi/ui.json

[Qemu-devel] [PATCH v2 04/12] gtk: add and use DisplayOptions + DisplayGTK

2018-01-29 Thread Gerd Hoffmann
Add QAPI DisplayType enum, DisplayOptions union and DisplayGTK struct. Switch gtk configuration to use the qapi type. Some bookkeeping (fullscreen for example) is done twice now, this is temporary until more/all UIs are switched over to qapi configuration. Signed-off-by: Gerd Hoffmann --- inclu

[Qemu-devel] [PATCH v2 08/12] curses: use DisplayOptions

2018-01-29 Thread Gerd Hoffmann
Switch curses ui to use qapi DisplayOptions for configuration. Signed-off-by: Gerd Hoffmann --- include/ui/console.h | 4 ++-- ui/curses.c | 2 +- vl.c | 4 +++- qapi/ui.json | 5 +++-- 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/include/ui/con

[Qemu-devel] [PATCH v2 09/12] cocoa: use DisplayOptions

2018-01-29 Thread Gerd Hoffmann
Switch cocoa ui to use qapi DisplayOptions for configuration. Signed-off-by: Gerd Hoffmann --- include/ui/console.h | 4 ++-- vl.c | 3 ++- qapi/ui.json | 6 -- ui/cocoa.m | 4 ++-- 4 files changed, 10 insertions(+), 7 deletions(-) diff --git a/include/ui/c

Re: [Qemu-devel] [PATCH v3] tpm: add CRB device

2018-01-29 Thread Igor Mammedov
On Fri, 26 Jan 2018 13:03:06 +0100 Marc-André Lureau wrote: > tpm_crb is a device for TPM 2.0 Command Response Buffer (CRB) > Interface as defined in TCG PC Client Platform TPM Profile (PTP) > Specification Family “2.0” Level 00 Revision 01.03 v22. > > The PTP allows device implementation to swi

Re: [Qemu-devel] [PATCH] docs: Add docs/devel/testing.rst

2018-01-29 Thread Eric Blake
On 01/29/2018 10:10 AM, Stefan Hajnoczi wrote: > On Mon, Jan 29, 2018 at 08:38:29AM -0600, Eric Blake wrote: >> On 01/29/2018 05:04 AM, Stefan Hajnoczi wrote: >>> On Mon, Jan 29, 2018 at 11:31:33AM +0800, Fam Zheng wrote: >>> >>> Thanks for writing this! >>> >>> I have only reviewed some parts in d

Re: [Qemu-devel] [PATCH v5 2/2] qemu-img: Document --force-share / -U

2018-01-29 Thread Kashyap Chamarthy
On Mon, Jan 29, 2018 at 05:01:41PM +0100, Max Reitz wrote: > On 2017-12-26 03:52, Fam Zheng wrote: [...] > So the previous patch makes the use of blank lines consistent and this > one breaks it again? :-) > > > +If specified, @code{qemu-img} will open the image with shared permissions, > > +whic

Re: [Qemu-devel] [PATCH v2 1/2] i386: Add Intel Processor Trace feature support

2018-01-29 Thread Eduardo Habkost
On Mon, Jan 29, 2018 at 07:03:13AM +, Kang, Luwei wrote: > > > From: Chao Peng > > > > > > Expose Intel Processor Trace feature to guest. > > > > > > In order to make this feature migration-safe, new feature word > > > information "FEAT_INTEL_PT_EBX" and "FEAT_INTEL_PT_ECX" be added. > > > Som

Re: [Qemu-devel] [PATCH] tcg: add cs_base and flags to -d exec output

2018-01-29 Thread Peter Maydell
On 17 December 2017 at 05:50, Paolo Bonzini wrote: > Signed-off-by: Paolo Bonzini > --- > accel/tcg/cpu-exec.c | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/accel/tcg/cpu-exec.c b/accel/tcg/cpu-exec.c > index 4318441e4c..18c1a2aedb 100644 > --- a/accel/tcg/cpu-ex

Re: [Qemu-devel] [PATCH] char-pty: fix glib assert

2018-01-29 Thread Laurent Vivier
On 29/01/2018 17:17, Juan Quintela wrote: > I am having this assert over and over: > > (process:30804): GLib-CRITICAL **: g_source_unref: assertion 'source != NULL' > failed > > gdb points to the line changed on this patch, and my reading of > commit: > > 2c716ba1506769c9be2caa02f0f6d6e7c00f430

Re: [Qemu-devel] [PATCH v3] tpm: add CRB device

2018-01-29 Thread Stefan Berger
On 01/29/2018 11:24 AM, Igor Mammedov wrote: On Fri, 26 Jan 2018 13:03:06 +0100 Marc-André Lureau wrote: tpm_crb is a device for TPM 2.0 Command Response Buffer (CRB) Interface as defined in TCG PC Client Platform TPM Profile (PTP) Specification Family “2.0” Level 00 Revision 01.03 v22. The P

[Qemu-devel] [PATCH RFC 0/2] s390x: support zpci in tcg

2018-01-29 Thread Cornelia Huck
This patch set (available at git://github.com/cohuck/qemu pci-tcg) wires up zpci under tcg. A guest started with qemu-system-s390x -M s390-ccw-virtio,accel=tcg -cpu qemu,zpci=on -device virtio-net-pci (...) and a 4.15 kernel in the guest (needed because the requirement for ais was dropped with

[Qemu-devel] [PATCH RFC 1/2] s390x/tcg: wire up pci instructions

2018-01-29 Thread Cornelia Huck
On s390x, pci support is implemented via a set of instructions (no mmio). Unfortunately, none of them are documented in the PoP; the code is based upon the existing implementation for KVM and the Linux zpci driver. Signed-off-by: Cornelia Huck --- target/s390x/helper.h | 9 target/s3

[Qemu-devel] [PATCH RFC 2/2] s390x/cpumodel: allow zpci features in qemu model

2018-01-29 Thread Cornelia Huck
AEN can be provided unconditionally, ZPCI has to be turned on manually (it should really depend on CONFIG_PCI). With -cpu qemu,zpci=on, a 4.15 guest kernel can now successfully detect virtio-pci devices under tcg. Signed-off-by: Cornelia Huck --- target/s390x/gen-features.c | 3 +++ 1 file chan

Re: [Qemu-devel] [RFC PATCH 02/10] block/qapi: Add qcow2 create options to schema

2018-01-29 Thread Max Reitz
On 2018-01-11 20:52, Kevin Wolf wrote: > Signed-off-by: Kevin Wolf > --- > qapi/block-core.json | 33 - > 1 file changed, 32 insertions(+), 1 deletion(-) > > diff --git a/qapi/block-core.json b/qapi/block-core.json > index 1749376c61..9341f6708d 100644 > --- a/qap

Re: [Qemu-devel] [RFC v3 01/14] blockjobs: add manual property

2018-01-29 Thread Kevin Wolf
Am 27.01.2018 um 03:05 hat John Snow geschrieben: > This property will be used to opt-in to the new BlockJobs workflow > that allows a tighter, more explicit control over transitions from > one runstate to another. > > Signed-off-by: John Snow > diff --git a/include/block/blockjob.h b/include/bl

Re: [Qemu-devel] [RFC v3 02/14] blockjobs: Add status enum

2018-01-29 Thread Kevin Wolf
Am 27.01.2018 um 03:05 hat John Snow geschrieben: > We're about to add several new states, and booleans are becoming > unwieldly and difficult to reason about. To this end, add a new "status" > field and add our existing states in a redundant manner alongside the > bools they are replacing: > > UN

Re: [Qemu-devel] [RFC] qid path collision issues in 9pfs

2018-01-29 Thread Greg Kurz
On Thu, 25 Jan 2018 17:08:40 +0100 Veaceslav Falico wrote: > On 1/25/2018 3:46 PM, Veaceslav Falico wrote: [...] > > > > I've reproduced it today without fscache: > > > > host: > > mount -o bind /tmp/mounted t1 > > mount -o bind /tmp/mounted t2 > > > > guest: > > / # tail -f t1/file & > > / #

Re: [Qemu-devel] [RFC PATCH 04/10] qcow2: Pass BlockdevCreateOptions to qcow2_create2()

2018-01-29 Thread Max Reitz
On 2018-01-11 20:52, Kevin Wolf wrote: > All of the simple options are now passed to qcow2_create2() in a > BlockdevCreateOptions object. Still missing: node-name and the > encryption options. > > Signed-off-by: Kevin Wolf > --- > block/qcow2.c | 186 > ++

Re: [Qemu-devel] [PULL 0/7] Input 20180129 v2 patches

2018-01-29 Thread Peter Maydell
000) > > are available in the git repository at: > > git://git.kraxel.org/qemu tags/input-20180129-v2-pull-request > > for you to fetch changes up to ae6b06ab655b21c19b234ce3422f694d11a013e0: > > hw: convert virtio-input-hid dev

Re: [Qemu-devel] [RFC v3 03/14] blockjobs: add state transition table

2018-01-29 Thread Kevin Wolf
Am 27.01.2018 um 03:05 hat John Snow geschrieben: > The state transition table has mostly been implied. We're about to make > it a bit more complex, so let's make the STM explicit instead. > > Perform state transitions with a function that for now just asserts the > transition is appropriate. > >

Re: [Qemu-devel] [PATCH v3 1/5] target/arm: Expand vector registers for SVE

2018-01-29 Thread Peter Maydell
On 23 January 2018 at 03:53, Richard Henderson wrote: > Change vfp.regs as a uint64_t to vfp.zregs as an ARMVectorReg. > The previous patches have made the change in representation > relatively painless. > > Reviewed-by: Alex Bennée > Signed-off-by: Richard Henderson > --- > target/arm/cpu.h

Re: [Qemu-devel] [PATCH v3 2/5] target/arm: Add predicate registers for SVE

2018-01-29 Thread Peter Maydell
On 23 January 2018 at 03:53, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > target/arm/cpu.h | 12 > 1 file changed, 12 insertions(+) > > diff --git a/target/arm/cpu.h b/target/arm/cpu.h > index 1854fe51a8..3f4f6b6144 100644 > --- a/target/arm/cpu.h > +++ b/targ

Re: [Qemu-devel] [PATCH v3 3/5] target/arm: Add SVE to migration state

2018-01-29 Thread Peter Maydell
On 23 January 2018 at 03:53, Richard Henderson wrote: > Save the high parts of the Zregs and all of the Pregs. > The ZCR_ELx registers are migrated via the CP mechanism. > > Signed-off-by: Richard Henderson > --- > target/arm/machine.c | 53 >

Re: [Qemu-devel] [RFC PATCH 05/10] qcow2: Use BlockdevRef in qcow2_create2()

2018-01-29 Thread Max Reitz
On 2018-01-11 20:52, Kevin Wolf wrote: > Instead of passing a separate BlockDriverState* into qcow2_create2(), > make use of the BlockdevRef that is included in BlockdevCreateOptions. > > Signed-off-by: Kevin Wolf > --- > include/block/block.h | 1 + > block.c | 39 +++

Re: [Qemu-devel] [RFC v3 01/14] blockjobs: add manual property

2018-01-29 Thread John Snow
On 01/29/2018 11:59 AM, Kevin Wolf wrote: > Am 27.01.2018 um 03:05 hat John Snow geschrieben: >> This property will be used to opt-in to the new BlockJobs workflow >> that allows a tighter, more explicit control over transitions from >> one runstate to another. >> >> Signed-off-by: John Snow >

Re: [Qemu-devel] [RFC v3 05/14] blockjobs: add block_job_dismiss

2018-01-29 Thread Kevin Wolf
Am 27.01.2018 um 03:05 hat John Snow geschrieben: > For jobs that have reached their terminal state, prior to having their > last reference put down (meaning jobs that have completed successfully, > unsuccessfully, or have been canceled), allow the user to dismiss the > job's lingering status repor

Re: [Qemu-devel] [RFC v3 02/14] blockjobs: Add status enum

2018-01-29 Thread John Snow
On 01/29/2018 12:04 PM, Kevin Wolf wrote: > Am 27.01.2018 um 03:05 hat John Snow geschrieben: >> We're about to add several new states, and booleans are becoming >> unwieldly and difficult to reason about. To this end, add a new "status" >> field and add our existing states in a redundant manner

[Qemu-devel] [PATCH v6 03/23] exec: add debug version of physical memory read and write API

2018-01-29 Thread Brijesh Singh
Adds the following new APIs - cpu_physical_memory_read_debug - cpu_physical_memory_write_debug - cpu_physical_memory_rw_debug - ldl_phys_debug - ldq_phys_debug Cc: Paolo Bonzini Cc: Peter Crosthwaite Cc: Richard Henderson Signed-off-by: Brijesh Singh Reviewed-by: Paolo Bonzini --- exec.c

[Qemu-devel] [PATCH v6 00/23] x86: Secure Encrypted Virtualization (AMD)

2018-01-29 Thread Brijesh Singh
This patch series provides support for AMD's new Secure Encrypted Virtualization (SEV) feature. SEV is an extension to the AMD-V architecture which supports running multiple VMs under the control of a hypervisor. The SEV feature allows the memory contents of a virtual machine (VM) to be transpare

[Qemu-devel] [PATCH v6 01/23] memattrs: add debug attribute

2018-01-29 Thread Brijesh Singh
Extend the MemTxAttrs to include 'debug' flag. The flag can be used as general indicator that operation was triggered by the debugger. Later in the patch series we set the debug=1 when issuing a memory access from the gdbstub or HMP commands. This patch is prerequisite to support debugging the enc

[Qemu-devel] [PATCH v6 04/23] monitor/i386: use debug APIs when accessing guest memory

2018-01-29 Thread Brijesh Singh
Updates HMP commands to use the debug version of APIs when accessing the guest memory. Cc: Paolo Bonzini Cc: Peter Crosthwaite Cc: Richard Henderson Cc: "Dr. David Alan Gilbert" Cc: Markus Armbruster Cc: Eduardo Habkost Signed-off-by: Brijesh Singh --- cpus.c| 2 +- disas.

[Qemu-devel] [PATCH v6 06/23] machine: add -memory-encryption property

2018-01-29 Thread Brijesh Singh
When CPU supports memory encryption feature, the property can be used to specify the encryption object to use when launching an encrypted guest. Cc: Paolo Bonzini Cc: Eduardo Habkost Cc: Marcel Apfelbaum Cc: Stefan Hajnoczi Signed-off-by: Brijesh Singh --- hw/core/machine.c | 22 ++

[Qemu-devel] [PATCH v6 05/23] target/i386: add memory encryption feature cpuid support

2018-01-29 Thread Brijesh Singh
AMD EPYC processors support memory encryption feature. The feature is reported through CPUID 8000_001F[EAX]. Fn8000_001F [EAX]: Bit 0 Secure Memory Encryption (SME) supported Bit 1 Secure Encrypted Virtualization (SEV) supported Bit 2 Page flush MSR supported Bit 3 Ecrypted State (SEV-

[Qemu-devel] [PATCH v6 18/23] sev: emit the SEV_MEASUREMENT event

2018-01-29 Thread Brijesh Singh
During machine creation we encrypted the guest bios image, the LAUNCH_MEASURE command can be used to retrieve the measurement of the encrypted memory region. Emit the SEV_MEASUREMENT event so that libvirt can grab the measurement value as soon as we are done with creating the encrypted machine. Cc

[Qemu-devel] [PATCH v6 02/23] exec: add ram_debug_ops support

2018-01-29 Thread Brijesh Singh
Currently, the guest memory access for the debug purpose is performed using the memcpy(). Lets extend the 'struct MemoryRegion' to include ram_debug_ops callbacks. The ram_debug_ops can be used to override memcpy() with something else. The feature can be used by encrypted guest -- which can regist

[Qemu-devel] [PATCH v6 07/23] kvm: update kvm.h to include memory encryption ioctls

2018-01-29 Thread Brijesh Singh
Updates kmv.h to include memory encryption ioctls and SEV commands. Cc: Christian Borntraeger Cc: Cornelia Huck Cc: Paolo Bonzini Signed-off-by: Brijesh Singh --- linux-headers/linux/kvm.h | 90 +++ 1 file changed, 90 insertions(+) diff --git a/lin

[Qemu-devel] [PATCH v6 12/23] kvm: introduce memory encryption APIs

2018-01-29 Thread Brijesh Singh
Inorder to integerate the Secure Encryption Virtualization (SEV) support add few high-level memory encryption APIs which can be used for encrypting the guest memory region. Cc: Paolo Bonzini Cc: k...@vger.kernel.org Signed-off-by: Brijesh Singh --- accel/kvm/kvm-all.c| 30 ++

[Qemu-devel] [PATCH v6 16/23] target/i386: encrypt bios rom

2018-01-29 Thread Brijesh Singh
SEV requires that guest bios must be encrypted before booting the guest. Cc: "Michael S. Tsirkin" Cc: Paolo Bonzini Cc: Richard Henderson Cc: Eduardo Habkost Signed-off-by: Brijesh Singh --- hw/i386/pc_sysfw.c | 13 + 1 file changed, 13 insertions(+) diff --git a/hw/i386/pc_sysf

[Qemu-devel] [PATCH v6 17/23] qapi: add SEV_MEASUREMENT event

2018-01-29 Thread Brijesh Singh
Add SEV_MEASUREMENT event which can be used by libvirt to get the measurement of the memory regions encrypted through the SEV launch flow. The measurement value is base64 encoded. Cc: Daniel P. Berrange Cc: Eric Blake Cc: Markus Armbruster Signed-off-by: Brijesh Singh --- qapi-schema.json | 1

[Qemu-devel] [PATCH v6 08/23] docs: add AMD Secure Encrypted Virtualization (SEV)

2018-01-29 Thread Brijesh Singh
Create a documentation entry to describe the AMD Secure Encrypted Virtualization (SEV) feature. Cc: Paolo Bonzini Signed-off-by: Brijesh Singh --- docs/amd-memory-encryption.txt | 92 ++ 1 file changed, 92 insertions(+) create mode 100644 docs/amd-memory

[Qemu-devel] [PATCH v6 19/23] sev: Finalize the SEV guest launch flow

2018-01-29 Thread Brijesh Singh
SEV launch flow requires us to issue LAUNCH_FINISH command before guest is ready to run. Cc: Paolo Bonzini Cc: k...@vger.kernel.org Signed-off-by: Brijesh Singh --- accel/kvm/sev.c| 29 + accel/kvm/trace-events | 1 + 2 files changed, 30 insertions(+) diff

[Qemu-devel] [PATCH v6 14/23] sev: add command to create launch memory encryption context

2018-01-29 Thread Brijesh Singh
The KVM_SEV_LAUNCH_START command creates a new VM encryption key (VEK). The encryption key created with the command will be used for encrypting the bootstrap images (such as guest bios). Cc: Paolo Bonzini Cc: k...@vger.kernel.org Signed-off-by: Brijesh Singh --- accel/kvm/sev.c| 97

[Qemu-devel] [PATCH v6 22/23] target/i386: clear C-bit when walking SEV guest page table

2018-01-29 Thread Brijesh Singh
In SEV-enabled guest the pte entry will have C-bit set, we need to clear the C-bit when walking the page table. The C-bit position should be available in cpuid Fn8000_001f[EBX] Cc: Paolo Bonzini Cc: Richard Henderson Cc: Eduardo Habkost Signed-off-by: Brijesh Singh --- target/i386/helper.c |

[Qemu-devel] [PATCH v6 09/23] accel: add Secure Encrypted Virtulization (SEV) object

2018-01-29 Thread Brijesh Singh
Add a new memory encryption object 'sev-guest'. The object will be used to create enrypted VMs on AMD EPYC CPU. The object provides the properties to pass guest owner's public Diffie-hellman key, guest policy and session information required to create the memory encryption context within the SEV fi

<    1   2   3   4   >