Re: [Qemu-devel] [PATCH v2 1/3] q35: set split kernel irqchip as default

2019-04-26 Thread Paolo Bonzini
> > In my testing it looks like KVM advertises supporting the KVM_IRQFD > > resample feature, but vfio never gets the unmask notification, so the > > device remains with DisINTx set and no further interrupts are > > generated. Do we expect KVM's IRQFD with resampler to work in the > > split IRQ

Re: [Qemu-devel] [PATCH 0/6] tests/qemu-iotests: Run basic iotests during "make check"

2019-04-26 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20190424103747.10173-1-th...@redhat.com/ Hi, This series failed the asan build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. === TEST SCRIPT BEGIN === #!/bin/bash time ma

Re: [Qemu-devel] Following up questions related to QEMU and I/O Thread

2019-04-26 Thread Paolo Bonzini
> Thanks Stefan and Paolo for your response and advice! > > Hi Paolo, > > As to the virtio-scsi batch I/O submission feature in QEMU which you > mentioned, is this feature turned on by default in QEMU 2.9 or there is a > tunable parameters to turn on/off the feature? Yes, it is available by de

[Qemu-devel] [Bug 1701835] Re: floating-point operation bugs in qemu-alpha

2019-04-26 Thread Richard Henderson
There is quite a bit missing for proper user-level emulation. Please try https://patchwork.ozlabs.org/patch/1091847/ ** Changed in: qemu Assignee: (unassigned) => Richard Henderson (rth) ** Changed in: qemu Status: New => In Progress -- You received this bug notification because yo

[Qemu-devel] [PATCH 2/2] target/alpha: Fix user-only floating-point exceptions

2019-04-26 Thread Richard Henderson
Record the software fp control register, as set by the osf_setsysinfo syscall. Add those masked exceptions to fpcr_exc_enable. Do not raise a signal for masked fp exceptions. Signed-off-by: Richard Henderson --- linux-user/syscall_defs.h | 3 +- target/alpha/cpu.h| 42 ++

[Qemu-devel] [PATCH 0/2] target/alpha: Fix bug 1701835

2019-04-26 Thread Richard Henderson
Serves me right for really only being interested in system testing. Anyway, in order to emulate user-only properly, we have to do all of the crazy things the kernel does, forced on us by the crazy DEC hardware engineers. r~ Richard Henderson (2): target/alpha: Clean up alpha_cpu_dump_state

[Qemu-devel] [PATCH 1/2] target/alpha: Clean up alpha_cpu_dump_state

2019-04-26 Thread Richard Henderson
Drop the "RI" and "FIR" prefixes; use only the normal linux names. Add the FPCR to the dump. Signed-off-by: Richard Henderson --- target/alpha/helper.c | 19 ++- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/target/alpha/helper.c b/target/alpha/helper.c index 720

Re: [Qemu-devel] Following up questions related to QEMU and I/O Thread

2019-04-26 Thread Wei Li
Thanks Stefan and Paolo for your response and advice! Hi Paolo, As to the virtio-scsi batch I/O submission feature in QEMU which you mentioned, is this feature turned on by default in QEMU 2.9 or there is a tunable parameters to turn on/off the feature? Thanks, Wei On 4/26/19, 1:14 AM, "Paol

Re: [Qemu-devel] [Qemu-block] [PATCH for-next 0/2] qemu-img: Make create hint at protocol options

2019-04-26 Thread John Snow
On 4/13/19 11:20 AM, Max Reitz wrote: > https://bugzilla.redhat.com/show_bug.cgi?id=1698863 reports that while > "qemu-img create -f raw" supports the "preallocation" option, it is not > listed under "-o help". > > It turns out it is, but only if you specify a target filename. Users > may not

[Qemu-devel] [PATCH v3 0/2] docs/interop/bitmaps: rewrite and modernize doc

2019-04-26 Thread John Snow
The documentation as written in the 4.0 release is not quite correct as of the 4.0 release; though thanks to backwards compatibility it's not quite wrong either. It is suitable for inclusion in 4.0.1, or any downstream that packages 4.0. This patch is an attempt at a nearly full rewrite that revit

[Qemu-devel] [PATCH v3 2/2] docs/interop/bitmaps: rewrite and modernize doc

2019-04-26 Thread John Snow
This just about rewrites the entirety of the bitmaps.rst document to make it consistent with the 4.0 release. I have added new features seen in the 4.0 release, as well as tried to clarify some points that keep coming up when discussing this feature both in-house and upstream. Yes, it's a lot long

[Qemu-devel] [PATCH v3 1/2] Makefile: add nit-picky mode to sphinx-build

2019-04-26 Thread John Snow
If we add references that don't resolve (or accidentally remove them), it will be helpful to have an error message alerting us to that. Turn warnings into errors so we can be alerted to problems in building the documentation when they arise. Signed-off-by: John Snow --- Makefile | 2 +- 1 file

Re: [Qemu-devel] [PATCH for-4.1] block: Use bdrv_unref_child() for all children in bdrv_close()

2019-04-26 Thread Max Reitz
On 31.03.19 13:17, Alberto Garcia wrote: > bdrv_unref_child() does the following things: > > - Updates the child->bs->inherits_from pointer. > - Calls bdrv_detach_child() to remove the BdrvChild from bs->children. > - Calls bdrv_unref() to unref the child BlockDriverState. > > When bdrv_unr

Re: [Qemu-devel] [RFC PATCH v1 08/10] KVM: X86: Introduce KVM_HC_PAGE_ENC_STATUS hypercall

2019-04-26 Thread Lendacky, Thomas
On 4/24/19 11:10 AM, Singh, Brijesh wrote: > The hypercall can be used by the SEV guest to notify the page encryption This hyercall is used by the SEV guest to notify a change in the page... > status to the hypervisor. The hypercall should be invoked only when > the encryption attribute is change

Re: [Qemu-devel] [PATCH for-4.1] commit: Use bdrv_append() in commit_start()

