Re: [Qemu-devel] [Qemu-arm] [PATCH v2 37/67] target/arm: Implement SVE Integer Compare - Immediate Group

2018-02-23 Thread Peter Maydell
On 17 February 2018 at 18:22, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > target/arm/helper-sve.h| 44 +++ > target/arm/sve_helper.c| 88 >

[Qemu-devel] [PATCH v6 2/5] usb-mtp: print parent path in IN_IGNORED trace fn

2018-02-23 Thread Bandan Das
Fix a possible null dereference when deleting a folder and its contents. An ignored event might be received for its contents after the parent folder is deleted which will return a null object. Signed-off-by: Bandan Das --- hw/usb/dev-mtp.c | 5 ++--- 1 file changed, 2

Re: [Qemu-devel] [PATCH v2 39/67] target/arm: Implement SVE Predicate Count Group

2018-02-23 Thread Peter Maydell
On 17 February 2018 at 18:22, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > target/arm/helper-sve.h| 2 + > target/arm/sve_helper.c| 14 ++ > target/arm/translate-sve.c | 116 >

[Qemu-devel] [PATCH v6 4/5] usb-mtp: Introduce write support for MTP objects

2018-02-23 Thread Bandan Das
Allow write operations on behalf of the initiator. The precursor to write is the sending of the write metadata that consists of the ObjectInfo dataset. This patch introduces a flag that is set when the responder is ready to receive write data based on a previous SendObjectInfo operation by the

[Qemu-devel] [PATCH v6 3/5] usb-mtp: Support delete of mtp objects

2018-02-23 Thread Bandan Das
Write of existing objects by the initiator is acheived by making a temporary buffer with the new changes, deleting the old file and then writing a new file with the same name. Also, add a "readonly" property which needs to be set to false for deletion to work. Signed-off-by: Bandan Das

Re: [Qemu-devel] [PATCH v1 4/8] new contrib/generate_all.sh: batch risugen script

2018-02-23 Thread Daniel P . Berrangé
On Fri, Feb 23, 2018 at 04:45:58PM +, Alex Bennée wrote: > > Daniel P. Berrangé writes: > > > On Fri, Feb 23, 2018 at 03:46:09PM +, Alex Bennée wrote: > >> This is a simple script for generating all instructions in a given > >> RISU file. You can split up the batch

[Qemu-devel] [PATCH v6 1/5] usb-mtp: Add one more argument when building results

2018-02-23 Thread Bandan Das
The response to a SendObjectInfo consists of the storageid, parent obejct handle and the handle reserved for the new incoming object Signed-off-by: Bandan Das --- hw/usb/dev-mtp.c | 50 +++--- 1 file changed, 27 insertions(+), 23

[Qemu-devel] [PATCH v6 0/5] Initial write support for MTP objects

2018-02-23 Thread Bandan Das
v6: 4/5,5/5: Cleanup some checkpatch errors. Thank you, Patchew! v5: 4/5,5/5: Add check for the RO bit and set response to STORE_READ_ONLY v4: 4/5: Remove getumask and set default permissions to 0644 5/5: Remove usb_mtp_object_lookup_name out of #ifdef CONFIG_INOTIFY1 Test

Re: [Qemu-devel] [PATCH v8 00/13] Interactive Boot Menu for DASD and SCSI Guests on s390x

2018-02-23 Thread Collin L. Walling
On 02/23/2018 08:33 AM, Thomas Huth wrote: On 23.02.2018 12:50, Viktor Mihajlovski wrote: On 23.02.2018 11:17, Thomas Huth wrote: On 23.02.2018 09:53, Christian Borntraeger wrote: Hmmm, on my ubuntu 16.04 guest, I get the boot menu with no timeout even if I do not specify loadparm or boot

Re: [Qemu-devel] [PATCH v2 33/36] file-posix: Fix no-op bdrv_truncate() with falloc preallocation

2018-02-23 Thread Eric Blake
On 02/21/2018 07:54 AM, Kevin Wolf wrote: If bdrv_truncate() is called, but the requested size is the same as before, don't call posix_fallocate(), which returns -EINVAL for length zero and would therefore make bdrv_truncate() fail. The problem can be triggered by creating a zero-sized raw

[Qemu-devel] [PATCH 3/5] ide: do not set s->end_transfer_func to ide_transfer_cancel

2018-02-23 Thread Paolo Bonzini
There is code checking s->end_transfer_func and it was not taught about ide_transfer_cancel. We can just use ide_transfer_stop because s->end_transfer_func is only ever called in the DRQ phase: after ide_transfer_cancel, the value of s->end_transfer_func is only used as a marker and never used to

[Qemu-devel] [PATCH 2/5] ide: push end_transfer callback to ide_transfer_halt

