Re: [Qemu-devel] [PATCH 1/4] tests/vm: Support proxy / corporate firewall

2018-07-02 Thread Fam Zheng
On Thu, 06/28 12:35, Philippe Mathieu-Daudé wrote: > If ftp_proxy/http_proxy/https_proxy standard environment variables > are available, pass them to the vm images. > > As per 06cc3551714: > This is required when building behind corporate proxy/firewall, but > also help when using local cache serv

Re: [Qemu-devel] [PATCH 2/4] tests/vm: Add a dependency to qemu-img

2018-07-02 Thread Fam Zheng
On Thu, 06/28 12:35, Philippe Mathieu-Daudé wrote: > Before the first use, the VM image are resized with qemu-img. > > Add a dependency to the qemu-img tool to fix: > > $ make vm-build-ubuntu.i386 > Traceback (most recent call last): > File "source/qemu/tests/vm/basevm.py", line 236, in m

Re: [Qemu-devel] [PATCH 0/4] tests/vm: various trivial fixes

2018-07-02 Thread Fam Zheng
On Thu, 06/28 12:35, Philippe Mathieu-Daudé wrote: > Hi, > > These are various fixes I added to have the VM tests working for me. Queued the last two patches. Thanks. Fam

[Qemu-devel] [GIT PULL for qemu-pseries] pseries: Update SLOF firmware image

2018-07-02 Thread Alexey Kardashevskiy
The following changes since commit edb1fb337f65f82fe32b989c4f018efe85c1dddb: pseries: Update SLOF firmware image (2018-07-02 16:21:30 +1000) are available in the git repository at: g...@github.com:aik/qemu.git tags/qemu-slof-20180702 for you to fetch changes up to

Re: [Qemu-devel] [PATCH] ppc: Include vga cirrus card into the compiling process

2018-07-02 Thread Sebastian Bauer
Am 2018-07-02 07:22, schrieb David Gibson: And now unapplied, since it breaks make check all over the place for ppc64-softmmu. Please folks, running an all-targets make check is really the *minimum* bar for testing before posting a patch for inclusion. Okay, will do next time. Sorry for the in

[Qemu-devel] [GIT PULL for qemu-pseries] pseries: Update SLOF firmware image

2018-07-02 Thread Alexey Kardashevskiy
The following changes since commit edb1fb337f65f82fe32b989c4f018efe85c1dddb: pseries: Update SLOF firmware image (2018-07-02 16:21:30 +1000) are available in the git repository at: g...@github.com:aik/qemu.git tags/qemu-slof-20180702 for you to fetch changes up to

Re: [Qemu-devel] [PATCH v5] crypto: Implement TLS Pre-Shared Keys (PSK).

2018-07-02 Thread Daniel P . Berrangé
On Fri, Jun 29, 2018 at 06:40:29PM +0100, Richard W.M. Jones wrote: > On Fri, Jun 29, 2018 at 06:03:43PM +0100, Daniel P. Berrangé wrote: > > On Thu, Jun 28, 2018 at 07:46:24PM +0100, Richard W.M. Jones wrote: > > > diff --git a/crypto/tlssession.c b/crypto/tlssession.c > > > index 96a02deb69..50df

Re: [Qemu-devel] [PATCH v2 1/2] block: allow blockdev-backup from any source

2018-07-02 Thread Kashyap Chamarthy
On Thu, Jun 28, 2018 at 05:19:37PM -0400, John Snow wrote: > > > On 06/28/2018 02:05 PM, Eric Blake wrote: > > On 06/28/2018 01:00 PM, John Snow wrote: > >> In the case of image fleecing, the node we choose as the source > >> for a blockdev-backup is going to be both a root node AND the > >> back

Re: [Qemu-devel] [PATCH v3 0/4] migation: unbreak postcopy recovery

2018-07-02 Thread Balamuruhan S
On Wed, Jun 27, 2018 at 09:22:42PM +0800, Peter Xu wrote: > v3: > - keep the recovery logic even for RDMA by dropping the 3rd patch and > touch up the original 4th patch (current 3rd patch) to suite that [Dave] > > v2: > - break the first patch into several > - fix a QEMUFile leak > > Please re

Re: [Qemu-devel] [libvirt] [PULL 25/26] block: Remove deprecated -drive option serial

2018-07-02 Thread Kevin Wolf
Am 25.06.2018 um 13:45 hat Peter Krempa geschrieben: > On Mon, Jun 25, 2018 at 13:41:06 +0200, Kevin Wolf wrote: > > Am 25.06.2018 um 11:53 hat Daniel P. Berrangé geschrieben: > > > On Fri, Jun 22, 2018 at 03:31:46PM +0100, Daniel P. Berrangé wrote: > > > > On Fri, Jun 22, 2018 at 04:25:13PM +0200,

Re: [Qemu-devel] [PATCH v1] s390x/tcg: fix locking problem with tcg_s390_tod_updated

2018-07-02 Thread Cornelia Huck
On Fri, 29 Jun 2018 19:05:20 +0200 David Hildenbrand wrote: > tcg_s390_tod_updated() is always called with the iothread being locked > (e.g. from S390TODClass->set() e.g. via HELPER(sck) or on incomming s/incomming/incoming/ > migration). The helper we call takes the lock itself - bad. > > Let

Re: [Qemu-devel] [PATCH v2] target-i386: Add NPT support

2018-07-02 Thread Paolo Bonzini
On 30/06/2018 08:08, Jan Kiszka wrote: > From: Jan Kiszka > > This implements NPT suport for SVM by hooking into > x86_cpu_handle_mmu_fault where it reads the stage-1 page table. Whether > we need to perform this 2nd stage translation, and how, is decided > during vmrun and stored in hflags2, alo

Re: [Qemu-devel] [PATCH] !fixup 052f529eb3d07170b18b8d0920bc8c450e389a2f