2019-04-26 Thread Max Reitz
On 03.04.19 16:37, Alberto Garcia wrote: > This function combines bdrv_set_backing_hd() and bdrv_replace_node() > so we can use it to simplify the code a bit in commit_start(). > > Signed-off-by: Alberto Garcia > --- > block/commit.c | 11 +-- > 1 file changed, 1 insertion(+), 10 deletio

Re: [Qemu-devel] [RFC PATCH v1 06/10] KVM: SVM: Add KVM_SEV_RECEIVE_FINISH command

2019-04-26 Thread Lendacky, Thomas
On 4/24/19 11:10 AM, Singh, Brijesh wrote: > The command finalize the guest receiving process and make the SEV guest > ready for the execution. > > Cc: Thomas Gleixner > Cc: Ingo Molnar > Cc: "H. Peter Anvin" > Cc: Paolo Bonzini > Cc: "Radim Krčmář" > Cc: Joerg Roedel > Cc: Borislav Petkov

Re: [Qemu-devel] [RFC PATCH v1 05/10] KVM: SVM: Add KVM_SEV_RECEIVE_UPDATE_DATA command

2019-04-26 Thread Lendacky, Thomas
On 4/24/19 11:10 AM, Singh, Brijesh wrote: > The command is used for copying the incoming buffer into the > SEV guest memory space. > > Cc: Thomas Gleixner > Cc: Ingo Molnar > Cc: "H. Peter Anvin" > Cc: Paolo Bonzini > Cc: "Radim Krčmář" > Cc: Joerg Roedel > Cc: Borislav Petkov > Cc: Tom Le

Re: [Qemu-devel] [PATCH for-4.1] block: Assert that drv->bdrv_child_perm is set in bdrv_child_perm()

2019-04-26 Thread Max Reitz
On 04.04.19 13:29, Alberto Garcia wrote: > There is no need to check for this because all block drivers that have > children implement bdrv_child_perm and all callers already ensure that > bs->drv is set. > > Furthermore, if this check would fail then the callers would end up > with uninitialized

Re: [Qemu-devel] [RFC PATCH v1 04/10] KVM: SVM: Add support for KVM_SEV_RECEIVE_START command

2019-04-26 Thread Lendacky, Thomas
On 4/24/19 11:10 AM, Singh, Brijesh wrote: > The command is used to create encryption context for the incoming create the encryption context for an incoming > SEV guest. The encryption context can be later unused by the hypervisor can be later used by > to import the incoming data into the SEV

Re: [Qemu-devel] [PATCH v2 1/3] q35: set split kernel irqchip as default

2019-04-26 Thread Alex Williamson
On Fri, 26 Apr 2019 13:27:44 -0600 Alex Williamson wrote: > On Thu, 20 Dec 2018 13:40:35 +0800 > Peter Xu wrote: > > > Starting from QEMU 4.0, let's specify "split" as the default value for > > kernel-irqchip. > > > > So for QEMU>=4.0 we'll have: allowed=Y,required=N,split=Y > >for QEMU<=3

Re: [Qemu-devel] [PATCH for-4.1 v2 2/2] iotests: Check that images are in read-only mode after block-commit

2019-04-26 Thread Max Reitz
On 11.04.19 14:32, Alberto Garcia wrote: > This tests the fix from the previous patch. > > Signed-off-by: Alberto Garcia > --- > tests/qemu-iotests/249 | 115 > + > tests/qemu-iotests/249.out | 35 ++ > tests/qemu-iotests/group |

Re: [Qemu-devel] [RFC PATCH v1 01/10] KVM: SVM: Add KVM_SEV SEND_START command

2019-04-26 Thread Borislav Petkov
On Fri, Apr 26, 2019 at 02:29:31PM +, Singh, Brijesh wrote: > Yes that's doable but I am afraid that caching the value may lead us to > wrong path and also divergence from the SEV API spec. The spec says the > returned length is a minimum length but its possible that caller can > give a bigger

Re: [Qemu-devel] [PATCH for-4.1 v2 1/2] commit: Make base read-only if there is an early failure

2019-04-26 Thread Max Reitz
On 11.04.19 14:32, Alberto Garcia wrote: > You can reproduce this by passing an invalid filter-node-name (like > "1234") to block-commit. In this case the base image is put in > read-write mode but is never reset back to read-only. > > Signed-off-by: Alberto Garcia > --- > block/commit.c | 3 +++

Re: [Qemu-devel] [RFC PATCH v1 02/10] KVM: SVM: Add KVM_SEND_UPDATE_DATA command

2019-04-26 Thread Lendacky, Thomas
On 4/24/19 11:10 AM, Singh, Brijesh wrote: > The command is used for encrypting the guest memory region using the > encryption > context created with KVM_SEV_SEND_START. > > Cc: Thomas Gleixner > Cc: Ingo Molnar > Cc: "H. Peter Anvin" > Cc: Paolo Bonzini > Cc: "Radim Krčmář" > Cc: Joerg Roed

[Qemu-devel] [Bug 1826599] [NEW] qemu crashes with HV_ERROR with any guest when using HVF on macos

2019-04-26 Thread Ben Wibking
Public bug reported: qemu reliably crashes (after some unknown amount of time) for any guest I've run on macOS (10.14.4) with HVF acceleration. I'm using the latest development tree: % qemu-system-x86_64 --version QEMU emulator version 4.0.50 (v4.0.0-rc4-52-g3284aa1281-dirty) Copyright (c) 2003-2

Re: [Qemu-devel] [PATCH v2 1/3] q35: set split kernel irqchip as default

2019-04-26 Thread Alex Williamson
On Thu, 20 Dec 2018 13:40:35 +0800 Peter Xu wrote: > Starting from QEMU 4.0, let's specify "split" as the default value for > kernel-irqchip. > > So for QEMU>=4.0 we'll have: allowed=Y,required=N,split=Y >for QEMU<=3.1 we'll have: allowed=Y,required=N,split=N >(omitting all the "kernel_i