2018-02-23 Thread Paolo Bonzini
The callback must be invoked once we get out of the DRQ phase; because all end_transfer_funcs end up invoking ide_transfer_stop, call it there. While at it, remove the "notify" argument from ide_transfer_halt; the code can simply be moved to ide_transfer_stop. Old PATA controllers have no

[Qemu-devel] [PATCH 1/5] ide: push call to end_transfer_func out of start_transfer callback

2018-02-23 Thread Paolo Bonzini
Split the PIO transfer across two callbacks, thus pushing the (possibly recursive) call to end_transfer_func up one level and out of the AHCI-specific code. Signed-off-by: Paolo Bonzini --- hw/ide/ahci.c | 7 ++- hw/ide/core.c | 9 ++---

[Qemu-devel] [PATCH v3 31/31] arm/translate-a64: add all single op FP16 to handle_fp_1src_half

2018-02-23 Thread Alex Bennée
This includes FMOV, FABS, FNEG, FSQRT and FRINT[NPMZAXI]. We re-use existing helpers to achieve this. Signed-off-by: Alex Bennée --- v3 - make fabs a bitwise operation - use read_vec_element_i32 to read value - properly wire into disas_fp_1rc ---

[Qemu-devel] [PATCH v9 06/13] s390-ccw: parse and set boot menu options

2018-02-23 Thread Collin L. Walling
Set boot menu options for an s390 guest and store them in the iplb. These options are set via the QEMU command line option: -boot menu=on|off[,splash-time=X] or via the libvirt domain xml: Where X represents some positive integer representing milliseconds. Any value set

[Qemu-devel] [PATCH v9 10/13] s390-ccw: read user input for boot index via the SCLP console

2018-02-23 Thread Collin L. Walling
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 values and is handled appropriately. A prompt will persist until input is entered or the timeout

[Qemu-devel] [PATCH REPOST v1 0/8] Group support and random clean-ups

2018-02-23 Thread Alex Bennée
Hi, This is essentially a re-post but with a wider distribution. There is one extra patch which adds the FP16 1 source data processing. This is for discussion on how best to represent all the different architectural versions by using the second field in the aarch64.risu file. Alex Bennée (8):

[Qemu-devel] [PATCH v9 09/13] s390-ccw: print zipl boot menu

2018-02-23 Thread Collin L. Walling
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 the menu might look like: zIPL v1.37.1-build-20170714 interactive boot menu. 0. default

Re: [Qemu-devel] [PATCH v2 18/36] rbd: Fix use after free in qemu_rbd_set_keypairs() error path

2018-02-23 Thread Kevin Wolf
Am 23.02.2018 um 16:15 hat Eric Blake geschrieben: > On 02/21/2018 07:53 AM, Kevin Wolf wrote: > > If we want to include the invalid option name in the error message, we > > can't free the string earlier than that. > > > > Signed-off-by: Kevin Wolf > > --- > > block/rbd.c | 3

Re: [Qemu-devel] [PATCH v9 13/13] s390-ccw: interactive boot menu for scsi

2018-02-23 Thread Viktor Mihajlovski
On 23.02.2018 16:43, Collin L. Walling wrote: > Interactive boot menu for scsi. This follows a similar procedure > as the interactive menu for eckd dasd. An example follows: > > s390x Enumerated Boot Menu. > > 3 entries detected. Select from index 0 to 2. > > Signed-off-by: Collin L.

[Qemu-devel] [PATCH v1 6/8] contrib/run_risu.sh: don't set -e

2018-02-23 Thread Alex Bennée
As the script is meant to summarise the results at the end it doesn't make sense to bail out at the first error. Signed-off-by: Alex Bennée --- contrib/run_risu.sh | 2 -- 1 file changed, 2 deletions(-) diff --git a/contrib/run_risu.sh b/contrib/run_risu.sh index

Re: [Qemu-devel] [PATCH v9 05/13] s390-ccw: move auxiliary IPL data to separate location

2018-02-23 Thread Collin L. Walling
On 02/23/2018 11:03 AM, Thomas Huth wrote: On 23.02.2018 16:43, Collin L. Walling wrote: The s390-ccw firmware needs some information in support of the boot process which is not available on the native machine. Examples are the netboot firmware load address and now the boot menu parameters.

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 33/67] target/arm: Implement SVE reverse within elements

2018-02-23 Thread Peter Maydell
On 17 February 2018 at 18:22, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > target/arm/helper-sve.h| 14 ++ > target/arm/sve_helper.c| 41 ++--- >

Re: [Qemu-devel] [PATCH v9 00/13] Interactive Boot Menu for DASD and SCSI Guests on s390x