2018-07-02 Thread Paolo Bonzini
On 30/06/2018 18:50, Philippe Mathieu-Daudé wrote: > Signed-off-by: Philippe Mathieu-Daudé > --- > This was in e9dd993d-875f-4173-f68e-e6b4e75e3...@amsat.org but I can't > find it on the list... > > tests/test-cutils.c| 2 +- > tests/test-qemu-opts.c | 2 +- > 2 files changed, 2 insertions(+

Re: [Qemu-devel] [PATCH] qemu-char: reset errno before qemu char write or read action

2018-07-02 Thread Paolo Bonzini
On 02/07/2018 02:49, xinhua.Cao wrote: > In the tcp_chr_write function, we checked errno, > but errno was not reset before a read or write operation. > Therefore, this check of errno's actions is often > incorrect after EAGAIN has occurred. > We reset errno before reading and writing to > ensure th

Re: [Qemu-devel] [PATCH v3 0/4] migation: unbreak postcopy recovery

2018-07-02 Thread Peter Xu
On Mon, Jul 02, 2018 at 01:34:45PM +0530, Balamuruhan S wrote: > On Wed, Jun 27, 2018 at 09:22:42PM +0800, Peter Xu wrote: > > v3: > > - keep the recovery logic even for RDMA by dropping the 3rd patch and > > touch up the original 4th patch (current 3rd patch) to suite that [Dave] > > > > v2: >

Re: [Qemu-devel] [PATCH] qtest: Use cpu address space instead of system memory

2018-07-02 Thread Stefan Hajnoczi
On Mon, Jul 02, 2018 at 09:52:37AM +0300, Julia Suvorova via Qemu-devel wrote: > Some devices (like nvic in armv7m) are not accessable through > address_space_memory, therefore can not be tested with qtest. > > Signed-off-by: Julia Suvorova > --- > qtest.c | 39 ++

Re: [Qemu-devel] [PATCH v1] qemu-pr-helper: garbage response structure can be used to write data

2018-07-02 Thread Dima Stepanov
Ping. On Fri, Jun 15, 2018 at 12:11:44PM +0300, Dima Stepanov wrote: > The prh_co_entry() routine handles requests. The first part is to read a > request by calling the prh_read_request() routine, if: > 1. scsi_cdb_xfer(req->cdb) call returns 0, and > 2. req->cdb[0] == PERSISTENT_RESERVE_IN, t

[Qemu-devel] [PATCH v3] spapr: compute default value of "hpt-max-page-size" later

2018-07-02 Thread Greg Kurz
It is currently not possible to run a pseries-2.12 or older machine with HV KVM. QEMU prints the following and exits right away. qemu-system-ppc64: KVM doesn't support for base page shift 34 The "hpt-max-page-size" capability was recently added to spapr to hide host configuration details from HPT

Re: [Qemu-devel] [PATCH v3 0/2] backup: Use copy offloading

2018-07-02 Thread Fam Zheng
Jeff: ping? Can we have this in 3.0? On Tue, 06/05 22:06, Fam Zheng wrote: > Based-on: <20180529055959.32002-1-f...@redhat.com> > ([PATCH v7 00/10] qemu-img convert with copy offloading) > > This enhances the backup job to make use of the copy offloading API. It > eliminates the necessity to use

[Qemu-devel] [Bug 1779634] [NEW] qemu-x86_64 on aarch64 reports "Synchronous External Abort"