Re: [Qemu-devel] [PATCH v6 5/5] block/backup: refactor: split out backup_calculate_cluster_size

2019-04-26 Thread Max Reitz
On 15.04.19 16:49, Vladimir Sementsov-Ogievskiy wrote: > Split out cluster_size calculation. Move copy-bitmap creation above > block-job creation, as we are going to share it with upcoming > backup-top filter, which also should be created before actual block job > creation. > > Also, while being h

Re: [Qemu-devel] [PATCH v2 0/2] docs/interop/bitmaps: rewrite and modernize doc

2019-04-26 Thread John Snow
On 4/23/19 2:10 PM, Vladimir Sementsov-Ogievskiy wrote: > 23.04.2019 1:17, John Snow wrote: >> The documentation as written in the 4.0 release is not quite correct as >> of the 4.0 release; though thanks to backwards compatibility it's not >> quite wrong either. It is suitable for inclusion in 4

Re: [Qemu-devel] [PATCH v6 4/5] block/backup: unify different modes code path

2019-04-26 Thread Max Reitz
On 15.04.19 16:49, Vladimir Sementsov-Ogievskiy wrote: > Do full, top and incremental mode copying all in one place. This > unifies the code path and helps further improvements. > > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > block/backup.c | 43 ++

[Qemu-devel] [PULL 0/2] target/hppa patch queue

2019-04-26 Thread Richard Henderson
The following changes since commit 3284aa128153750f14a61e8a96fd085e6f2999b6: Merge remote-tracking branch 'remotes/lersek/tags/edk2-pull-2019-04-22' into staging (2019-04-24 13:19:41 +0100) are available in the Git repository at: https://github.com/rth7680/qemu.git tags/pull-hpp

[Qemu-devel] [PULL 2/2] target/hppa: Always return EXCP_DMAR for protection id trap

2019-04-26 Thread Richard Henderson
From: Nick Hudson The EXCP_DMP trap is considered legacy. "In PA-RISC 1.1 (Second Edition) and later revisions, processors must use traps 26, 27,and 28 which provide equivalent functionality" Signed-off-by: Nick Hudson Message-Id: <20190423063621.8203-3-nick.hud...@gmx.co.uk> Signed-off-by: Ri

[Qemu-devel] [PULL 1/2] target/hppa: Implement Fast TLB Insert instructions

2019-04-26 Thread Richard Henderson
From: Nick Hudson These instructions are present on pcxl and pcxl2 machines, and are used by NetBSD and OpenBSD. See https://parisc.wiki.kernel.org/images-parisc/a/a9/Pcxl2_ers.pdf page 13-9 (195/206) Signed-off-by: Nick Hudson Message-Id: <20190423063621.8203-2-nick.hud...@gmx.co.u

Re: [Qemu-devel] [PATCH v6 3/5] block/backup: refactor and tolerate unallocated cluster skipping

2019-04-26 Thread Max Reitz
On 15.04.19 16:49, Vladimir Sementsov-Ogievskiy wrote: > Split allocation checking to separate function and reduce nesting. > Consider bdrv_is_allocated() fail as allocated area, as copying more > than needed is not wrong (and we do it anyway) and seems better than > fail the whole job. And, most p

Re: [Qemu-devel] [PATCH v6 1/5] block/backup: simplify backup_incremental_init_copy_bitmap

2019-04-26 Thread Max Reitz
On 15.04.19 16:49, Vladimir Sementsov-Ogievskiy wrote: > Simplify backup_incremental_init_copy_bitmap using the function > bdrv_dirty_bitmap_next_dirty_area. > > Note: move to job->len instead of bitmap size: it should not matter but > less code. > > Signed-off-by: Vladimir Sementsov-Ogievskiy >

Re: [Qemu-devel] [PULL 00/15] tcg patch queue