2018-02-23 Thread Viktor Mihajlovski
On 23.02.2018 16:43, Collin L. Walling wrote: > --- [v9] --- > > - only set boot menu opts if a bootindex was specified on cmd > > - Menus for guests with an IPL device that chooses to use the SCSI scheme are >only enabled explicitly for -boot menu=on options (i.e. it will > appropriately

Re: [Qemu-devel] [PATCH v1 4/8] new contrib/generate_all.sh: batch risugen script

2018-02-23 Thread Daniel P . Berrangé
On Fri, Feb 23, 2018 at 03:46:09PM +, Alex Bennée wrote: > This is a simple script for generating all instructions in a given > RISU file. You can split up the batch size by passing a -n N command > line options. For example: > > ./contrib/generate_all.sh -n 2 hp.risu testcases.armv8.2_hp >

Re: [Qemu-devel] proposed release schedule for QEMU 2.12

2018-02-23 Thread Peter Maydell
On 30 January 2018 at 16:25, Peter Maydell wrote: > It seems like it's about time we settled on the dates for the > 2.12 release. I've sketched in a suggestion at: > https://wiki.qemu.org/Planning/2.12 > > which puts softfreeze on the 13th March, hardfreeze a > week

Re: [Qemu-devel] [PATCH v9 05/13] s390-ccw: move auxiliary IPL data to separate location

2018-02-23 Thread Thomas Huth
On 23.02.2018 16:43, Collin L. Walling wrote: > The s390-ccw firmware needs some information in support of the > boot process which is not available on the native machine. > Examples are the netboot firmware load address and now the > boot menu parameters. > > While storing that data in unused

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 35/67] target/arm: Implement SVE Select Vectors Group

2018-02-23 Thread Peter Maydell
On 17 February 2018 at 18:22, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > target/arm/helper-sve.h| 9 > target/arm/sve_helper.c| 55 > ++ >

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 38/67] target/arm: Implement SVE Partition Break Group

2018-02-23 Thread Peter Maydell
On 17 February 2018 at 18:22, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > target/arm/helper-sve.h| 18 > target/arm/sve_helper.c| 247 > + >

Re: [Qemu-devel] [PATCH v1 4/8] new contrib/generate_all.sh: batch risugen script

2018-02-23 Thread Alex Bennée
Daniel P. Berrangé writes: > On Fri, Feb 23, 2018 at 03:46:09PM +, Alex Bennée wrote: >> This is a simple script for generating all instructions in a given >> RISU file. You can split up the batch size by passing a -n N command >> line options. For example: >> >>

Re: [Qemu-devel] [PATCH v1 5/8] contrib/run_risu.sh: allow appending of QEMU_FLAGS

2018-02-23 Thread Peter Maydell
On 23 February 2018 at 15:46, Alex Bennée wrote: > Useful if you want to disable a feature for your run. For example: > > set -x QEMU_FLAGS "-cpu fp16=off" > > Signed-off-by: Alex Bennée > --- > contrib/run_risu.sh | 6 -- > 1 file changed,

Re: [Qemu-devel] [PATCH v1 3/8] aarch64.risu: add cryptographic extensions for v8.2

2018-02-23 Thread Peter Maydell
On 23 February 2018 at 15:46, Alex Bennée wrote: > Signed-off-by: Alex Bennée > --- > aarch64.risu | 32 > 1 file changed, 32 insertions(+) > > diff --git a/aarch64.risu b/aarch64.risu > index 838bded..06a9f3c

Re: [Qemu-devel] [PATCH 3/7] HACK: HobLib: workaround infinite loop

2018-02-23 Thread Laszlo Ersek
On 02/23/18 14:23, marcandre.lur...@redhat.com wrote: > From: Marc-André Lureau > > Without this hack, GetNextHob() loops infinitely with the next patch. > I don't understand the reason. > > The loop is triggered by the GetFirstGuidHob () call. > > CC: Laszlo Ersek

Re: [Qemu-devel] [PATCH RFC 14/14] qapi: Add #if conditions to commands, events, types, visitors

2018-02-23 Thread Markus Armbruster
Marc-Andre Lureau writes: > Hi > > On Mon, Feb 12, 2018 at 8:22 AM, Markus Armbruster wrote: >> Example change to generated code: >> >> diff -rup test-qapi-events.h.old test-qapi-events.h >> --- test-qapi-events.h.old 2018-02-12 07:02:45.672737544

Re: [Qemu-devel] [PATCH 03/10] linux-user: init_guest_space: Clean up if we can't initialize the commpage

2018-02-23 Thread Peter Maydell
On 28 December 2017 at 18:08, Luke Shumaker wrote: > From: Luke Shumaker > > We'll just exit with an error anyway, so it doesn't really matter, but it > is cleaned up in all of the other places were we error out. > > Signed-off-by: Luke Shumaker

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 01/67] target/arm: Enable SVE for aarch64-linux-user

2018-02-23 Thread Richard Henderson
On 02/23/2018 09:00 AM, Alex Bennée wrote: > > Richard Henderson writes: > >> Enable ARM_FEATURE_SVE for the generic "any" cpu. >> >> Signed-off-by: Richard Henderson >> --- >> target/arm/cpu.c | 7 +++ >> target/arm/cpu64.c |