2018-07-02 Thread He Yi
Public bug reported: Purpose: to run x86_64 utilities on aarch64 platform (Intel/Dell network adapters' firmware upgrade tools) System: aarch64 server platform, with ubuntu 16.04 (xenial) Linux 4.13.0-45-generic #50~16.04.1-Ubuntu SMP Wed May 30 11:14:25 UTC 2018 aarch64 aarch64 aarch64 GNU/Lin

[Qemu-devel] [PATCH v3 0/4] pc-dimm: pre_plug "slot" and "addr" assignment

2018-07-02 Thread David Hildenbrand
As requested by Igor, assign and verify "slot" and "addr" in the pre_plug handler. Factor out the compatibility handling/configuration for detecting the alignment to be used when searching for an address in guest physical memory for a memory device. This is another part of the original series

[Qemu-devel] [PATCH v3 3/4] pc: drop memory region alignment check for 0

2018-07-02 Thread David Hildenbrand
All applicable memory regions always have an alignment > 0. All memory backends result in file_ram_alloc() or qemu_anon_ram_alloc() getting called, setting the alignment to > 0. So a PCDIMM memory region always has an alignment > 0. NVDIMM copy the alignment of the original memory memory region in

[Qemu-devel] [PATCH v3 1/4] pc-dimm: assign and verify the "slot" property during pre_plug

2018-07-02 Thread David Hildenbrand
We can assign and verify the slot before realizing and trying to plug. reading/writing the slot property should never fail, so let's reduce error handling a bit by using &error_abort. To do this during pre_plug, add and use (x86, ppc) pc_dimm_pre_plug(). Reviewed-by: David Gibson Reviewed-by: Ig

[Qemu-devel] [PATCH v3 2/4] util/oslib-win32: indicate alignment for qemu_anon_ram_alloc()

2018-07-02 Thread David Hildenbrand
Let's set the alignment just like for the posix variant. This will implicitly set the alignment of the underlying memory region and therefore make memory_region_get_alignment(mr) return something > 0 for all memory backends applicable to PCDIMM/NVDIMM. The allocation granularity is ususally 64k, w

[Qemu-devel] [PATCH v1] machine: properly free device_memory

2018-07-02 Thread David Hildenbrand
Machines might have inititalized device_memory if they support memory devices, so let's properly free it. Signed-off-by: David Hildenbrand --- hw/core/machine.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/core/machine.c b/hw/core/machine.c index 617e5f8d75..ae3e713e90 100644 --- a/hw/

[Qemu-devel] [PATCH v3 4/4] pc-dimm: assign and verify the "addr" property during pre_plug

2018-07-02 Thread David Hildenbrand
We can assign and verify the slot before realizing and trying to plug. reading/writing the address property should never fail for DIMMs, so let's reduce error handling a bit by using &error_abort. Getting access to the memory region now might however fail. So forward errors from get_memory_region()

Re: [Qemu-devel] [PATCH v2 0/7] Misc sm501 improvements

2018-07-02 Thread Peter Maydell
On 30 June 2018 at 21:34, BALATON Zoltan wrote: > On Tue, 26 Jun 2018, BALATON Zoltan wrote: >> >> Version 2 of the sm501 changes with fixes that are needed to get >> AmigaOS 4.1FE to boot and able to produce graphics. >> >> The strange blue-white colors that first appear are actually correct >> a

Re: [Qemu-devel] [PATCH v3 0/4] migation: unbreak postcopy recovery

2018-07-02 Thread Balamuruhan S
On Mon, Jul 02, 2018 at 04:46:18PM +0800, Peter Xu wrote: > On Mon, Jul 02, 2018 at 01:34:45PM +0530, Balamuruhan S wrote: > > On Wed, Jun 27, 2018 at 09:22:42PM +0800, Peter Xu wrote: > > > v3: > > > - keep the recovery logic even for RDMA by dropping the 3rd patch and > > > touch up the origina

[Qemu-devel] [Bug 1779634] Re: qemu-x86_64 on aarch64 reports "Synchronous External Abort"

2018-07-02 Thread Peter Maydell
qemu-x86_64 is just a userspace program. If the kernel is getting Synchronous External Aborts then this is not a QEMU problem. Either there's a bug in the host kernel, or the guest binary is attempting to mmap /dev/mem and do wrong things to it because it's expecting it to be an x86 system. I suspe

Re: [Qemu-devel] [PATCH v3 05/20] kvm: arm/arm64: Fix stage2_flush_memslot for 4 level page table

2018-07-02 Thread Marc Zyngier
On 29/06/18 12:15, Suzuki K Poulose wrote: > So far we have only supported 3 level page table with fixed IPA of 40bits. > Fix stage2_flush_memslot() to accommodate for 4 level tables. > > Cc: Marc Zyngier > Acked-by: Christoffer Dall > Signed-off-by: Suzuki K Poulose > --- > virt/kvm/arm/mmu.c

Re: [Qemu-devel] [PATCH v3 06/20] kvm: arm/arm64: Remove spurious WARN_ON

2018-07-02 Thread Marc Zyngier
On 29/06/18 12:15, Suzuki K Poulose wrote: > On a 4-level page table pgd entry can be empty, unlike a 3-level > page table. Remove the spurious WARN_ON() in stage_get_pud(). > > Cc: Marc Zyngier > Acked-by: Christoffer Dall > Signed-off-by: Suzuki K Poulose > --- > virt/kvm/arm/mmu.c | 2 +- >

Re: [Qemu-devel] [PATCH v3 1/3] spapr: introduce a fixed IRQ number space

2018-07-02 Thread Cédric Le Goater
> --- a/hw/ppc/spapr_vio.c > +++ b/hw/ppc/spapr_vio.c > @@ -436,6 +436,9 @@ static void spapr_vio_busdev_reset(DeviceState *qdev) > } > } > > +/* TODO : poor VIO device indexing ... */ > +static uint32_t vio_index; I think we could also use (dev->reg & 0xff) as an index for the VIO device

[Qemu-devel] [Bug 1779634] Re: qemu-x86_64 on aarch64 reports "Synchronous External Abort"

2018-07-02 Thread Peter Maydell
You could confirm this hypothesis by using strace and looking for whether it's doing mmap() of /dev/mem or /dev/kmem. If it's true, then the program would not work even if you had the source and recompiled it for aarch64 -- it would require bugfixes (code changes) to achieve whatever it's trying to

Re: [Qemu-devel] [PATCH v3 07/20] kvm: arm/arm64: Prepare for VM specific stage2 translations

2018-07-02 Thread Marc Zyngier
On 29/06/18 12:15, Suzuki K Poulose wrote: > Right now the stage2 page table for a VM is hard coded, assuming > an IPA of 40bits. As we are about to add support for per VM IPA, > prepare the stage2 page table helpers to accept the kvm instance > to make the right decision for the VM. No functional

Re: [Qemu-devel] [PATCH v3 2/4] util/oslib-win32: indicate alignment for qemu_anon_ram_alloc()

2018-07-02 Thread Igor Mammedov
On Mon, 2 Jul 2018 11:37:53 +0200 David Hildenbrand wrote: > Let's set the alignment just like for the posix variant. This will > implicitly set the alignment of the underlying memory region and > therefore make memory_region_get_alignment(mr) return something > 0 for > all memory backends appli

Re: [Qemu-devel] [PATCH v3 0/4] migation: unbreak postcopy recovery

2018-07-02 Thread Peter Xu
On Mon, Jul 02, 2018 at 03:12:41PM +0530, Balamuruhan S wrote: > On Mon, Jul 02, 2018 at 04:46:18PM +0800, Peter Xu wrote: > > On Mon, Jul 02, 2018 at 01:34:45PM +0530, Balamuruhan S wrote: > > > On Wed, Jun 27, 2018 at 09:22:42PM +0800, Peter Xu wrote: > > > > v3: > > > > - keep the recovery logic

[Qemu-devel] [PATCH] target-i386: adds PV_SEND_IPI CPUID feature bit

2018-07-02 Thread Wanpeng Li
From: Wanpeng Li Adds PV_SEND_IPI CPUID feature bit. Cc: Paolo Bonzini Cc: Eduardo Habkost Cc: Radim Krčmář Cc: Vitaly Kuznetsov Signed-off-by: Wanpeng Li --- target/i386/cpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/i386/cpu.c b/target/i386/cpu.c index 1