2019-04-26 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20190426172421.27133-1-richard.hender...@linaro.org/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20190426172421.27133-1-richard.hender...@linaro.org Subject: [Qemu-devel] [PULL

[Qemu-devel] [PULL 14/15] tcg/arm: Restrict constant pool displacement to 12 bits

2019-04-26 Thread Richard Henderson
This will not necessarily restrict the size of the TB, since for v7 the majority of constant pool usage is for calls from the out-of-line ldst code, which is already at the end of the TB. But this does allow us to save one insn per reference on the off-chance. Signed-off-by: Richard Henderson --

[Qemu-devel] [PULL 08/15] tcg: Hoist max_insns computation to tb_gen_code

2019-04-26 Thread Richard Henderson
In order to handle TB's that translate to too much code, we need to place the control of the length of the translation in the hands of the code gen master loop. Reviewed-by: Alistair Francis Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- include/exec/exec-all.h

[Qemu-devel] [PULL 13/15] tcg/ppc: Allow the constant pool to overflow at 32k

2019-04-26 Thread Richard Henderson
There is no point in coding for a 2GB offset when the max TB size is already limited to 64k. If we further restrict to 32k then we can eliminate the extra ADDIS instruction. Signed-off-by: Richard Henderson --- tcg/ppc/tcg-target.inc.c | 28 ++-- 1 file changed, 10 inser

[Qemu-devel] [PULL 11/15] tcg: Restart TB generation after constant pool overflow

2019-04-26 Thread Richard Henderson
This is part b of relocation overflow handling. Signed-off-by: Richard Henderson --- tcg/tcg-pool.inc.c | 12 +++- tcg/tcg.c | 9 + 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/tcg/tcg-pool.inc.c b/tcg/tcg-pool.inc.c index 7af5513ff3..4eaa84b631 10064

[Qemu-devel] [PULL 12/15] tcg: Restart TB generation after out-of-line ldst overflow

2019-04-26 Thread Richard Henderson
This is part c of relocation overflow handling. Signed-off-by: Richard Henderson --- tcg/aarch64/tcg-target.inc.c | 16 ++-- tcg/arm/tcg-target.inc.c | 16 ++-- tcg/i386/tcg-target.inc.c| 6 -- tcg/mips/tcg-target.inc.c| 6 -- tcg/ppc/tcg-target.inc.

[Qemu-devel] [PULL 05/15] tcg/i386: Support INDEX_op_extract2_{i32, i64}

2019-04-26 Thread Richard Henderson
Signed-off-by: Richard Henderson --- tcg/i386/tcg-target.h | 4 ++-- tcg/i386/tcg-target.inc.c | 11 +++ 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/tcg/i386/tcg-target.h b/tcg/i386/tcg-target.h index 2c58eaa9ed..241bf19413 100644 --- a/tcg/i386/tcg-target.h +++ b

[Qemu-devel] [PULL 09/15] tcg: Restart after TB code generation overflow

2019-04-26 Thread Richard Henderson
If a TB generates too much code, try again with fewer insns. Fixes: https://bugs.launchpad.net/bugs/1824853 Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- accel/tcg/translate-all.c | 38 -- tcg/tcg.c | 4 2 file

[Qemu-devel] [PULL 06/15] tcg/arm: Support INDEX_op_extract2_i32

2019-04-26 Thread Richard Henderson
Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- tcg/arm/tcg-target.h | 2 +- tcg/arm/tcg-target.inc.c | 25 + 2 files changed, 26 insertions(+), 1 deletion(-) diff --git a/tcg/arm/tcg-target.h b/tcg/arm/tcg-target.h index 4ee6c98958..17e7713

[Qemu-devel] [PULL 15/15] cputlb: Fix io_readx() to respect the access_type

2019-04-26 Thread Richard Henderson
From: Shahab Vahedi This change adapts io_readx() to its input access_type. Currently io_readx() treats any memory access as a read, although it has an input argument "MMUAccessType access_type". This results in: 1) Calling the tlb_fill() only with MMU_DATA_LOAD 2) Considering only entry->addr_r

[Qemu-devel] [PULL 04/15] tcg: Use extract2 in tcg_gen_deposit_{i32, i64}

2019-04-26 Thread Richard Henderson
Signed-off-by: Richard Henderson --- tcg/tcg-op.c | 34 ++ 1 file changed, 30 insertions(+), 4 deletions(-) diff --git a/tcg/tcg-op.c b/tcg/tcg-op.c index fbc70649dd..a00d1df37e 100644 --- a/tcg/tcg-op.c +++ b/tcg/tcg-op.c @@ -611,9 +611,22 @@ void tcg_gen_deposit

[Qemu-devel] [PULL 03/15] tcg: Use deposit and extract2 in tcg_gen_shifti_i64

2019-04-26 Thread Richard Henderson
Signed-off-by: Richard Henderson --- tcg/tcg-op.c | 47 --- 1 file changed, 24 insertions(+), 23 deletions(-) diff --git a/tcg/tcg-op.c b/tcg/tcg-op.c index deacc63e3b..fbc70649dd 100644 --- a/tcg/tcg-op.c +++ b/tcg/tcg-op.c @@ -1355,31 +1355,32 @@ sta

[Qemu-devel] [PULL 07/15] tcg/aarch64: Support INDEX_op_extract2_{i32, i64}

2019-04-26 Thread Richard Henderson
Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson --- tcg/aarch64/tcg-target.h | 4 ++-- tcg/aarch64/tcg-target.inc.c | 11 +++ 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/tcg/aarch64/tcg-target.h b/tcg/aarch64/tcg-target.h index 6600a54a02..ce

[Qemu-devel] [PULL 02/15] tcg: Add INDEX_op_extract2_{i32,i64}

2019-04-26 Thread Richard Henderson
This will let backends implement the double-word shift operation. Reviewed-by: David Hildenbrand Signed-off-by: Richard Henderson --- tcg/aarch64/tcg-target.h | 2 ++ tcg/arm/tcg-target.h | 1 + tcg/i386/tcg-target.h| 2 ++ tcg/mips/tcg-target.h| 2 ++ tcg/ppc/tcg-target.h |

[Qemu-devel] [PULL 10/15] tcg: Restart TB generation after relocation overflow

2019-04-26 Thread Richard Henderson
If the TB generates too much code, such that backend relocations overflow, try again with a smaller TB. In support of this, move relocation processing from a random place within tcg_out_op, in the handling of branch opcodes, to a new function at the end of tcg_gen_code. This is not a complete sol

[Qemu-devel] [PULL 01/15] tcg: Implement tcg_gen_extract2_{i32, i64}