Re: [Qemu-devel] [PATCH 01/10] linux-user: Use #if to only call validate_guest_space for 32-bit ARM target

2018-02-23 Thread Peter Maydell
On 23 February 2018 at 18:35, Peter Maydell wrote: > On 28 December 2017 at 18:08, Luke Shumaker wrote: >> From: Luke Shumaker >> >> Instead of defining a bogus validate_guest_space that always returns 1 on >> targets other

[Qemu-devel] [PATCH] macio: fix NULL pointer dereference when issuing IDE trim

2018-02-23 Thread Mark Cave-Ayland
Commit ef0e64a983 "ide: pass IDEState to trim AIO callback" changed the IDE trim callback from using a BlockBackend to an IDEState but forgot to update the dma_blk_io() call in hw/ide/macio.c accordingly. Without this fix qemu-system-ppc segfaults when issuing an IDE trim command on any of the

Re: [Qemu-devel] [PATCH] loader: don't perform overlapping address check for memory region ROM images

2018-02-23 Thread Peter Maydell
On 23 February 2018 at 18:53, Mark Cave-Ayland wrote: > On 23/02/18 18:04, Peter Maydell wrote: > >> On 23 February 2018 at 11:29, Mark Cave-Ayland >> wrote: >>> >>> All memory region ROM images have a base address of 0 which causes

Re: [Qemu-devel] [PATCH REPOST v1 0/8] Group support and random clean-ups

2018-02-23 Thread Peter Maydell
On 23 February 2018 at 15:46, Alex Bennée wrote: > Hi, > > This is essentially a re-post but with a wider distribution. There is > one extra patch which adds the FP16 1 source data processing. This is for > discussion on how best to represent all the different

Re: [Qemu-devel] [PATCH 01/10] linux-user: Use #if to only call validate_guest_space for 32-bit ARM target

2018-02-23 Thread Peter Maydell
On 28 December 2017 at 18:08, Luke Shumaker wrote: > From: Luke Shumaker > > Instead of defining a bogus validate_guest_space that always returns 1 on > targets other than 32-bit ARM, use #if blocks to only call it on 32-bit ARM > targets. This makes

Re: [Qemu-devel] [PATCH] loader: don't perform overlapping address check for memory region ROM images

2018-02-23 Thread Mark Cave-Ayland
On 23/02/18 18:04, Peter Maydell wrote: On 23 February 2018 at 11:29, Mark Cave-Ayland wrote: All memory region ROM images have a base address of 0 which causes the overlapping address check to fail if more than one memory region ROM image is present, or an

Re: [Qemu-devel] [PATCH v2 27/67] target/arm: Implement SVE Permute - Unpredicated Group

2018-02-23 Thread Richard Henderson
On 02/23/2018 06:34 AM, Peter Maydell wrote: > On 17 February 2018 at 18:22, Richard Henderson > wrote: >> Signed-off-by: Richard Henderson >> --- >> target/arm/helper-sve.h| 23 + >> target/arm/translate-a64.h | 14

[Qemu-devel] [PATCH v3 02/36] block/qapi: Add qcow2 create options to schema

2018-02-23 Thread Kevin Wolf
Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake Reviewed-by: Max Reitz --- qapi/block-core.json | 45 - 1 file changed, 44 insertions(+), 1 deletion(-) diff --git a/qapi/block-core.json

[Qemu-devel] [PATCH v3 01/36] block/qapi: Introduce BlockdevCreateOptions

2018-02-23 Thread Kevin Wolf
This creates a BlockdevCreateOptions union type that will contain all of the options for image creation. We'll start out with an empty struct type BlockdevCreateNotSupported for all drivers. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake Reviewed-by: Max

[Qemu-devel] [PATCH v3 05/36] qcow2: Use BlockdevRef in qcow2_create2()

2018-02-23 Thread Kevin Wolf
Instead of passing a separate BlockDriverState* into qcow2_create2(), make use of the BlockdevRef that is included in BlockdevCreateOptions. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake Reviewed-by: Max Reitz ---

[Qemu-devel] [PATCH v3 00/36] x-blockdev-create for protocols and qcow2

2018-02-23 Thread Kevin Wolf
This series implements a minimal QMP command that allows to create an image file on the protocol level or an image format on a given block node. Eventually, the interface is going to change to some kind of an async command (possibly a (non-)block job), but that will require more work on the job

[Qemu-devel] [PATCH v3 04/36] qcow2: Pass BlockdevCreateOptions to qcow2_create2()

2018-02-23 Thread Kevin Wolf
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 Reviewed-by: Max Reitz --- block/qcow2.c | 190

[Qemu-devel] [PATCH v3 06/36] qcow2: Use QCryptoBlockCreateOptions in qcow2_create2()