Re: [Qemu-devel] [PATCH v3 07/20] kvm: arm/arm64: Prepare for VM specific stage2 translations

2018-07-02 Thread Suzuki K Poulose
On 02/07/18 11:12, Marc Zyngier wrote: On 29/06/18 12:15, Suzuki K Poulose wrote: Right now the stage2 page table for a VM is hard coded, assuming an IPA of 40bits. As we are about to add support for per VM IPA, prepare the stage2 page table helpers to accept the kvm instance to make the right d

[Qemu-devel] [PULL 1/1] target/m68k: correctly disassemble move16

2018-07-02 Thread Laurent Vivier
"move16 %a0@+,%a1@" and "fmovel (cpid=3) %a0@-,%fpcr" share the same opcode. To fix that, backport the fix from binutils: 2005-11-10 Andreas Schwab * m68k-dis.c (print_insn_m68k): Only match FPU insns with coprocessor ID 1. Reported-by: Thomas Huth Signed-off-by: Laurent Vivier

[Qemu-devel] [PULL 0/1] M68k for 3.0 patches

2018-07-02 Thread Laurent Vivier
The following changes since commit 281bd281222776229d5dbf84d1a5c6d8d9d2a34b: Merge remote-tracking branch 'remotes/xtensa/tags/20180630-xtensa' into staging (2018-06-30 22:23:51 +0100) are available in the Git repository at: git://github.com/vivier/qemu-m68k.git tags/m68k-for-3.0-pull-reque

Re: [Qemu-devel] [PATCH v3 4/4] pc-dimm: assign and verify the "addr" property during pre_plug

2018-07-02 Thread Igor Mammedov
On Mon, 2 Jul 2018 11:37:55 +0200 David Hildenbrand wrote: > We can assign and verify the slot before realizing and trying to plug. s/slot/"addr"/ > reading/writing the address property should never fail for DIMMs, so let's > reduce error handling a bit by using &error_abort. Getting access to

Re: [Qemu-devel] [PATCH v2 0/7] Misc sm501 improvements

2018-07-02 Thread BALATON Zoltan
On Mon, 2 Jul 2018, Peter Maydell wrote: On 30 June 2018 at 21:34, BALATON Zoltan wrote: On Tue, 26 Jun 2018, BALATON Zoltan wrote: Version 2 of the sm501 changes with fixes that are needed to get AmigaOS 4.1FE to boot and able to produce graphics. The strange blue-white colors that first ap

Re: [Qemu-devel] [PATCH v1] machine: properly free device_memory

2018-07-02 Thread Igor Mammedov
On Mon, 2 Jul 2018 11:41:52 +0200 David Hildenbrand wrote: > Machines might have inititalized device_memory if they support memory > devices, so let's properly free it. > > Signed-off-by: David Hildenbrand > --- > hw/core/machine.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/hw/

Re: [Qemu-devel] [PATCH] accel/tcg: Avoid caching overwritten tlb entries

2018-07-02 Thread Peter Maydell
On 29 June 2018 at 22:37, Richard Henderson wrote: > When installing a TLB entry, remove any cached version of the > same page in the VTLB. If the existing TLB entry matches, do > not copy into the VTLB, but overwrite it. > > Signed-off-by: Richard Henderson > --- > > This may fix some problems

Re: [Qemu-devel] [PATCH v1] qemu-pr-helper: garbage response structure can be used to write data

2018-07-02 Thread Stefan Hajnoczi
On Fri, Jun 15, 2018 at 12:11:44PM +0300, Dima Stepanov wrote: > The prh_co_entry() routine handles requests. The first part is to read a > request by calling the prh_read_request() routine, if: > 1. scsi_cdb_xfer(req->cdb) call returns 0, and > 2. req->cdb[0] == PERSISTENT_RESERVE_IN, then > T

Re: [Qemu-devel] [PATCH v3 4/4] pc-dimm: assign and verify the "addr" property during pre_plug

2018-07-02 Thread David Hildenbrand
On 02.07.2018 12:31, Igor Mammedov wrote: > On Mon, 2 Jul 2018 11:37:55 +0200 > David Hildenbrand wrote: > >> We can assign and verify the slot before realizing and trying to plug. > s/slot/"addr"/ > >> reading/writing the address property should never fail for DIMMs, so let's >> reduce error h

Re: [Qemu-devel] [PATCH 0/2] Fix qemu-system-aarch64 crash

2018-07-02 Thread Peter Maydell
On 30 June 2018 at 01:02, Richard Henderson wrote: > The sequence of events was > (1) Kernel executed a disabled sve insn, > (2) Undefined Instruction trap went to EL3, > (3) Lookup of the exception handler saw el3 and returned asidx 1, > (4) Which hadn't been set up. > > So there's defini

Re: [Qemu-devel] [PATCH] i386/monitor.c: make addresses canonical for "info mem" and "info tlb"

2018-07-02 Thread Paolo Bonzini
On 01/07/2018 20:57, Doug Gale wrote: > > > On Sun, Jun 17, 2018 at 4:40 AM, Doug Gale > wrote: > > Correct the output of the "info mem" and "info tlb" monitor commands to > correctly show canonical addresses. > > In 48-bit addressing mode, the upper 16 bi

Re: [Qemu-devel] [PATCH v2 0/7] Misc sm501 improvements

2018-07-02 Thread Peter Maydell
On 2 July 2018 at 11:33, BALATON Zoltan wrote: > Thank you. Please agree on what should be the needed action here. It would > be a pity if this missed 3.0 because of this. Could it be merged before the > freeze if no obvious problems are found with that it can be removed later if > it causes any t

Re: [Qemu-devel] [PATCH v3 07/20] kvm: arm/arm64: Prepare for VM specific stage2 translations