2019-04-26 Thread Richard Henderson
From: David Hildenbrand Will be helpful for s390x. Input 128 bit and output 64 bit only, which is sufficient for now. Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Signed-off-by: David Hildenbrand Message-Id: <20190225154204.26751-1-da...@redhat.com> [rth: Add matching tc

[Qemu-devel] [PULL 00/15] tcg patch queue

2019-04-26 Thread Richard Henderson
The following changes since commit 3284aa128153750f14a61e8a96fd085e6f2999b6: Merge remote-tracking branch 'remotes/lersek/tags/edk2-pull-2019-04-22' into staging (2019-04-24 13:19:41 +0100) are available in the Git repository at: https://github.com/rth7680/qemu.git tags/pull-tc

Re: [Qemu-devel] [PATCH v3 11/13] tests: acpi: add simple arm/virt testcase

2019-04-26 Thread Laszlo Ersek
On 04/25/19 07:34, Igor Mammedov wrote: > adds simple arm/virt test case that starts guest with > bios-tables-test.aarch64.iso.qcow2 boot image which > initializes UefiTestSupport* structure in RAM once > guest is booted. > > * see commit: tests: acpi: add acpi_find_rsdp_address_uefi() helper >

Re: [Qemu-devel] [PATCH 3/4] tests: fw_cfg: add reboot_timeout test case

2019-04-26 Thread Laszlo Ersek
On 04/25/19 12:23, Philippe Mathieu-Daudé wrote: > On 4/25/19 10:29 AM, Li Qiang wrote: >> >> >> Gerd Hoffmann mailto:kra...@redhat.com>> 于2019年4月 >> 25日周四 下午4:15写道: >> >> On Wed, Apr 24, 2019 at 09:16:56AM +0800, Li Qiang wrote: >> > Thomas Huth mailto:th...@redhat.com>> 于2019年4 >> 月24

Re: [Qemu-devel] [PATCH 3/4] tests: fw_cfg: add reboot_timeout test case

2019-04-26 Thread Laszlo Ersek
On 04/25/19 10:15, Gerd Hoffmann wrote: > On Wed, Apr 24, 2019 at 09:16:56AM +0800, Li Qiang wrote: >> Thomas Huth 于2019年4月24日周三 上午12:29写道: >> >>> Is this endianess-safe? Or do you need to byteswap reboot_timeout if the >>> host and guest endianess does not match? >> >> Good question! >> >> IIUC,

Re: [Qemu-devel] [PATCH 4/6] cirrus / travis: Add gnu-sed and bash for macOS and FreeBSD

2019-04-26 Thread Laszlo Ersek
(+Dan) On 04/25/19 08:00, Thomas Huth wrote: > On 24/04/2019 23.29, Wainer dos Santos Moschetta wrote: >> Hello Thomas, >> >> On 04/24/2019 07:37 AM, Thomas Huth wrote: >>> We are going to enable the qemu-iotests during "make check" again, >>> and for running the iotests, we need bash and gnu-sed.

Re: [Qemu-devel] [PATCH v3 11/13] tests: acpi: add simple arm/virt testcase

2019-04-26 Thread Wei Xu
Hi Igor, On 4/26/2019 12:54 PM, Igor Mammedov wrote: > On Fri, 26 Apr 2019 00:51:56 +0800 > x00249684 wrote: > >> Hi Igor, >> >> +static void test_acpi_virt_tcg(void) >> +{ >> +test_data data = { >> +.machine = "virt", >> +.uefi_fl1 = "pc-bios/edk2-aarch64-code.fd", >> +

[Qemu-devel] [PATCH v4 09/10] block/pflash_cfi02: Implement erase suspend/resume

2019-04-26 Thread Stephen Checkoway
During a sector erase (but not a chip erase), the embeded erase program can be suspended. Once suspended, the sectors not selected for erasure may be read and programmed. Autoselect mode is allowed during erase suspend mode. Presumably, CFI queries are similarly allowed so this commit allows them a

[Qemu-devel] [PATCH v4 10/10] block/pflash_cfi02: Use the chip erase time specified in the CFI table

2019-04-26 Thread Stephen Checkoway
When erasing the chip, use the typical time specified in the CFI table rather than arbitrarily selecting 5 seconds. Since the currently unconfigurable value set in the table is 12, this means a chip erase takes 4096 ms so this isn't a big change in behavior. Signed-off-by: Stephen Checkoway ---

[Qemu-devel] [PATCH v4 08/10] block/pflash_cfi02: Implement multi-sector erase

2019-04-26 Thread Stephen Checkoway
After two unlock cycles and a sector erase command, the AMD flash chips start a 50 us erase time out. Any additional sector erase commands add a sector to be erased and restart the 50 us timeout. During the timeout, status bit DQ3 is cleared. After the time out, DQ3 is asserted during erasure. Sig

[Qemu-devel] [PATCH v4 04/10] block/pflash_cfi02: Implement intereleaved flash devices

2019-04-26 Thread Stephen Checkoway
It's common for multiple narrow flash chips to be hooked up in parallel to support wider buses. For example, four 8-bit wide flash chips (x8) may be combined in parallel to produce a 32-bit wide device. Similarly, two 16-bit wide chips (x16) may be combined. This commit introduces `device-width` a

[Qemu-devel] [PATCH v4 05/10] block/pflash_cfi02: Implement nonuniform sector sizes

2019-04-26 Thread Stephen Checkoway
Some flash chips support sectors of different sizes. For example, the AMD AM29LV160DT has 31 64 kB sectors, one 32 kB sector, two 8 kB sectors, and a 16 kB sector, in that order. The AM29LV160DB has those in the reverse order. The `num-blocks` and `sector-length` properties work exactly as they di

[Qemu-devel] [PATCH v4 06/10] block/pflash_cfi02: Fix CFI in autoselect mode

2019-04-26 Thread Stephen Checkoway
After a flash device enters CFI mode from autoselect mode, the reset command returns the device to autoselect mode. An additional reset command is necessary to return to read array mode. Signed-off-by: Stephen Checkoway Acked-by: Thomas Huth --- hw/block/pflash_cfi02.c | 21 +-

[Qemu-devel] [PATCH v4 02/10] block/pflash_cfi02: Refactor, NFC intended

2019-04-26 Thread Stephen Checkoway
Simplify and refactor for upcoming commits. In particular, pull out all of the code to modify the status into simple helper functions. Status handling becomes more complex once multiple chips are interleaved to produce a single device. No change in functionality is intended with this commit. Sign

[Qemu-devel] [PATCH v4 03/10] block/pflash_cfi02: Fix command address comparison

2019-04-26 Thread Stephen Checkoway
Most AMD commands only examine 11 bits of the address. This masks the addresses used in the comparison to 11 bits. The exceptions are word or sector addresses which use offset directly rather than the shifted offset, boff. Signed-off-by: Stephen Checkoway Acked-by: Thomas Huth --- hw/block/pfla

[Qemu-devel] [PATCH v4 07/10] block/pflash_cfi02: Fix reset command not ignored during erase

2019-04-26 Thread Stephen Checkoway
When the flash device is performing a chip erase, all commands are ignored. When it is performing a sector erase, only the erase suspend command is valid, which is currently not supported. In particular, the reset command should not cause the device to reset to read array mode while programming is

[Qemu-devel] [PATCH v4 01/10] block/pflash_cfi02: Add test for supported commands

2019-04-26 Thread Stephen Checkoway
Test the AMD command set for parallel flash chips. This test uses an ARM musicpal board with a pflash drive to test the following list of currently-supported commands. - Autoselect - CFI - Sector erase - Chip erase - Program - Unlock bypass - Reset Signed-off-by: Stephen Checkoway --- tests/Make

[Qemu-devel] [PATCH v4 00/10] block/pflash_cfi02: Implement missing AMD pflash functionality

2019-04-26 Thread Stephen Checkoway
The goal of this patch series implement the following AMD command-set parallel flash functionality: - flash interleaving; - nonuniform sector sizes; - erase suspend/resume commands; and - multi-sector erase. During refactoring and implementation, I discovered several bugs that are fixed here as we

Re: [Qemu-devel] [PATCH 1/3] ram-encrypted-notifier: Introduce a RAM block encrypted notifier

2019-04-26 Thread Janakarajan Natarajan
On 4/26/19 7:29 AM, Igor Mammedov wrote: > On Thu, 25 Apr 2019 22:58:18 + > "Natarajan, Janakarajan" wrote: > >> A client can register to this notifier to know whether the newly added or >> removed memory region is marked as encrypted. This information is needed >> for the SEV guest launch. In

Re: [Qemu-devel] [PULL 00/11] Machine queue, 2019-04-25

2019-04-26 Thread Peter Maydell
On Thu, 25 Apr 2019 at 18:57, Eduardo Habkost wrote: > > The following changes since commit 3284aa128153750f14a61e8a96fd085e6f2999b6: > > Merge remote-tracking branch 'remotes/lersek/tags/edk2-pull-2019-04-22' > into staging (2019-04-24 13:19:41 +0100) > > are available in the Git repository at

[Qemu-devel] [Bug 1826568] [NEW] RISC-V Disassembler/translator instruction decoding disagreement

2019-04-26 Thread Floyd42
Public bug reported: When running QEMU V3.1.0 for platform RISC-V, 64bit, Spike V1.10 with "-d in_asm -singlestep -D qemu_log.txt", my (faulty) test code brought up this message in the logs: 0x8002cade: 05139517e2bf illegal Disassembler disagrees with translator ove

Re: [Qemu-devel] Using --enable-kvm fails with WindowsXP guest on an AMD host (works on Intel host)

2019-04-26 Thread balducci
(apologies if this doesn't get properly threaded into: http://lists.nongnu.org/archive/html/qemu-devel/2019-04/msg03407.html) > After upgrading host (Gentoo Linux) a Windows XP guest can't boot anymore. > > Some findings while testing: > > * XP image boots & works OK on an Intel machine (Gentoo Li

Re: [Qemu-devel] [RFC PATCH v1 01/10] KVM: SVM: Add KVM_SEV SEND_START command

2019-04-26 Thread Singh, Brijesh
On 4/26/19 9:10 AM, Borislav Petkov wrote: > On Wed, Apr 24, 2019 at 04:09:59PM +, Singh, Brijesh wrote: >> The command is used to create an outgoing SEV guest encryption context. >> >> Cc: Thomas Gleixner >> Cc: Ingo Molnar >> Cc: "H. Peter Anvin" >> Cc: Paolo Bonzini >> Cc: "Radim Krčmá

Re: [Qemu-devel] [RFC PATCH v1 01/10] KVM: SVM: Add KVM_SEV SEND_START command

2019-04-26 Thread Borislav Petkov
On Wed, Apr 24, 2019 at 04:09:59PM +, Singh, Brijesh wrote: > The command is used to create an outgoing SEV guest encryption context. > > Cc: Thomas Gleixner > Cc: Ingo Molnar > Cc: "H. Peter Anvin" > Cc: Paolo Bonzini > Cc: "Radim Krčmář" > Cc: Joerg Roedel > Cc: Borislav Petkov > Cc:

Re: [Qemu-devel] [PATCH for-4.1] block: Use bdrv_unref_child() for all children in bdrv_close()

2019-04-26 Thread Alberto Garcia
ping On Sun 31 Mar 2019 01:17:47 PM CEST, Alberto Garcia wrote: > bdrv_unref_child() does the following things: > > - Updates the child->bs->inherits_from pointer. > - Calls bdrv_detach_child() to remove the BdrvChild from bs->children. > - Calls bdrv_unref() to unref the child BlockDriverSt

Re: [Qemu-devel] [PATCH for-4.1 v2 0/2] commit: Make base read-only if there is an early failure

2019-04-26 Thread Alberto Garcia
ping On Thu 11 Apr 2019 02:32:26 PM CEST, Alberto Garcia wrote: > Hi, > > this is the same patch I posted yesterday, but with a test case. > > Berto > > Alberto Garcia (2): > commit: Make base read-only if there is an early failure > iotests: Check that images are in read-only mode after block

Re: [Qemu-devel] [PATCH for-4.1] commit: Use bdrv_append() in commit_start()

2019-04-26 Thread Alberto Garcia
ping On Wed 03 Apr 2019 04:37:48 PM CEST, Alberto Garcia wrote: > This function combines bdrv_set_backing_hd() and bdrv_replace_node() > so we can use it to simplify the code a bit in commit_start(). > > Signed-off-by: Alberto Garcia > --- > block/commit.c | 11 +-- > 1 file changed, 1 i

Re: [Qemu-devel] [PATCH for-4.1] block: Assert that drv->bdrv_child_perm is set in bdrv_child_perm()

2019-04-26 Thread Alberto Garcia
ping On Thu 04 Apr 2019 01:29:53 PM CEST, Alberto Garcia wrote: > There is no need to check for this because all block drivers that have > children implement bdrv_child_perm and all callers already ensure that > bs->drv is set. > > Furthermore, if this check would fail then the callers would end u

Re: [Qemu-devel] [PATCH v6 08/11] contrib: add vhost-user-gpu

2019-04-26 Thread Marc-André Lureau
Hi On Fri, Apr 26, 2019 at 10:03 AM Gerd Hoffmann wrote: > > Hi, > > > +#ifdef CONFIG_LIBDRM_INTEL > > +static bool > > +intel_alloc_bo(struct drm_buffer *buf) > > +{ > > +uint32_t tiling = I915_TILING_NONE; > > + > > +buf->intel_bo = drm_intel_bo_alloc_tiled(buf->dev->bufmgr, > > "vho

Re: [Qemu-devel] [PULL 00/19] first batch of s390x patches for 4.1

2019-04-26 Thread Peter Maydell
On Thu, 25 Apr 2019 at 14:21, Cornelia Huck wrote: > > The following changes since commit 3284aa128153750f14a61e8a96fd085e6f2999b6: > > Merge remote-tracking branch 'remotes/lersek/tags/edk2-pull-2019-04-22' > into staging (2019-04-24 13:19:41 +0100) > > are available in the Git repository at:

[Qemu-devel] [Bug 1826422] Re: Regression: QEMU 4.0 hangs the host (*bisect included*)

2019-04-26 Thread Alex Williamson
The change in QEMU 4.0 is only a change in defaults of the machine type, it can be entirely reverted in the VM config with kernel_irqchip=on or with libvirt. Using a machine type prior to the q35 4.0 machine type would also avoid it. There are no performance issues with these configurations that

Re: [Qemu-devel] [PATCH v2 10/10] s390x/cpumodel: wire up 8561 and 8562 as gen15 machines

2019-04-26 Thread Cornelia Huck
On Fri, 26 Apr 2019 14:05:30 +0200 David Hildenbrand wrote: > On 26.04.19 14:01, Christian Borntraeger wrote: > > > > > > On 26.04.19 13:52, David Hildenbrand wrote: > >> On 26.04.19 13:36, Christian Borntraeger wrote: > >>> > >>> > >>> On 26.04.19 13:32, David Hildenbrand wrote: > O

Re: [Qemu-devel] About pt-br keyboard layout

2019-04-26 Thread Lin Ma
On 4/26/19 7:48 PM, Gerd Hoffmann wrote: So -k must match the *hosts* keyboard layout. So, that means, If I launch qemu with -k pt-br on a host, I need to ensure the keyboard layout must be pt-br as well onthathypervisorhost,Then when I connected to this vnc server(qemu) throughvncviewer on my

Re: [Qemu-devel] [PATCH 3/6] Add vhost-user-backend

2019-04-26 Thread Marc-André Lureau
Hi On Fri, Apr 26, 2019 at 12:27 PM Marc-André Lureau wrote: > > Create a vhost-user-backend object that holds a connection to a > vhost-user backend (or "slave" process) and can be referenced from > virtio devices that support it. See later patches for input & gpu > usage. > > Note: a previous i

Re: [Qemu-devel] [PATCH 1/3] ram-encrypted-notifier: Introduce a RAM block encrypted notifier

2019-04-26 Thread Igor Mammedov
On Thu, 25 Apr 2019 22:58:18 + "Natarajan, Janakarajan" wrote: > A client can register to this notifier to know whether the newly added or > removed memory region is marked as encrypted. This information is needed > for the SEV guest launch. In SEV guest, some memory regions may contain > enc

[Qemu-devel] aio context ownership during bdrv_close()

2019-04-26 Thread Anton Kuchin
I can't figure out ownership of aio context during bdrv_close(). As far as I understand bdrv_unref() shold be called with acquired aio context to prevent concurrent operations (at least most usages in blockdev.c explicitly acquire and release context, but not all). But if refcount reaches zer

Re: [Qemu-devel] [PATCH v2 for-4.1 0/2] Fix ohci_die() and move PCI code to separate file

2019-04-26 Thread Philippe Mathieu-Daudé
On 4/26/19 2:20 PM, Thomas Huth wrote: > On 26/04/2019 14.14, Philippe Mathieu-Daudé wrote: >> On 4/26/19 7:42 AM, Thomas Huth wrote: >>> On 26/04/2019 00.55, Philippe Mathieu-Daudé wrote: Hi Thomas, On 4/19/19 9:56 AM, Thomas Huth wrote: > First patch fixes a problem with ohci_d

Re: [Qemu-devel] [PATCH v2 for-4.1 0/2] Fix ohci_die() and move PCI code to separate file

2019-04-26 Thread Thomas Huth
On 26/04/2019 14.14, Philippe Mathieu-Daudé wrote: > On 4/26/19 7:42 AM, Thomas Huth wrote: >> On 26/04/2019 00.55, Philippe Mathieu-Daudé wrote: >>> Hi Thomas, >>> >>> On 4/19/19 9:56 AM, Thomas Huth wrote: First patch fixes a problem with ohci_die(), second patch moves PCI code into >>

Re: [Qemu-devel] [PATCH v6 05/11] vhost-user: add vhost_user_gpu_set_socket()

2019-04-26 Thread Marc-André Lureau
Hi On Fri, Apr 26, 2019 at 2:06 PM Gerd Hoffmann wrote: > > Hi, > > > > > +Wire format > > > > +=== > > > > + > > > > +Unless specified differently, numbers are in the machine native byte > > > > +order. > > > > + > > > > +A vhost-user-gpu request consists of 2 header fields and a paylo

Re: [Qemu-devel] [PATCH v2 for-4.1 0/2] Fix ohci_die() and move PCI code to separate file

2019-04-26 Thread Philippe Mathieu-Daudé
On 4/26/19 7:42 AM, Thomas Huth wrote: > On 26/04/2019 00.55, Philippe Mathieu-Daudé wrote: >> Hi Thomas, >> >> On 4/19/19 9:56 AM, Thomas Huth wrote: >>> First patch fixes a problem with ohci_die(), second patch moves PCI code >>> into >>> a separate file, so that the sysbus OHCI device can also

Re: [Qemu-devel] [PATCH v6 05/11] vhost-user: add vhost_user_gpu_set_socket()

2019-04-26 Thread Gerd Hoffmann
Hi, > > > +Wire format > > > +=== > > > + > > > +Unless specified differently, numbers are in the machine native byte > > > +order. > > > + > > > +A vhost-user-gpu request consists of 2 header fields and a payload. > > > + > > > ++-+--+-+ > > > +| request | size | pay

Re: [Qemu-devel] [PATCH v2 10/10] s390x/cpumodel: wire up 8561 and 8562 as gen15 machines

2019-04-26 Thread David Hildenbrand
On 26.04.19 14:01, Christian Borntraeger wrote: > > > On 26.04.19 13:52, David Hildenbrand wrote: >> On 26.04.19 13:36, Christian Borntraeger wrote: >>> >>> >>> On 26.04.19 13:32, David Hildenbrand wrote: On 26.04.19 13:10, Christian Borntraeger wrote: > 8561 and 8562 will be gen15 machi

Re: [Qemu-devel] About pt-br keyboard layout

2019-04-26 Thread Gerd Hoffmann
> > So -k must match the *hosts* keyboard layout. > So, that means, If I launch qemu with -k pt-br on a host, I need to ensure > the keyboard layout > must be pt-br as well onthathypervisorhost,Then when I connected to this vnc > server(qemu) > throughvncviewer on mylaptop(us keyboard layout), I ty

Re: [Qemu-devel] [PATCH v2 10/10] s390x/cpumodel: wire up 8561 and 8562 as gen15 machines

2019-04-26 Thread David Hildenbrand
On 26.04.19 13:36, Christian Borntraeger wrote: > > > On 26.04.19 13:32, David Hildenbrand wrote: >> On 26.04.19 13:10, Christian Borntraeger wrote: >>> 8561 and 8562 will be gen15 machines. There is no name yet, lets us use >>> the cpu id as base name. Later on we can provide aliases with the pr

Re: [Qemu-devel] [PATCH v3 11/13] tests: acpi: add simple arm/virt testcase

2019-04-26 Thread Igor Mammedov
On Fri, 26 Apr 2019 00:51:56 +0800 x00249684 wrote: > Hi Igor, > > +static void test_acpi_virt_tcg(void) > +{ > +test_data data = { > +.machine = "virt", > +.uefi_fl1 = "pc-bios/edk2-aarch64-code.fd", > +.uefi_fl2 = "pc-bios/edk2-arm-vars.fd", > +.cd = > "tes

Re: [Qemu-devel] [PATCH v6 05/11] vhost-user: add vhost_user_gpu_set_socket()

2019-04-26 Thread Marc-André Lureau
Hi On Fri, Apr 26, 2019 at 9:33 AM Gerd Hoffmann wrote: > > On Tue, Apr 23, 2019 at 03:19:58PM +0200, Marc-André Lureau wrote: > > Add a new vhost-user message to give a unix socket to a vhost-user > > backend for GPU display updates. > > Can you split input/gpu into two patch series? > > > +Wire

Re: [Qemu-devel] [PATCH v2 10/10] s390x/cpumodel: wire up 8561 and 8562 as gen15 machines

2019-04-26 Thread Christian Borntraeger
On 26.04.19 13:52, David Hildenbrand wrote: > On 26.04.19 13:36, Christian Borntraeger wrote: >> >> >> On 26.04.19 13:32, David Hildenbrand wrote: >>> On 26.04.19 13:10, Christian Borntraeger wrote: 8561 and 8562 will be gen15 machines. There is no name yet, lets us use the cpu id as b

Re: [Qemu-devel] About pt-br keyboard layout

2019-04-26 Thread Lin Ma
On 4/26/19 4:38 PM, Gerd Hoffmann wrote: On Fri, Apr 26, 2019 at 04:09:12PM +0800, Lin Ma wrote: Hi all, While I launch qemu with vnc + pt-br keyboard layout on my pc, If I type shift + 6 in iPXE shell or grub shell via my usual 105-key keyboard, shift + 6 would be mapped to "(apostrophe), Bu

Re: [Qemu-devel] [PATCH] Revert "armv7m: Guard against no -kernel argument"

2019-04-26 Thread Peter Maydell
On Fri, 26 Apr 2019 at 10:17, Stefan Hajnoczi wrote: > > On Thu, Apr 25, 2019 at 08:07:06PM +0200, Philippe Mathieu-Daudé wrote: > > Previous to this commit (v3.1), we have: > > > > $ qemu-system-aarch64 -M netduino2 > > qemu-system-aarch64: Guest image must be specified (using -kernel) > > > > No

Re: [Qemu-devel] [PATCH v2 10/10] s390x/cpumodel: wire up 8561 and 8562 as gen15 machines

2019-04-26 Thread Christian Borntraeger
On 26.04.19 13:32, David Hildenbrand wrote: > On 26.04.19 13:10, Christian Borntraeger wrote: >> 8561 and 8562 will be gen15 machines. There is no name yet, lets us use >> the cpu id as base name. Later on we can provide aliases with the proper >> name. >> >> Signed-off-by: Christian Borntraeger

Re: [Qemu-devel] [PATCH v2 10/10] s390x/cpumodel: wire up 8561 and 8562 as gen15 machines

2019-04-26 Thread David Hildenbrand
On 26.04.19 13:24, Christian Borntraeger wrote: > > > On 26.04.19 13:21, David Hildenbrand wrote: >> On 26.04.19 13:10, Christian Borntraeger wrote: >>> 8561 and 8562 will be gen15 machines. There is no name yet, lets us use >>> the cpu id as base name. Later on we can provide aliases with the pr

  1   2   >