2018-02-23 Thread Kevin Wolf
Instead of passing the encryption format name and the QemuOpts down, use the QCryptoBlockCreateOptions contained in BlockdevCreateOptions. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake Reviewed-by: Max Reitz --- block/qcow2.c | 62

[Qemu-devel] [PATCH v3 13/36] block: Make bdrv_is_whitelisted() public

2018-02-23 Thread Kevin Wolf
We'll use a separate source file for image creation, and we need to check there whether the requested driver is whitelisted. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz Reviewed-by: Eric Blake --- include/block/block.h | 1 +

[Qemu-devel] [PATCH v3 17/36] gluster: Support .bdrv_co_create

2018-02-23 Thread Kevin Wolf
This adds the .bdrv_co_create driver callback to gluster, which enables image creation over QMP. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz Reviewed-by: Eric Blake --- qapi/block-core.json | 18 ++- block/gluster.c | 135

[Qemu-devel] [PATCH v3 21/36] rbd: Pass BlockdevOptionsRbd to qemu_rbd_connect()

2018-02-23 Thread Kevin Wolf
With the conversion to a QAPI options object, the function is now prepared to be used in a .bdrv_co_create implementation. Signed-off-by: Kevin Wolf --- block/rbd.c | 109 +--- 1 file changed, 53 insertions(+), 56

[Qemu-devel] [PATCH v3 10/36] test-qemu-opts: Test qemu_opts_to_qdict_filtered()

2018-02-23 Thread Kevin Wolf
Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake Reviewed-by: Max Reitz --- tests/test-qemu-opts.c | 125 + 1 file changed, 125 insertions(+) diff --git a/tests/test-qemu-opts.c

[Qemu-devel] [PATCH v3 25/36] nfs: Use QAPI options in nfs_client_open()

2018-02-23 Thread Kevin Wolf
Using the QAPI visitor to turn all options into QAPI BlockdevOptionsNfs simplifies the code a lot. It will also be useful for implementing the QAPI based .bdrv_co_create callback. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- block/nfs.c | 176

[Qemu-devel] [PATCH v3 16/36] file-win32: Support .bdrv_co_create

2018-02-23 Thread Kevin Wolf
This adds the .bdrv_co_create driver callback to file-win32, which enables image creation over QMP. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz Reviewed-by: Eric Blake --- block/file-win32.c | 45

[Qemu-devel] [PATCH v3 29/36] ssh: Use QAPI BlockdevOptionsSsh object

2018-02-23 Thread Kevin Wolf
Create a BlockdevOptionsSsh object in connect_to_ssh() and take the options from there. 'host_key_check' is still processed separately because it's not in the schema yet. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- block/ssh.c | 136

[Qemu-devel] [PATCH v3 12/36] qcow2: Use visitor for options in qcow2_create()

2018-02-23 Thread Kevin Wolf
Instead of manually creating the BlockdevCreateOptions object, use a visitor to parse the given options into the QAPI object. This involves translation from the old command line syntax to the syntax mandated by the QAPI schema. Option names are still checked against qcow2_create_opts, so only the

[Qemu-devel] [PATCH v3 34/36] block: Fail bdrv_truncate() with negative size

2018-02-23 Thread Kevin Wolf
Most callers have their own checks, but something like this should also be checked centrally. As it happens, x-blockdev-create can pass negative image sizes to format drivers (because there is no QAPI type that would reject negative numbers) and triggers the check added by this patch.

[Qemu-devel] [PATCH v3 33/36] file-posix: Fix no-op bdrv_truncate() with falloc preallocation

2018-02-23 Thread Kevin Wolf
If bdrv_truncate() is called, but the requested size is the same as before, don't call posix_fallocate(), which returns -EINVAL for length zero and would therefore make bdrv_truncate() fail. The problem can be triggered by creating a zero-sized raw image with 'falloc' preallocation mode.

[Qemu-devel] [PATCH v3 36/36] qemu-iotests: Test ssh image creation over QMP

2018-02-23 Thread Kevin Wolf
Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- tests/qemu-iotests/207 | 261 + tests/qemu-iotests/207.out | 75 + tests/qemu-iotests/group | 1 + 3 files changed, 337 insertions(+)

[Qemu-devel] [PATCH v3 30/36] ssh: QAPIfy host-key-check option

2018-02-23 Thread Kevin Wolf
This makes the host-key-check option available in blockdev-add. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- qapi/block-core.json | 63 +++-- block/ssh.c | 88

[Qemu-devel] [PATCH v3 18/36] rbd: Fix use after free in qemu_rbd_set_keypairs() error path

2018-02-23 Thread Kevin Wolf
If we want to include the invalid option name in the error message, we can't free the string earlier than that. Cc: qemu-sta...@nongnu.org Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz Reviewed-by: Eric Blake --- block/rbd.c | 3 ++-