2018-07-02 Thread Auger Eric
Hi Suzuki, On 06/29/2018 01:15 PM, Suzuki K Poulose wrote: > Right now the stage2 page table for a VM is hard coded, assuming > an IPA of 40bits. As we are about to add support for per VM IPA, > prepare the stage2 page table helpers to accept the kvm instance > to make the right decision for the V

Re: [Qemu-devel] [PATCH] audio/hda: drop atomics

2018-07-02 Thread Peter Maydell
On 29 June 2018 at 18:49, Philippe Mathieu-Daudé wrote: > On 06/27/2018 01:15 PM, Philippe Mathieu-Daudé wrote: >> On 06/27/2018 08:19 AM, Gerd Hoffmann wrote: >>> Doesn't build on 32bit clang. And because we run under qemu mutex >>> anyway they are not needed. >>> >>> Signed-off-by: Gerd Hoffman

Re: [Qemu-devel] about live memory snapshot

2018-07-02 Thread Peter Xu
On Sat, Jun 30, 2018 at 01:45:29AM +, Gonglei (Arei) wrote: > Hi Peter, > > As we discussed in LC3 China, the current scheme of "migration to file" > can't fit on production environment, which will cause the snapshot file > bigger > and bigger when the guest is under enough memory pressure.

Re: [Qemu-devel] [PATCH v2 0/7] Misc sm501 improvements

2018-07-02 Thread BALATON Zoltan
On Mon, 2 Jul 2018, Peter Maydell wrote: On 2 July 2018 at 11:33, BALATON Zoltan wrote: Thank you. Please agree on what should be the needed action here. It would be a pity if this missed 3.0 because of this. Could it be merged before the freeze if no obvious problems are found with that it can

[Qemu-devel] [Bug 1779649] [NEW] Suspending a domain works with a 3.16 gues kernel but not with a 4.16 one

2018-07-02 Thread Bastien Orivel
Public bug reported: Suspending a domain with `systemctl suspend` works with a guest 3.16 kernel (jessie), the domain goes into `pmsuspend` in libvirt but doesn't work anymore with a 4.16 one (sid) where: - With a QXL card: the spice display just goes black and the domain stays `running` in li

Re: [Qemu-devel] [PATCH v3 09/20] kvm: arm64: Make stage2 page table layout dynamic

2018-07-02 Thread Suzuki K Poulose
On 29/06/18 12:15, Suzuki K Poulose wrote: So far we had a static stage2 page table handling code, based on a fixed IPA of 40bits. As we prepare for a configurable IPA size per VM, make our stage2 page table code dynamic, to do the right thing for a given VM. We ensure the existing condition is a

Re: [Qemu-devel] [PATCH v3 07/20] kvm: arm/arm64: Prepare for VM specific stage2 translations

2018-07-02 Thread Suzuki K Poulose
Hi Eric, On 02/07/18 11:51, Auger Eric wrote: Hi Suzuki, On 06/29/2018 01:15 PM, Suzuki K Poulose wrote: Right now the stage2 page table for a VM is hard coded, assuming an IPA of 40bits. As we are about to add support for per VM IPA, prepare the stage2 page table helpers to accept the kvm i

[Qemu-devel] [Bug 1779650] [NEW] The display stays black after waking up a domain via SPICE with a QXL card

2018-07-02 Thread Bastien Orivel
Public bug reported: As the title says, in a jessie VM, waking up a VM via the spice remote view works with a VGA graphic card. With a QXL card though, the domain wakes up but the display stays black (the keyboard is working though). Qemu: Master, 281bd281222776229d5dbf84d1a5c6d8d9d2a34b ** Affe

[Qemu-devel] [PATCH v1 1/1] s390x/storage attributes: fix CMMA_BLOCK_SIZE usage

2018-07-02 Thread Claudio Imbrenda
The macro CMMA_BLOCK_SIZE was defined but not used, and a hardcoded value was instead used in the code. This patch fixes the value of CMMA_BLOCK_SIZE and uses it in the appropriate place in the code. Signed-off-by: Claudio Imbrenda --- hw/s390x/s390-stattrib.c | 5 +++-- 1 file changed, 3 inser

Re: [Qemu-devel] about live memory snapshot

2018-07-02 Thread Denis Plotnikov
On 02.07.2018 13:53, Peter Xu wrote: On Sat, Jun 30, 2018 at 01:45:29AM +, Gonglei (Arei) wrote: Hi Peter, As we discussed in LC3 China, the current scheme of "migration to file" can't fit on production environment, which will cause the snapshot file bigger and bigger when the guest is u

Re: [Qemu-devel] [PATCH v3 1/3] spapr: introduce a fixed IRQ number space

2018-07-02 Thread Cédric Le Goater
On 07/02/2018 12:03 PM, Cédric Le Goater wrote: >> --- a/hw/ppc/spapr_vio.c >> +++ b/hw/ppc/spapr_vio.c >> @@ -436,6 +436,9 @@ static void spapr_vio_busdev_reset(DeviceState *qdev) >> } >> } >> >> +/* TODO : poor VIO device indexing ... */ >> +static uint32_t vio_index; > > I think we coul

[Qemu-devel] [PULL 03/15] s390x/cpumodel: default enable bpb and ppa15 for z196 and later

2018-07-02 Thread Cornelia Huck
From: Christian Borntraeger Most systems and host kernels provide the necessary building blocks for bpb and ppa15. We can reverse the logic and default enable those features, while still allowing to disable it via cpu model. So let us add bpb and ppa15 to z196 and later default CPU model for the

[Qemu-devel] [PULL 00/15] s390x patches for 3.0

2018-07-02 Thread Cornelia Huck
The following changes since commit 281bd281222776229d5dbf84d1a5c6d8d9d2a34b: Merge remote-tracking branch 'remotes/xtensa/tags/20180630-xtensa' into staging (2018-06-30 22:23:51 +0100) are available in the Git repository at: git://github.com/cohuck/qemu tags/s390x-20180702