[Qemu-devel] [PATCH v3 31/36] ssh: Pass BlockdevOptionsSsh to connect_to_ssh()

2018-02-23 Thread Kevin Wolf
Move the parsing of the QDict options up to the callers, in preparation for the .bdrv_co_create implementation that directly gets a QAPI type. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- block/ssh.c | 34 +- 1 file

[Qemu-devel] [PATCH v3 32/36] ssh: Support .bdrv_co_create

2018-02-23 Thread Kevin Wolf
This adds the .bdrv_co_create driver callback to ssh, which enables image creation over QMP. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- qapi/block-core.json | 16 - block/ssh.c | 92

[Qemu-devel] [PATCH v3 23/36] rbd: Assign s->snap/image_name in qemu_rbd_open()

2018-02-23 Thread Kevin Wolf
Now that the options are already available in qemu_rbd_open() and not only parsed in qemu_rbd_connect(), we can assign s->snap and s->image_name there instead of passing the fields by reference to qemu_rbd_connect(). Signed-off-by: Kevin Wolf --- block/rbd.c | 14

Re: [Qemu-devel] [edk2] [PATCH 3/7] HACK: HobLib: workaround infinite loop

2018-02-23 Thread Andrew Fish
> On Feb 23, 2018, at 5:23 AM, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > Without this hack, GetNextHob() loops infinitely with the next patch. > I don't understand the reason. > > The loop is triggered by the GetFirstGuidHob () call. > >

Re: [Qemu-devel] [PATCH v2 28/67] target/arm: Implement SVE Permute - Predicates Group