[Qemu-devel] [PULL 01/15] s390/ipl: fix ipl with -no-reboot

2018-07-02 Thread Cornelia Huck
From: Christian Borntraeger kexec/kdump as well as the bootloader use a subcode of diagnose 308 that is supposed to reset the I/O subsystem but not comprise a full "reboot". With the latest refactoring this is now broken when -no-reboot is used or when libvirt acts on a reboot QMP event, for exam

[Qemu-devel] [PULL 09/15] s390x/tcg: SET CLOCK COMPARATOR can clear CKC interrupts

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand Let's stop the timer and delete any pending CKC IRQ before doing anything else. While at it, add a comment why the check for ckc == -1ULL is needed. Reviewed-by: Thomas Huth Signed-off-by: David Hildenbrand Message-Id: <20180627134410.4901-7-da...@redhat.com> Signed-of

[Qemu-devel] [PULL 07/15] s390x/tcg: drop tod_basetime

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand Never set to anything but 0. Reviewed-by: Thomas Huth Signed-off-by: David Hildenbrand Message-Id: <20180627134410.4901-5-da...@redhat.com> Signed-off-by: Cornelia Huck --- target/s390x/cpu.c | 1 - target/s390x/cpu.h | 1 - target/s390x/misc_helper.c

[Qemu-devel] [PULL 02/15] loader: Check access size when calling rom_ptr() to avoid crashes

2018-07-02 Thread Cornelia Huck
From: Thomas Huth The rom_ptr() function allows direct access to the ROM blobs that we load during startup. However, there are currently no checks for the size of the accesses, so it's currently possible to crash QEMU for example with: $ echo "Insane in the mainframe" > /tmp/test.txt $ s390x-sof

[Qemu-devel] [PULL 04/15] s390x/tcg: avoid overflows in time2tod/tod2time

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand Big values for the TOD/ns clock can result in some overflows that can be avoided. Not all overflows can be handled however, as the conversion either multiplies by 4.096 or divided by 4.096. Apply the trick used in the Linux kernel in arch/s390/include/asm/timex.h for tod_

[Qemu-devel] [PULL 12/15] s390x/tcg: fix CPU hotplug with single-threaded TCG

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand run_on_cpu() doesn't seem to work reliably until the CPU has been fully created if the single-threaded TCG main loop is already running. Therefore, hotplugging a CPU under single-threaded TCG does currently not work. We should use the direct call instead of going via run_

[Qemu-devel] [PULL 08/15] s390x/tcg: properly implement the TOD

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand Right now, each CPU has its own TOD. Especially, the TOD will differ based on creation time of a CPU - e.g. when hotplugging a CPU the times will differ quite a lot, resulting in stall warnings in the guest. Let's use a single TOD by implementing our new TOD device. Prepa

[Qemu-devel] [PULL 05/15] s390x/kvm: pass values instead of pointers to kvm_s390_set_clock_*()

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand We are going to factor out the TOD into a separate device and use const pointers for device class functions where possible. We are passing right now ordinary pointers that should never be touched when setting the TOD. Let's just pass the values directly. Note that s390_se

[Qemu-devel] [PULL 10/15] s390x/tcg: implement SET CLOCK

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand This allows a guest to change its TOD. We already take care of updating all CKC timers from within S390TODClass. Use MO_ALIGN to load the operand manually - this will properly trigger a SPECIFICATION exception. Acked-by: Thomas Huth Signed-off-by: David Hildenbrand Mes

[Qemu-devel] [PULL 06/15] s390x/tod: factor out TOD into separate device

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand Let's treat this like a separate device. TCG will have to store the actual state/time later on. Include cpu-qom.h in kvm_s390x.h (due to S390CPU) to compile tod-kvm.c. Reviewed-by: Thomas Huth Signed-off-by: David Hildenbrand Message-Id: <20180627134410.4901-4-da...@re

Re: [Qemu-devel] [PATCH v2 2/3] block/fleecing-filter: new filter driver for fleecing

2018-07-02 Thread Vladimir Sementsov-Ogievskiy
02.07.2018 09:35, Fam Zheng wrote: On Fri, 06/29 12:24, Eric Blake wrote: On 06/29/2018 10:15 AM, Vladimir Sementsov-Ogievskiy wrote: We need to synchronize backup job with reading from fleecing image like it was done in block/replication.c. Otherwise, the following situation is theoretically

[Qemu-devel] [PULL 11/15] s390x/tcg: rearm the CKC timer during migration

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand If the CPU data is migrated after the TOD clock, the CKC timer of a CPU is not rearmed. Let's rearm it when loading the CPU state. Introduce tcg-stub.c just like kvm-stub.c for tcg specific stubs. Reviewed-by: Thomas Huth Signed-off-by: David Hildenbrand Message-Id: <2

[Qemu-devel] [PULL 13/15] s390x/kvm: legacy_s390_alloc() only supports one allocation

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand We always allocate at a fixed address, a second allocation can therefore of course never work. We would simply overwrite mappings. This can e.g. happen in s390_memory_init(), if trying to allocate more than > 8TB. Let's just bail out, as there is no need for supporting it

[Qemu-devel] [PULL 14/15] s390x/kvm: indicate alignment in legacy_s390_alloc()

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand Let's do this for completeness reason, although we don't support e.g. PCDIMM/NVDIMM, which would use the alignment for placing the memory region in guest physical memory. But maybe someday we would want to support something like this - then we don't forget about this if al

[Qemu-devel] [PULL 15/15] s390x/tcg: fix locking problem with tcg_s390_tod_updated

2018-07-02 Thread Cornelia Huck
From: David Hildenbrand tcg_s390_tod_updated() is always called with the iothread being locked (e.g. from S390TODClass->set() e.g. via HELPER(sck) or on incoming migration). The helper we call takes the lock itself - bad. Let's change that by factoring out updating the ckc timer. This now looks

Re: [Qemu-devel] [PATCH v0 0/7] Background snapshots

2018-07-02 Thread Peter Xu
On Fri, Jun 29, 2018 at 11:03:13AM +0300, Denis Plotnikov wrote: > The patch set adds the ability to make external snapshots while VM is running. Hi, Denis, This work is interesting, though I have a few questions to ask in general below. > > The workflow to make a snapshot is the following: > 1

Re: [Qemu-devel] [PATCH v2 2/3] block/fleecing-filter: new filter driver for fleecing

2018-07-02 Thread Vladimir Sementsov-Ogievskiy
29.06.2018 20:24, Eric Blake wrote: On 06/29/2018 10:15 AM, Vladimir Sementsov-Ogievskiy wrote: We need to synchronize backup job with reading from fleecing image like it was done in block/replication.c. Otherwise, the following situation is theoretically possible: Grammar suggestions: 1.

Re: [Qemu-devel] [PATCH v5] crypto: Implement TLS Pre-Shared Keys (PSK).

2018-07-02 Thread Eric Blake
On 07/02/2018 02:52 AM, Daniel P. Berrangé wrote: +#define TLS_PRIORITY_ADDITIONAL_ANON "+ANON-DH" +#define TLS_PRIORITY_ADDITIONAL_PSK "+ECDHE-PSK:+DHE-PSK:+PSK" Unfortunately in testing this I learn ECDHE-PSK is only supported when using GNUTLS >= 3.0, so can you make this conditional ba

Re: [Qemu-devel] [PATCH v6 0/4] Add support for TPM Physical Presence interface

2018-07-02 Thread Igor Mammedov
On Fri, 29 Jun 2018 08:20:38 -0400 Stefan Berger wrote: > On 06/28/2018 01:26 PM, Marc-André Lureau wrote: > > Hi, > > > > The following patches implement the TPM Physical Presence Interface > > that allows a user to set a command via ACPI (sysfs entry in Linux) > > that, upon the next reboot, th

Re: [Qemu-devel] [PATCH] qemu-char: reset errno before qemu char write or read action

2018-07-02 Thread Eric Blake
On 07/01/2018 07:49 PM, xinhua.Cao wrote: In the tcp_chr_write function, we checked errno, but errno was not reset before a read or write operation. Therefore, this check of errno's actions is often incorrect after EAGAIN has occurred. We reset errno before reading and writing to ensure the corre

Re: [Qemu-devel] [PATCH v2 2/3] block/fleecing-filter: new filter driver for fleecing

2018-07-02 Thread Vladimir Sementsov-Ogievskiy
29.06.2018 20:30, John Snow wrote: On 06/29/2018 11:15 AM, Vladimir Sementsov-Ogievskiy wrote: We need to synchronize backup job with reading from fleecing image like it was done in block/replication.c. Otherwise, the following situation is theoretically possible: 1. client start reading 2. c

Re: [Qemu-devel] [PATCH v3 00/23] target/openrisc improvements