2018-02-23 Thread Richard Henderson
On 02/23/2018 07:15 AM, Peter Maydell wrote: >> +static const uint64_t expand_bit_data[5][2] = { >> +{ 0xull, 0xull }, >> +{ 0x0303030303030303ull, 0x0c0c0c0c0c0c0c0cull }, >> +{ 0x000f000f000f000full, 0x00f000f000f000f0ull }, >> +{

[Qemu-devel] [PATCH v3 07/36] qcow2: Handle full/falloc preallocation in qcow2_create2()

2018-02-23 Thread Kevin Wolf
Once qcow2_create2() can be called directly on an already existing node, we must provide the 'full' and 'falloc' preallocation modes outside of creating the image on the protocol layer. Fortunately, we have preallocated truncate now which can provide this functionality. Signed-off-by: Kevin Wolf

[Qemu-devel] [PATCH v3 08/36] util: Add qemu_opts_to_qdict_filtered()

2018-02-23 Thread Kevin Wolf
This allows, given a QemuOpts for a QemuOptsList that was merged from multiple QemuOptsList, to only consider those options that exist in one specific list. Block drivers need this to separate format-layer create options from protocol-level options. Signed-off-by: Kevin Wolf

[Qemu-devel] [PATCH v3 03/36] qcow2: Let qcow2_create() handle protocol layer

2018-02-23 Thread Kevin Wolf
Currently, qcow2_create() only parses the QemuOpts and then calls qcow2_create2() for the actual image creation, which includes both the creation of the actual file on the file system and writing a valid empty qcow2 image into that file. The plan is that qcow2_create2() becomes the function that

[Qemu-devel] [PATCH v3 11/36] qdict: Introduce qdict_rename_keys()

2018-02-23 Thread Kevin Wolf
A few block drivers will need to rename .bdrv_create options for their QAPIfication, so let's have a helper function for that. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz Reviewed-by: Eric Blake --- include/qapi/qmp/qdict.h | 6

[Qemu-devel] [PATCH v3 22/36] rbd: Support .bdrv_co_create

2018-02-23 Thread Kevin Wolf
This adds the .bdrv_co_create driver callback to rbd, which enables image creation over QMP. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- qapi/block-core.json | 19 ++- block/rbd.c | 146

[Qemu-devel] [PATCH v3 24/36] rbd: Use qemu_rbd_connect() in qemu_rbd_do_create()

2018-02-23 Thread Kevin Wolf
This is almost exactly the same code. The differences are that qemu_rbd_connect() supports BlockdevOptionsRbd.server and that the cache mode is set explicitly. Supporting 'server' is a welcome new feature for image creation. Caching is disabled by default, so leave it that way. Signed-off-by:

[Qemu-devel] [PATCH v3 09/36] test-qemu-opts: Test qemu_opts_append()

2018-02-23 Thread Kevin Wolf
Basic test for merging two QemuOptsLists. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake Reviewed-by: Max Reitz --- tests/test-qemu-opts.c | 128 + 1 file changed, 128 insertions(+)

[Qemu-devel] [PATCH v3 14/36] block: x-blockdev-create QMP command

2018-02-23 Thread Kevin Wolf
This adds a synchronous x-blockdev-create QMP command that can create qcow2 images on a given node name. We don't want to block while creating an image, so this is not the final interface in all aspects, but BlockdevCreateOptionsQcow2 and .bdrv_co_create() are what they actually might look like

[Qemu-devel] [PATCH v3 26/36] nfs: Support .bdrv_co_create

2018-02-23 Thread Kevin Wolf
This adds the .bdrv_co_create driver callback to nfs, which enables image creation over QMP. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- qapi/block-core.json | 16 +++- block/nfs.c | 74

[Qemu-devel] [PATCH v3 20/36] rbd: Remove non-schema options from runtime_opts

2018-02-23 Thread Kevin Wolf
Instead of the QemuOpts in qemu_rbd_connect(), we want to use QAPI objects. As a preparation, fetch those options directly from the QDict that .bdrv_open() supports in the rbd driver and that are not in the schema. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz

[Qemu-devel] [PATCH v3 28/36] sheepdog: Support .bdrv_co_create

2018-02-23 Thread Kevin Wolf
This adds the .bdrv_co_create driver callback to sheepdog, which enables image creation over QMP. Signed-off-by: Kevin Wolf --- qapi/block-core.json | 24 - block/sheepdog.c | 242 +++ 2 files changed, 191 insertions(+),

[Qemu-devel] [PATCH v3 15/36] file-posix: Support .bdrv_co_create

2018-02-23 Thread Kevin Wolf
This adds the .bdrv_co_create driver callback to file, which enables image creation over QMP. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz Reviewed-by: Eric Blake --- qapi/block-core.json | 20 +- block/file-posix.c |

[Qemu-devel] [PATCH v3 19/36] rbd: Factor out qemu_rbd_connect()

2018-02-23 Thread Kevin Wolf
The code to establish an RBD connection is duplicated between open and create. In order to be able to share the code, factor out the code from qemu_rbd_open() as a first step. Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- block/rbd.c | 100

[Qemu-devel] [PATCH v3 27/36] sheepdog: QAPIfy "redundancy" create option

2018-02-23 Thread Kevin Wolf
The "redundancy" option for Sheepdog image creation is currently a string that can encode one or two integers depending on its format, which at the same time implicitly selects a mode. This patch turns it into a QAPI union and converts the string into such a QAPI object before interpreting the

[Qemu-devel] [PATCH v3 35/36] qemu-iotests: Test qcow2 over file image creation with QMP

2018-02-23 Thread Kevin Wolf
Signed-off-by: Kevin Wolf Reviewed-by: Max Reitz --- tests/qemu-iotests/206 | 436 + tests/qemu-iotests/206.out | 209 ++ tests/qemu-iotests/group | 1 + 3 files changed, 646

Re: [Qemu-devel] [PATCH v6 00/23] RISC-V QEMU Port Submission

2018-02-23 Thread Michael Clark
Dear Daniel, We've had this discussion on a recent pull request where some code was going to be copied directly from hw/arm/virt.c to hw/riscv/virt.c and we have subsequently relicensed the recipient file as GPLv2+. This code has not yet been incorporated into the port. Besides naming conventions

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 31/67] target/arm: Implement SVE conditionally broadcast/extract element

2018-02-23 Thread Richard Henderson
On 02/23/2018 07:44 AM, Peter Maydell wrote: >> +/* Similar to the ARM LastActiveElement pseudocode function, except the >> + result is multiplied by the element size. This includes the not found >> + indication; e.g. not found for esz=3 is -8. */ >> +int32_t

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 33/67] target/arm: Implement SVE reverse within elements

2018-02-23 Thread Richard Henderson
On 02/23/2018 07:50 AM, Peter Maydell wrote: > On 17 February 2018 at 18:22, Richard Henderson > wrote: >> Signed-off-by: Richard Henderson >> --- >> target/arm/helper-sve.h| 14 ++ >> target/arm/sve_helper.c| 41

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

2018-02-23 Thread Deepa Srinivasan
Stefan, Kevin - Ping, to take this patch. Thanks. On 01/29/2018 07:51 AM, Stefan Hajnoczi wrote: 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

Re: [Qemu-devel] [PATCH v2 36/67] target/arm: Implement SVE Integer Compare - Vectors Group

2018-02-23 Thread Richard Henderson
On 02/23/2018 08:29 AM, Peter Maydell wrote: > On 17 February 2018 at 18:22, Richard Henderson > wrote: >> Signed-off-by: Richard Henderson >> --- > >> diff --git a/target/arm/sve_helper.c b/target/arm/sve_helper.c >> index

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 38/67] target/arm: Implement SVE Partition Break Group

2018-02-23 Thread Richard Henderson
On 02/23/2018 08:41 AM, Peter Maydell wrote: > On 17 February 2018 at 18:22, Richard Henderson > wrote: >> Signed-off-by: Richard Henderson >> --- >> target/arm/helper-sve.h| 18 >> target/arm/sve_helper.c| 247 >>

Re: [Qemu-devel] [PATCH v2 1/3] s390x/sclp: proper support of larger send and receive masks

2018-02-23 Thread Claudio Imbrenda
On Fri, 23 Feb 2018 11:31:46 +0100 Cornelia Huck wrote: > On Thu, 22 Feb 2018 17:22:57 +0100 > Claudio Imbrenda wrote: > > > Until 67915de9f0383ccf4a ("s390x/event-facility: variable-length > > event masks") we only supported sclp event masks of

Re: [Qemu-devel] [Qemu-block] Limiting coroutine stack usage

2018-02-23 Thread Paolo Bonzini
On 22/02/2018 18:06, John Snow wrote: > > > On 02/22/2018 05:57 AM, Kevin Wolf wrote: >> Am 20.02.2018 um 22:54 hat Paolo Bonzini geschrieben: >>> On 20/02/2018 18:04, Peter Lieven wrote: Hi, I remember we discussed a long time ago to limit the stack usage of all functions

Re: [Qemu-devel] [PATCH v2 0/3] s390x/sclp: 64 bit event masks

2018-02-23 Thread Claudio Imbrenda
On Fri, 23 Feb 2018 11:37:55 +0100 Cornelia Huck wrote: > On Thu, 22 Feb 2018 17:22:56 +0100 > Claudio Imbrenda wrote: > > > Until 67915de9f0383ccf4a ("s390x/event-facility: variable-length > > event masks") we only supported 32bit sclp event

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 08/67] target/arm: Implement SVE Predicate Misc Group

2018-02-23 Thread Peter Maydell
On 17 February 2018 at 18:22, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > target/arm/cpu.h | 3 + > target/arm/helper-sve.h| 3 + > target/arm/sve_helper.c| 86 +++- >

[Qemu-devel] [PATCH] loader: don't perform overlapping address check for memory region ROM images

2018-02-23 Thread Mark Cave-Ayland
All memory region ROM images have a base address of 0 which causes the overlapping address check to fail if more than one memory region ROM image is present, or an existing ROM image is loaded at address 0. Make sure that we ignore the overlapping address check in rom_check_and_register_reset()

Re: [Qemu-devel] [PATCH qemu repost] qmp: Add qom-list-properties to list QOM object properties

2018-02-23 Thread Paolo Bonzini
On 22/02/2018 06:00, Alexey Kardashevskiy wrote: > There is already 'device-list-properties' which does most of the job, > however it does not handle everything returned by qom-list-types such > as machines as they inherit directly from TYPE_OBJECT and not TYPE_DEVICE. > > This adds a new

Re: [Qemu-devel] [PATCH v2 09/67] target/arm: Implement SVE Integer Binary Arithmetic - Predicated Group

2018-02-23 Thread Peter Maydell
On 17 February 2018 at 18:22, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > target/arm/helper-sve.h| 145 + > target/arm/sve_helper.c| 196 >

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 11/67] target/arm: Implement SVE bitwise shift by immediate (predicated)

2018-02-23 Thread Peter Maydell
On 17 February 2018 at 18:22, Richard Henderson wrote: > Signed-off-by: Richard Henderson > --- > target/arm/helper-sve.h| 25 + > target/arm/sve_helper.c| 265 > + >

Re: [Qemu-devel] [PATCH 0/6] vhost-user-test and leak fixes

2018-02-23 Thread Marc-André Lureau
Hi On Fri, Feb 23, 2018 at 12:37 PM, Paolo Bonzini wrote: > On 15/02/2018 22:25, Marc-André Lureau wrote: >> Hi, >> >> The following patches fix a regression introduced in commit >> 218bb57dd79d that prevent ASAN from being detected & used. There is >> also a works around

Re: [Qemu-devel] [PATCH 0/6] vhost-user-test and leak fixes

2018-02-23 Thread Paolo Bonzini
On 15/02/2018 22:25, Marc-André Lureau wrote: > Hi, > > The following patches fix a regression introduced in commit > 218bb57dd79d that prevent ASAN from being detected & used. There is > also a works around for a GCC ASAN optimization bug. A few test leaks > are fixed, and a few patches

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 03/67] target/arm: Add SVE decode skeleton

2018-02-23 Thread Peter Maydell
On 17 February 2018 at 18:22, Richard Henderson wrote: > Including only 4, as-yet unimplemented, instruction patterns > so that the whole thing compiles. > > Signed-off-by: Richard Henderson > --- > target/arm/translate-a64.c | 11

Re: [Qemu-devel] [Qemu-arm] [PATCH v2 03/67] target/arm: Add SVE decode skeleton

2018-02-23 Thread Peter Maydell
On 23 February 2018 at 11:40, Peter Maydell wrote: > I realized while working through the rest of the series that this is > too early to do the sve_access_check() and fp_access_check(). Those > only apply to instructions which actually exist, so we mustn't > do the

<    1   2   3   4   >