2018-07-02 Thread Stafford Horne
On Sun, Jul 01, 2018 at 07:39:08PM -0700, no-re...@patchew.org wrote: > Hi, > > This series seems to have some coding style problems. See output below for > more information: > > Type: series > Message-id: 20180628030330.15615-1-richard.hender...@linaro.org > Subject: [Qemu-devel] [PATCH v3 00/23

Re: [Qemu-devel] [PATCH v3 0/2] backup: Use copy offloading

2018-07-02 Thread Jeff Cody
On Mon, Jul 02, 2018 at 05:04:20PM +0800, Fam Zheng wrote: > Jeff: ping? Can we have this in 3.0? > Yes - can you rebase on current master? I can resolve the conflicts myself if not. > On Tue, 06/05 22:06, Fam Zheng wrote: > > Based-on: <20180529055959.32002-1-f...@redhat.com> > > ([PATCH v7 00/

Re: [Qemu-devel] [PATCH v2 2/3] block/fleecing-filter: new filter driver for fleecing

2018-07-02 Thread Vladimir Sementsov-Ogievskiy
29.06.2018 20:40, Eric Blake wrote: On 06/29/2018 12:30 PM, John Snow wrote: On 06/29/2018 11:15 AM, Vladimir Sementsov-Ogievskiy wrote: We need to synchronize backup job with reading from fleecing image like it was done in block/replication.c. Otherwise, the following situation is theoretic

Re: [Qemu-devel] [PATCH v3 09/20] kvm: arm64: Make stage2 page table layout dynamic

2018-07-02 Thread Auger Eric
Hi Suzuki, On 06/29/2018 01:15 PM, Suzuki K Poulose wrote: > So far we had a static stage2 page table handling code, based on a > fixed IPA of 40bits. As we prepare for a configurable IPA size per > VM, make our stage2 page table code dynamic, to do the right thing > for a given VM. We ensure the

Re: [Qemu-devel] [PATCH v3 13/20] kvm: arm64: Configure VTCR per VM

2018-07-02 Thread Marc Zyngier
On 29/06/18 12:15, Suzuki K Poulose wrote: > We set VTCR_EL2 very early during the stage2 init and don't > touch it ever. This is fine as we had a fixed IPA size. This > patch changes the behavior to set the VTCR for a given VM, > depending on its stage2 table. The common configuration for > VTCR i

Re: [Qemu-devel] [PATCH v5] crypto: Implement TLS Pre-Shared Keys (PSK).

2018-07-02 Thread Daniel P . Berrangé
On Mon, Jul 02, 2018 at 06:54:41AM -0500, Eric Blake wrote: > On 07/02/2018 02:52 AM, Daniel P. Berrangé wrote: > > > > > > +#define TLS_PRIORITY_ADDITIONAL_ANON "+ANON-DH" > > > > > +#define TLS_PRIORITY_ADDITIONAL_PSK "+ECDHE-PSK:+DHE-PSK:+PSK" > > > > > > > > Unfortunately in testing this I l

Re: [Qemu-devel] [RFC v2] arm: Add NRF51 SOC non-volatile memory controller

2018-07-02 Thread Peter Maydell
On 27 June 2018 at 10:44, Stefan Hajnoczi wrote: > On Tue, Jun 26, 2018 at 11:32:04AM +0200, Steffen Görtz wrote: >> Changes since V1: >> - Code style changes > > Please put the changelog below '---'. > >> diff --git a/hw/nvram/nrf51_nvmc.c b/hw/nvram/nrf51_nvmc.c >> new file mode 100644 >> index

Re: [Qemu-devel] [PATCH v1] qemu-pr-helper: garbage response structure can be used to write data

2018-07-02 Thread Paolo Bonzini
On 02/07/2018 10:52, Dima Stepanov wrote: > Ping. > > On Fri, Jun 15, 2018 at 12:11:44PM +0300, Dima Stepanov wrote: >> The prh_co_entry() routine handles requests. The first part is to read a >> request by calling the prh_read_request() routine, if: >> 1. scsi_cdb_xfer(req->cdb) call returns 0,

Re: [Qemu-devel] [PATCH v2 1/3] arm: Add Nordic Semiconductor nRF51 SoC

2018-07-02 Thread Stefan Hajnoczi
On Thu, Jun 28, 2018 at 12:08:13AM +0930, Joel Stanley wrote: > +/* TODO: Flash size should be defined by the board. Microbit uses 256KB */ > +#define FLASH_BASE 0x > +#define FLASH_SIZE (256 * 1024) > + > +/* TODO: Flash size should be defined by the board. Microbit uses 16KB */

Re: [Qemu-devel] [PATCH v2 2/3] arm: Add BBC micro:bit machine

2018-07-02 Thread Stefan Hajnoczi
On Thu, Jun 28, 2018 at 12:08:14AM +0930, Joel Stanley wrote: > diff --git a/hw/arm/microbit.c b/hw/arm/microbit.c > new file mode 100644 > index ..e9e0d35ca79c > --- /dev/null > +++ b/hw/arm/microbit.c > @@ -0,0 +1,56 @@ > +/* > + * BBC micro:bit machine > + * http://tech.microbit.org/

Re: [Qemu-devel] [PATCH v3 00/23] target/openrisc improvements

2018-07-02 Thread Peter Maydell
On 28 June 2018 at 22:31, Stafford Horne wrote: > On Wed, Jun 27, 2018 at 08:03:07PM -0700, Richard Henderson wrote: >> Changes since v2: >> * Fix missing mtspr break. >> * Reorg print_insn_or1k and interrupt logging to the start. >> * Adjust exit after mtspr; fixing smp kernel crash. >> *

Re: [Qemu-devel] [PATCH v2 3/3] MAINTAINERS: Add NRF51 entry

2018-07-02 Thread Stefan Hajnoczi
On Thu, Jun 28, 2018 at 12:08:15AM +0930, Joel Stanley wrote: > This contains the NRF51, and the machine that uses it, the BBC > micro:bit. > > Signed-off-by: Joel Stanley > --- > MAINTAINERS | 8 > 1 file changed, 8 insertions(+) > > diff --git a/MAINTAINERS b/MAINTAINERS > index 8c62

Re: [Qemu-devel] [PATCH 0/4] block: Trivial fixes in offloading code

2018-07-02 Thread Max Reitz
On 2018-07-02 04:58, Fam Zheng wrote: > These are the low priority ones spotted by Kevin and Max last week. > > Fam Zheng (4): > qcow2: Drop unused cluster_data > file-posix: Fix fd_open check in raw_co_copy_range_to > qcow2: Drop unreachable break > raw: Drop superfluous semicolon > > b

Re: [Qemu-devel] [PATCH v5 04/46] checkpatch: Recognize IEC binary prefix definitions

2018-07-02 Thread Paolo Bonzini
On 29/06/2018 23:46, Joe Perches wrote: >>> ERROR: "foo * bar" should be "foo *bar" >>> #310: FILE: hw/ppc/ppc440_uc.c:564: >>> +size = 8 * MiB * sh; >>> total: 1 errors, 0 warnings, 433 lines checked > Does the linux kernel use these? > I don't believe so. > No, I'm n

Re: [Qemu-devel] [PATCH v0 0/7] Background snapshots

2018-07-02 Thread Denis Plotnikov
On 02.07.2018 14:23, Peter Xu wrote: On Fri, Jun 29, 2018 at 11:03:13AM +0300, Denis Plotnikov wrote: The patch set adds the ability to make external snapshots while VM is running. Hi, Denis, This work is interesting, though I have a few questions to ask in general below. The workflow t

Re: [Qemu-devel] [PATCH] tcg: Fix --disable-tcg build breakage

2018-07-02 Thread Peter Maydell
On 29 June 2018 at 21:07, Philippe Mathieu-Daudé wrote: > Fix the --disable-tcg breakage introduced by 8bca9a03ec60d: > > $ configure --disable-tcg > [...] > $ make -C i386-softmmu exec.o > make: Entering directory 'i386-softmmu' > CC exec.o > In file included from s

Re: [Qemu-devel] [PATCH v3 4/4] pc-dimm: assign and verify the "addr" property during pre_plug

2018-07-02 Thread Igor Mammedov
On Mon, 2 Jul 2018 12:39:43 +0200 David Hildenbrand wrote: > On 02.07.2018 12:31, Igor Mammedov wrote: > > On Mon, 2 Jul 2018 11:37:55 +0200 > > David Hildenbrand wrote: > > > >> We can assign and verify the slot before realizing and trying to plug. > > s/slot/"addr"/ > > > >> reading/w

  1   2   3   4   5   6   >