Re: [PATCH 3/6] hw/usb/quirks: Use smaller types to reduce .rodata by 10KiB

2020-03-05 Thread Gerd Hoffmann
> struct usb_device_id { > -int vendor_id; > -int product_id; > -int interface_class; > -int interface_subclass; > -int interface_protocol; > +int16_t vendor_id; > +int16_t product_id; > +int8_t interface_class; > +int8_t interface_subclass; > +int8_t interf

Re: [PULL 1/1] qxl: introduce hardware revision 5

2020-03-05 Thread Gerd Hoffmann
Hi, > > +case 5: /* qxl-5 */ > > +pci_device_rev = QXL_REVISION_STABLE_V12 + 1; > > +io_size = pow2ceil(QXL_IO_RANGE_SIZE); > > +break; > this patch -- commit ed71c09ffd6f -- disables ACPI S3 in the Windows 10 > guest for me, using OVMF and QXL. > > The "Sleep" menu

Re: [PATCH v5 14/50] mutli-process: build remote command line args

2020-03-05 Thread Daniel P . Berrangé
On Wed, Mar 04, 2020 at 02:37:43PM -0800, Elena Ufimtseva wrote: > On Wed, Mar 04, 2020 at 04:33:57PM +, Daniel P. Berrangé wrote: > > On Wed, Mar 04, 2020 at 08:25:34AM -0800, Elena Ufimtseva wrote: > > > On Wed, Mar 04, 2020 at 11:00:32AM +, Daniel P. Berrangé wrote: > > > > On Mon, Mar 0

[MERGED PATCH v2 1/5] hw/scsi/viosrp: Add missing 'hw/scsi/srp.h' include

2020-03-05 Thread Philippe Mathieu-Daudé
This header use the srp_* structures declared in "hw/scsi/srp.h". Signed-off-by: Philippe Mathieu-Daudé --- Patch already applied to ppc-for-5.0. hw/scsi/viosrp.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/scsi/viosrp.h b/hw/scsi/viosrp.h index d8e365db1e..25676c2383 100644 --- a/

[PATCH v2 0/5] hw/scsi/spapr_vscsi: Fix time bomb zero-length array use

2020-03-05 Thread Philippe Mathieu-Daudé
This series fixes a dangerous zero-length array use. Simples patches first to clean the issue in the last patch: dissociate the buffer holding DMA requests with pointer to SRP Information Unit packets. v2: Addressed David Gibson review comments Philippe Mathieu-Daudé (5): hw/scsi/viosrp: Add mi

[MERGED PATCH v2 2/5] hw/scsi/spapr_vscsi: Use SRP_MAX_IU_LEN instead of sizeof flexible array

2020-03-05 Thread Philippe Mathieu-Daudé
Replace sizeof() flexible arrays union srp_iu/viosrp_iu by the SRP_MAX_IU_LEN definition, which is what this code actually meant to use. Signed-off-by: Philippe Mathieu-Daudé --- Patch already applied to ppc-for-5.0. hw/scsi/spapr_vscsi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions

[PATCH v2 4/5] hw/scsi/spapr_vscsi: Introduce req_iu() helper

2020-03-05 Thread Philippe Mathieu-Daudé
Introduce the req_iu() helper which returns a pointer to the viosrp_iu union held in the vscsi_req structure. This simplifies the next patch. Signed-off-by: Philippe Mathieu-Daudé --- v2: Simplify req_iu, rename 'ui -> iu' in commit description (dgibson) hw/scsi/spapr_vscsi.c | 39 +

[PATCH v2 5/5] hw/scsi/spapr_vscsi: Do not mix SRP IU size with DMA buffer size

2020-03-05 Thread Philippe Mathieu-Daudé
The 'union srp_iu' is meant as a pointer to any SRP Information Unit type, it is not related to the size of a VIO DMA buffer. Use a plain buffer for the VIO DMA read/write calls. We can remove the reserved buffer from the 'union srp_iu'. This issue was noticed when replacing the zero-length array

[MERGED PATCH v2 3/5] hw/scsi/spapr_vscsi: Simplify a bit

2020-03-05 Thread Philippe Mathieu-Daudé
We already have a ui pointer, use it (to simplify the next commit). Signed-off-by: Philippe Mathieu-Daudé --- Patch already applied to ppc-for-5.0. hw/scsi/spapr_vscsi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/scsi/spapr_vscsi.c b/hw/scsi/spapr_vscsi.c index

Re: [PATCH v4 1/3] s390x: fix memleaks in cpu_finalize

2020-03-05 Thread David Hildenbrand
> #if !defined(CONFIG_USER_ONLY) > MachineState *ms = MACHINE(qdev_get_machine()); > unsigned int max_cpus = ms->smp.max_cpus; > + > +cpu->env.tod_timer = > +timer_new_ns(QEMU_CLOCK_VIRTUAL, s390x_tod_timer, cpu); > +cpu->env.cpu_timer = > +timer_new_ns(QEMU_CLO

Re: [PATCH v7 12/17] spapr: Don't use weird units for MIN_RMA_SLOF

2020-03-05 Thread Philippe Mathieu-Daudé
(sorry I missed that due to the change of series cover subject, I was tracking "Fixes for RMA size calculation​") On 3/3/20 4:43 AM, David Gibson wrote: MIN_RMA_SLOF records the minimum about of RMA that the SLOF firmware requires. It lets us give a meaningful error if the RMA ends up too smal

Re: [PATCH v7 16/17] spapr: Clean up RMA size calculation

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/3/20 4:43 AM, David Gibson wrote: Move the calculation of the Real Mode Area (RMA) size into a helper function. While we're there clean it up and correct it in a few ways: * Add comments making it clearer where the various constraints come from * Remove a pointless check that the RMA

Re: [kvm-unit-tests PATCH v2 2/9] arm: pmu: Let pmu tests take a sub-test parameter

2020-03-05 Thread Andrew Jones
On Thu, Jan 30, 2020 at 12:25:03PM +0100, Eric Auger wrote: > As we intend to introduce more PMU tests, let's add > a sub-test parameter that will allow to categorize > them. Existing tests are in the cycle-counter category. > > Signed-off-by: Eric Auger > --- > arm/pmu.c | 24 ++

Re: [PATCH v7 15/17] spapr: Don't clamp RMA to 16GiB on new machine types

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/3/20 4:43 AM, David Gibson wrote: In spapr_machine_init() we clamp the size of the RMA to 16GiB and the comment saying why doesn't make a whole lot of sense. In fact, this was done because the real mode handling code elsewhere limited the RMA in TCG mode to the maximum value configurable in

Re: [PATCH v7 13/17] spapr,ppc: Simplify signature of kvmppc_rma_size()

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/3/20 4:43 AM, David Gibson wrote: This function calculates the maximum size of the RMA as implied by the host's page size of structure of the VRMA (there are a number of other constraints on the RMA size which will supersede this one in many circumstances). The current interface takes the c

Re: [PATCH v7 10/17] target/ppc: Only calculate RMLS derived RMA limit on demand

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/3/20 4:43 AM, David Gibson wrote: When the LPCR is written, we update the env->rmls field with the RMA limit it implies. Simplify things by just calculating the value directly from the LPCR value when we need it. It's possible this is a little slower, but it's unlikely to be significant, s

Re: [PATCH] audio: Add sndio backend

2020-03-05 Thread Gerd Hoffmann
On Wed, Mar 04, 2020 at 07:04:07AM -0800, no-re...@patchew.org wrote: > Patchew URL: > https://patchew.org/QEMU/20200304145003.gb15...@humpty.home.comstyle.com/ > > > > Hi, > > This series seems to have some coding style problems. See output below for > more information: > > Subject: [PATCH]

Re: [kvm-unit-tests PATCH v2 3/9] arm: pmu: Add a pmu struct

2020-03-05 Thread Andrew Jones
On Thu, Jan 30, 2020 at 12:25:04PM +0100, Eric Auger wrote: > This struct aims at storing information potentially used by > all tests such as the pmu version, the read-only part of the > PMCR, the number of implemented event counters, ... > > Signed-off-by: Eric Auger > --- > arm/pmu.c | 30

Re: [PATCH v7 08/17] target/ppc: Streamline calculation of RMA limit from LPCR[RMLS]

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/3/20 4:43 AM, David Gibson wrote: Currently we use a big switch statement in ppc_hash64_update_rmls() to work out what the right RMA limit is based on the LPCR[RMLS] field. There's no formula for this - it's just an arbitrary mapping defined by the existing CPU implementations - but we can

Re: [PATCH v7 07/17] target/ppc: Use class fields to simplify LPCR masking

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/3/20 4:43 AM, David Gibson wrote: When we store the Logical Partitioning Control Register (LPCR) we have a big switch statement to work out which are valid bits for the cpu model we're emulating. As well as being ugly, this isn't really conceptually correct, since it is based on the mmu_mod

Re: [PATCH v7 01/17] ppc: Remove stub support for 32-bit hypervisor mode

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/3/20 4:43 AM, David Gibson wrote: a4f30719a8cd, way back in 2007 noted that "PowerPC hypervisor mode is not fundamentally available only for PowerPC 64" and added a 32-bit version of the MSR[HV] bit. But nothing was ever really done with that; there is no meaningful support for 32-bit hyper

Re: [PATCH v7 04/17] target/ppc: Introduce ppc_hash64_use_vrma() helper

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/3/20 4:43 AM, David Gibson wrote: When running guests under a hypervisor, the hypervisor obviously needs to be protected from guest accesses even if those are in what the guest considers real mode (translation off). The POWER hardware provides two ways of doing that: The old way has guest r

Re: [PATCH v4 1/3] s390x: fix memleaks in cpu_finalize

2020-03-05 Thread Pan Nengyuan
On 3/5/2020 4:34 PM, David Hildenbrand wrote: > >> #if !defined(CONFIG_USER_ONLY) >> MachineState *ms = MACHINE(qdev_get_machine()); >> unsigned int max_cpus = ms->smp.max_cpus; >> + >> +cpu->env.tod_timer = >> +timer_new_ns(QEMU_CLOCK_VIRTUAL, s390x_tod_timer, cpu); >> +

Re: [kvm-unit-tests PATCH v2 4/9] arm: pmu: Check Required Event Support

2020-03-05 Thread Andrew Jones
On Thu, Jan 30, 2020 at 12:25:05PM +0100, Eric Auger wrote: > If event counters are implemented check the common events > required by the PMUv3 are implemented. > > Some are unconditionally required (SW_INCR, CPU_CYCLES, > either INST_RETIRED or INST_SPEC). Some others only are > required if the i

Re: [PATCH v2] Fixed integer overflow in e1000e

2020-03-05 Thread Dmitry Fleytman
> On 4 Mar 2020, at 16:20, and...@daynix.com wrote: > > From: Andrew Melnychenko > > Fixes: 6f3fbe4ed06 > Buglink: https://bugzilla.redhat.com/show_bug.cgi?id=1737400 > Fixed setting max_queue_num if there are no peers in NICConf. qemu_new_nic() > creates NICState with 1 NetClientState(index 0)

Re: [PATCH 2/3] hw/net/e1000: Move macreg[] arrays to .rodata to save 1MiB of .data

2020-03-05 Thread Dmitry Fleytman
> On 5 Mar 2020, at 3:04, Philippe Mathieu-Daudé wrote: > > Each array consumes 256KiB of .data. As we do not reassign entries, > we can move it to the .rodata section, and save a total of 1MiB of > .data (size reported on x86_64 host). > > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by:

Re: [PATCH 1/3] hw/net/e1000: Add readops/writeops typedefs

2020-03-05 Thread Dmitry Fleytman
> On 5 Mar 2020, at 3:04, Philippe Mathieu-Daudé wrote: > > Express the macreg[] arrays using typedefs. > No logical changes introduced here. > > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Dmitry Fleytman > --- > hw/net/e1000.c | 6 -- > hw/net/e1000e_core.c | 6 -- >

Re: [PATCH v6 04/18] s390x: protvirt: Add migration blocker

2020-03-05 Thread Janosch Frank
On 3/4/20 6:13 PM, David Hildenbrand wrote: > On 04.03.20 12:42, Janosch Frank wrote: >> Migration is not yet supported. >> >> Signed-off-by: Janosch Frank >> --- >> hw/s390x/s390-virtio-ccw.c | 33 - >> 1 file changed, 24 insertions(+), 9 deletions(-) >> >> diff -

Re: [PATCH v2] Fixed integer overflow in e1000e

2020-03-05 Thread Dmitry Fleytman
> On 4 Mar 2020, at 16:20, and...@daynix.com wrote: > > From: Andrew Melnychenko > > Fixes: 6f3fbe4ed06 > Buglink: https://bugzilla.redhat.com/show_bug.cgi?id=1737400 > Fixed setting max_queue_num if there are no peers in NICConf. qemu_new_nic() > creates NICState with 1 NetClientState(index

Re: [PATCH v7 11/17] target/ppc: Don't store VRMA SLBE persistently

2020-03-05 Thread Philippe Mathieu-Daudé
Hi David, On 3/3/20 4:43 AM, David Gibson wrote: Currently, we construct the SLBE used for VRMA translations when the LPCR is written (which controls some bits in the SLBE), then use it later for translations. This is a bit complex and confusing - simplify it by simply constructing the SLBE dir

Re: [PATCH v6 08/18] s390x: Add SIDA memory ops

2020-03-05 Thread Janosch Frank
On 3/4/20 6:39 PM, David Hildenbrand wrote: > On 04.03.20 12:42, Janosch Frank wrote: >> Protected guests save the instruction control blocks in the SIDA >> instead of QEMU/KVM directly accessing the guest's memory. >> >> Let's introduce new functions to access the SIDA. > > "The new memops are av

Re: [PATCH v2 2/3] riscv/sifive_u: Add a serial property to the sifive_u SoC

2020-03-05 Thread Bin Meng
On Thu, Mar 5, 2020 at 7:11 AM Alistair Francis wrote: > > At present the board serial number is hard-coded to 1, and passed > to OTP model during initialization. Firmware (FSBL, U-Boot) uses > the serial number to generate a unique MAC address for the on-chip > ethernet controller. When multiple

Re: [PATCH v6 09/18] s390x: protvirt: Move STSI data over SIDAD

2020-03-05 Thread Janosch Frank
On 3/4/20 6:43 PM, David Hildenbrand wrote: > On 04.03.20 12:42, Janosch Frank wrote: >> For protected guests, we need to put the STSI emulation results into >> the SIDA, so SIE will write them into the guest at the next entry. >> >> Signed-off-by: Janosch Frank >> Acked-by: David Hildenbrand >>

Re: [PATCH v6 04/18] s390x: protvirt: Add migration blocker

2020-03-05 Thread David Hildenbrand
On 05.03.20 10:16, Janosch Frank wrote: > On 3/4/20 6:13 PM, David Hildenbrand wrote: >> On 04.03.20 12:42, Janosch Frank wrote: >>> Migration is not yet supported. >>> >>> Signed-off-by: Janosch Frank >>> --- >>> hw/s390x/s390-virtio-ccw.c | 33 - >>> 1 file chang

Re: [PATCH v1 2/3] riscv/sifive_u: Add a serial property to the sifive_u SoC

2020-03-05 Thread Bin Meng
Hi Alistair, On Thu, Mar 5, 2020 at 7:13 AM Alistair Francis wrote: > > On Wed, Mar 4, 2020 at 6:47 AM Bin Meng wrote: > > > > Hi Alistair, > > > > On Wed, Mar 4, 2020 at 9:37 AM Alistair Francis > > wrote: > > > > > > At present the board serial number is hard-coded to 1, and passed > > > to O

Re: [PATCH] configure: change a typo in zstd config

2020-03-05 Thread Juan Quintela
Philippe Mathieu-Daudé wrote: > On 3/3/20 1:56 PM, Juan Quintela wrote: >> Denis Plotnikov wrote: >>> Package manager --exist flag is used instead of --exists. >>> Fix it. >>> >>> Signed-off-by: Denis Plotnikov >> >> Reviewed-by: Juan Quintela >> >> queued. > > It doesn't seem that trivial: > h

Re: [kvm-unit-tests PATCH v2 5/9] arm: pmu: Basic event counter Tests

2020-03-05 Thread Andrew Jones
On Thu, Jan 30, 2020 at 12:25:06PM +0100, Eric Auger wrote: > Adds the following tests: > - event-counter-config: test event counter configuration > - basic-event-count: > - programs counters #0 and #1 to count 2 required events > (resp. CPU_CYCLES and INST_RETIRED). Counter #0 is preset > to

Re: [PATCH v6 10/18] s390x: protvirt: SCLP interpretation

2020-03-05 Thread Janosch Frank
On 3/4/20 6:48 PM, David Hildenbrand wrote: > On 04.03.20 12:42, Janosch Frank wrote: >> SCLP for a protected guest is done over the SIDAD, so we need to use >> the s390_cpu_virt_mem_* functions to access the SIDAD instead of guest > > nope :) > > s390_cpu_pv_mem_* Ack > >> memory when reading

Re: [kvm-unit-tests PATCH v2 6/9] arm: pmu: Test chained counter

2020-03-05 Thread Andrew Jones
On Thu, Jan 30, 2020 at 12:25:07PM +0100, Eric Auger wrote: > Add 2 tests exercising chained counters. The first one uses > CPU_CYCLES and the second one uses SW_INCR. > > Signed-off-by: Eric Auger > --- > arm/pmu.c | 128 ++ > arm/unittests.cf

Re: [PATCH v6 13/18] s390x: protvirt: Disable address checks for PV guest IO emulation

2020-03-05 Thread Janosch Frank
On 3/4/20 6:55 PM, David Hildenbrand wrote: > On 04.03.20 12:42, Janosch Frank wrote: >> IO instruction data is routed through SIDAD for protected guests, so >> adresses do not need to be checked, as this is kernel memory. >> >> Signed-off-by: Janosch Frank >> Reviewed-by: Thomas Huth >> --- >>

Re: [kvm-unit-tests PATCH v2 5/9] arm: pmu: Basic event counter Tests

2020-03-05 Thread Andrew Jones
On Thu, Jan 30, 2020 at 12:25:06PM +0100, Eric Auger wrote: > Adds the following tests: > - event-counter-config: test event counter configuration > - basic-event-count: > - programs counters #0 and #1 to count 2 required events > (resp. CPU_CYCLES and INST_RETIRED). Counter #0 is preset > to

Re: [PATCH v1 07/10] configure: fix check for libzstd

2020-03-05 Thread Juan Quintela
Alex Bennée wrote: > Alex Bennée writes: > >> Fixes: 3a67848134d0 >> Signed-off-by: Alex Bennée >> --- >> configure | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/configure b/configure >> index 7b373bc0bb8..caa65f58831 100755 >> --- a/configure >> +++ b/configure >>

Re: [PATCH v2] Handle gdb.MemoryError exception in dump-guest-memory.py

2020-03-05 Thread Marc-André Lureau
Hi On Sat, Feb 15, 2020 at 1:34 AM Kevin Buettner wrote: > > [Included a "Signed-off-by" line in this version.] > > I recently investigated a bug in which the dump-guest-memory.py script > sees a gdb.MemoryError exception while attempting to dump memory > obtained from a QEMU core dump. (And, ye

Re: [PATCH v7 11/17] target/ppc: Don't store VRMA SLBE persistently

2020-03-05 Thread Greg Kurz
On Thu, 5 Mar 2020 10:17:03 +0100 Philippe Mathieu-Daudé wrote: > Hi David, > > On 3/3/20 4:43 AM, David Gibson wrote: > > Currently, we construct the SLBE used for VRMA translations when the LPCR > > is written (which controls some bits in the SLBE), then use it later for > > translations. > >

Re: [kvm-unit-tests PATCH v2 7/9] arm: pmu: test 32-bit <-> 64-bit transitions

2020-03-05 Thread Andrew Jones
On Thu, Jan 30, 2020 at 12:25:08PM +0100, Eric Auger wrote: > Test configurations where we transit from 32b to 64b > counters and conversely. Also tests configuration where > chain counters are configured but only one counter is > enabled. > > Signed-off-by: Eric Auger > --- > arm/pmu.c

Re: [PATCH 0/3] hw/net,virtfs-proxy-helper: Reduce .data footprint

2020-03-05 Thread Stefano Garzarella
On Thu, Mar 05, 2020 at 02:04:43AM +0100, Philippe Mathieu-Daudé wrote: > More memory footprint reduction, similar to: > https://lists.gnu.org/archive/html/qemu-devel/2020-03/msg00984.html > > The elf-dissector tool [1] [2] helped to notice the big array. > > [1] https://phabricator.kde.org/sourc

Re: [kvm-unit-tests PATCH v2 8/9] arm: gic: Provide per-IRQ helper functions

2020-03-05 Thread Andrew Jones
On Thu, Jan 30, 2020 at 12:25:09PM +0100, Eric Auger wrote: > From: Andre Przywara > > A common theme when accessing per-IRQ parameters in the GIC distributor > is to set fields of a certain bit width in a range of MMIO registers. > Examples are the enabled status (one bit per IRQ), the level/edg

Re: [PATCH v6 14/18] s390x: protvirt: Move IO control structures over SIDA

2020-03-05 Thread Janosch Frank
On 3/4/20 7:56 PM, David Hildenbrand wrote: > On 04.03.20 12:42, Janosch Frank wrote: >> For protected guests, we need to put the IO emulation results into the >> SIDA, so SIE will write them into the guest at the next entry. >> > > [...] > >> >> if (ioinst_disassemble_sch_ident(reg1, &m,

Re: [PATCH v5 4/5] qcow2: add zstd cluster compression

2020-03-05 Thread Vladimir Sementsov-Ogievskiy
04.03.2020 16:35, Denis Plotnikov wrote: zstd significantly reduces cluster compression time. It provides better compression performance maintaining the same level of the compression ratio in comparison with zlib, which, at the moment, is the only compression method available. The performance te

Re: [PATCH v6 15/18] s390x: protvirt: Handle SIGP store status correctly

2020-03-05 Thread Janosch Frank
On 3/4/20 7:41 PM, David Hildenbrand wrote: > On 04.03.20 12:42, Janosch Frank wrote: >> Status storing is not done by QEMU anymore, but is handled by SIE. >> >> Signed-off-by: Janosch Frank >> Reviewed-by: Thomas Huth >> --- >> target/s390x/helper.c | 4 >> target/s390x/sigp.c | 1 + >>

Re: [PATCH v6 13/18] s390x: protvirt: Disable address checks for PV guest IO emulation

2020-03-05 Thread David Hildenbrand
On 05.03.20 10:42, Janosch Frank wrote: > On 3/4/20 6:55 PM, David Hildenbrand wrote: >> On 04.03.20 12:42, Janosch Frank wrote: >>> IO instruction data is routed through SIDAD for protected guests, so >>> adresses do not need to be checked, as this is kernel memory. >>> >>> Signed-off-by: Janosch

Re: [PATCH v6 14/18] s390x: protvirt: Move IO control structures over SIDA

2020-03-05 Thread David Hildenbrand
On 05.03.20 10:55, Janosch Frank wrote: > On 3/4/20 7:56 PM, David Hildenbrand wrote: >> On 04.03.20 12:42, Janosch Frank wrote: >>> For protected guests, we need to put the IO emulation results into the >>> SIDA, so SIE will write them into the guest at the next entry. >>> >> >> [...] >> >>> >>>

Re: [PATCH 1/6] hw/audio/fmopl: Fix a typo twice

2020-03-05 Thread Laurent Vivier
Le 04/03/2020 à 23:18, Philippe Mathieu-Daudé a écrit : > Signed-off-by: Philippe Mathieu-Daudé > --- > hw/audio/fmopl.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/hw/audio/fmopl.c b/hw/audio/fmopl.c > index 9f50a89b4a..173a7521f2 100644 > --- a/hw/audio/fmopl.c

Re: [PATCH v1 07/10] configure: fix check for libzstd

2020-03-05 Thread Alex Bennée
Juan Quintela writes: > Alex Bennée wrote: >> Alex Bennée writes: >> >>> Fixes: 3a67848134d0 >>> Signed-off-by: Alex Bennée >>> --- >>> configure | 2 +- >>> 1 file changed, 1 insertion(+), 1 deletion(-) >>> >>> diff --git a/configure b/configure >>> index 7b373bc0bb8..caa65f58831 100755 >>

Re: [PATCH v6 10/18] s390x: protvirt: SCLP interpretation

2020-03-05 Thread David Hildenbrand
>>> #endif >>> diff --git a/target/s390x/kvm.c b/target/s390x/kvm.c >>> index 43fc0c088b..a4cbdc5fc6 100644 >>> --- a/target/s390x/kvm.c >>> +++ b/target/s390x/kvm.c >>> @@ -1226,6 +1226,11 @@ static void kvm_sclp_service_call(S390CPU *cpu, >>> struct kvm_run *run, >>> sccb = env->regs[ipb

Re: [PATCH 3/3] virtfs-proxy-helper: Make the helper_opts[] array const

2020-03-05 Thread Greg Kurz
On Thu, 5 Mar 2020 02:04:46 +0100 Philippe Mathieu-Daudé wrote: > Reduce a bit the memory footprint by making the helper_opts[] > array const. > ... and, maybe most importantly, make it clear helper_opts[] is not supposed to be modified at runtime. > Signed-off-by: Philippe Mathieu-Daudé > -

Re: [PATCH v5 40/50] multi-process/mig: build migration module in the remote process

2020-03-05 Thread Dr. David Alan Gilbert
* Jag Raman (jag.ra...@oracle.com) wrote: > > > On 3/4/2020 2:52 PM, Dr. David Alan Gilbert wrote: > > * Jag Raman (jag.ra...@oracle.com) wrote: > > > > > > > > > On 3/4/2020 10:58 AM, Dr. David Alan Gilbert wrote: > > > > * Jagannathan Raman (jag.ra...@oracle.com) wrote: > > > > > Add Makefile

Re: [PATCH v3 1/1] block/rbd: Add support for ceph namespaces

2020-03-05 Thread Florian Florensa
On Mon, Feb 03, 2020 at 12:17:10PM +0100, Florian Florensa wrote: Hello, Any news regarding this ? Regards, Florian > Hello Kevin, > > Just checking in to see if any more work needs to be done on this for a > possible merge. > > Regards, > > Florian > On Fri, Jan 10, 2020 at 09:13:12AM -0500,

Re: [kvm-unit-tests PATCH v2 9/9] arm: pmu: Test overflow interrupts

2020-03-05 Thread Andrew Jones
On Thu, Jan 30, 2020 at 12:25:10PM +0100, Eric Auger wrote: > Test overflows for MEM_ACCESS and SW_INCR events. Also tests > overflows with 64-bit events. > > Signed-off-by: Eric Auger > > --- > > v1 -> v2: > - inline setup_irq() code > --- > arm/pmu.c | 137 +++

Re: [PATCH v1] mips/mips_malta: Allow more than 2G RAM

2020-03-05 Thread Philippe Mathieu-Daudé
Please post new patches as v2, and do not post them as reply to v1. On 3/3/20 1:41 AM, Jiaxun Yang wrote: When malta is coupled with MIPS64 cpu which have 64bit address space, it is possible to have more than 2G RAM. So we removed ram_size check and overwrite memory layout for these targets. S

Re: [PATCH 3/5] hw/scsi/spapr_vscsi: Simplify a bit

2020-03-05 Thread Greg Kurz
On Wed, 4 Mar 2020 16:33:09 +0100 Philippe Mathieu-Daudé wrote: > We already have a ui pointer, use it (to simplify the next commit). > Small typo, s/ui/iu > Signed-off-by: Philippe Mathieu-Daudé > --- > hw/scsi/spapr_vscsi.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) >

[PATCH v4] hw/i386/intel_iommu: Simplify vtd_find_as_from_bus_num() logic

2020-03-05 Thread Philippe Mathieu-Daudé
The vtd_find_as_from_bus_num() function was introduced (in commit dbaabb25f) in a code format that could return an incorrect pointer, which was later fixed by commit a2e1cd41ccf. We could have avoided this by writing the if() statement differently. Do it now, in case this function is re-used. The c

Re: [PATCH v2 0/5] hw/scsi/spapr_vscsi: Fix time bomb zero-length array use

2020-03-05 Thread Paolo Bonzini
On 05/03/20 09:31, Philippe Mathieu-Daudé wrote: > This series fixes a dangerous zero-length array use. > Simples patches first to clean the issue in the last patch: > dissociate the buffer holding DMA requests with pointer to > SRP Information Unit packets. > > v2: Addressed David Gibson review c

Re: [PATCH v1 07/10] configure: fix check for libzstd

2020-03-05 Thread Juan Quintela
Alex Bennée wrote: > Juan Quintela writes: > >> Alex Bennée wrote: >>> Alex Bennée writes: >>> >> >> Can you told me what architecture/distro/os are you using. > > It broke on the CI setup - it could be another issue with the ageing > Travis images (Ubuntu 16.04). > >>> Dropping this patch as

Re: [PATCH 0/3] tests/docker: Fix linking with VirGL

2020-03-05 Thread Philippe Mathieu-Daudé
ping ping? On 2/24/20 1:20 PM, Philippe Mathieu-Daudé wrote: On 2/12/20 9:27 PM, Philippe Mathieu-Daudé wrote: We link with VirGL in our debian-amd64 (cross-host) docker image. This series includes few fixes to keep testing it. ping? Philippe Mathieu-Daudé (3):    tests/docker: Update Vir

Re: [PATCH] tests/docker: Install tools to cross-debug and build Linux kernels

2020-03-05 Thread Philippe Mathieu-Daudé
ping ping? On 2/24/20 1:20 PM, Philippe Mathieu-Daudé wrote: On 2/12/20 9:27 PM, Philippe Mathieu-Daudé wrote: From: Philippe Mathieu-Daudé We often run Linux kernels to test QEMU. We sometimes need to build them manually to use non-default features. We only miss the tiny 'bc' tool. The ncur

Re: [PATCH v3 1/2] spapr: Disable legacy virtio devices for pseries-5.0 and later

2020-03-05 Thread Greg Kurz
On Thu, 5 Mar 2020 15:30:08 +1100 David Gibson wrote: > PAPR specifies a kind of odd, paravirtualized PCI bus, which looks to > the guess mostly like classic PCI, even if some of the individual > devices on the bus are PCI Express. One consequence of that is that > virtio-pci devices still defa

[PATCH] configure: Improve zstd test

2020-03-05 Thread Juan Quintela
There were one error on the test (missing an s for --exists). But we really need a recent zstd (0.8.1). That version was released in 2016, so it is newer that some of our travis images. Just check for the version that we need. Signed-off-by: Juan Quintela Reported-by: Richard Henderson --- con

Re: [PATCH v7 11/17] target/ppc: Don't store VRMA SLBE persistently

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/5/20 10:47 AM, Greg Kurz wrote: On Thu, 5 Mar 2020 10:17:03 +0100 Philippe Mathieu-Daudé wrote: Hi David, On 3/3/20 4:43 AM, David Gibson wrote: Currently, we construct the SLBE used for VRMA translations when the LPCR is written (which controls some bits in the SLBE), then use it later

Re: [PATCH 0/3] hw/net,virtfs-proxy-helper: Reduce .data footprint

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/5/20 10:53 AM, Stefano Garzarella wrote: On Thu, Mar 05, 2020 at 02:04:43AM +0100, Philippe Mathieu-Daudé wrote: More memory footprint reduction, similar to: https://lists.gnu.org/archive/html/qemu-devel/2020-03/msg00984.html The elf-dissector tool [1] [2] helped to notice the big array.

Re: [PATCH v5 34/50] multi-process/mon: choose HMP commands based on target

2020-03-05 Thread Dr. David Alan Gilbert
* Jagannathan Raman (jag.ra...@oracle.com) wrote: > From: Elena Ufimtseva > > Add "targets" field to HMP command definition to select the targets > which would be supported by each command > > Signed-off-by: Elena Ufimtseva > Signed-off-by: John G Johnson > Signed-off-by: Jagannathan Raman >

Re: [PATCH 3/6] hw/usb/quirks: Use smaller types to reduce .rodata by 10KiB

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/5/20 9:02 AM, Gerd Hoffmann wrote: struct usb_device_id { -int vendor_id; -int product_id; -int interface_class; -int interface_subclass; -int interface_protocol; +int16_t vendor_id; +int16_t product_id; +int8_t interface_class; +int8_t interface_subclas

Re: [PATCH 0/3] hw/net,virtfs-proxy-helper: Reduce .data footprint

2020-03-05 Thread Stefano Garzarella
On Thu, Mar 05, 2020 at 11:37:22AM +0100, Philippe Mathieu-Daudé wrote: > On 3/5/20 10:53 AM, Stefano Garzarella wrote: > > On Thu, Mar 05, 2020 at 02:04:43AM +0100, Philippe Mathieu-Daudé wrote: > > > More memory footprint reduction, similar to: > > > https://lists.gnu.org/archive/html/qemu-devel/

Re: [PATCH v5 36/50] multi-process/mon: enable QMP module support in the remote process

2020-03-05 Thread Dr. David Alan Gilbert
* Jagannathan Raman (jag.ra...@oracle.com) wrote: > Build system changes to enable QMP module in the remote process > > Signed-off-by: Elena Ufimtseva > Signed-off-by: John G Johnson > Signed-off-by: Jagannathan Raman It's odd that this is labelled as QMP changes yet a lot of the code is actua

Re: [PATCH 3/6] hw/usb/quirks: Use smaller types to reduce .rodata by 10KiB

2020-03-05 Thread Philippe Mathieu-Daudé
On Thu, Mar 5, 2020 at 11:41 AM Philippe Mathieu-Daudé wrote: > On 3/5/20 9:02 AM, Gerd Hoffmann wrote: > >> struct usb_device_id { > >> -int vendor_id; > >> -int product_id; > >> -int interface_class; > >> -int interface_subclass; > >> -int interface_protocol; > >> +int1

Re: [PATCH v5 37/50] multi-process/mon: Refactor monitor/chardev functions out of vl.c

2020-03-05 Thread Dr. David Alan Gilbert
* Jagannathan Raman (jag.ra...@oracle.com) wrote: > Some of the initialization helper functions w.r.t monitor & chardev > in vl.c are also used by the remote process. Therefore, these functions > are refactored into shared files that both QEMU & remote process > could use. > > Signed-off-by: Elena

[PATCH v2] hw/net/imx_fec: write TGSR and TCSR3 in imx_enet_write()

2020-03-05 Thread Chen Qun
The current code causes clang static code analyzer generate warning: hw/net/imx_fec.c:858:9: warning: Value stored to 'value' is never read value = value & 0x000f; ^ ~~ hw/net/imx_fec.c:864:9: warning: Value stored to 'value' is never read value = v

RE: [PATCH v2] hw/net/imx_fec: write TGSR and TCSR3 in imx_enet_write()

2020-03-05 Thread Chenqun (kuhn)
>-Original Message- >From: Chenqun (kuhn) >Sent: Thursday, March 5, 2020 6:53 PM >To: qemu-devel@nongnu.org; qemu-triv...@nongnu.org >Cc: peter.mayd...@linaro.org; Zhanghailiang >; jasow...@redhat.com; >peter.ch...@nicta.com.au; qemu-...@nongnu.org; Chenqun (kuhn) >; Euler Robot >Subject:

Re: [kvm-unit-tests PATCH v2 8/9] arm: gic: Provide per-IRQ helper functions

2020-03-05 Thread Alexandru Elisei
Hi, I'm going to reiterate the comments I posted on this exact same patch sent by Andre [1], and add a few new ones. [1] https://www.spinics.net/lists/arm-kernel/msg767690.html On 3/5/20 9:55 AM, Andrew Jones wrote: > On Thu, Jan 30, 2020 at 12:25:09PM +0100, Eric Auger wrote: >> From: Andre Prz

Re: [PATCH v4] hw/i386/intel_iommu: Simplify vtd_find_as_from_bus_num() logic

2020-03-05 Thread Michael S. Tsirkin
On Thu, Mar 05, 2020 at 11:27:02AM +0100, Philippe Mathieu-Daudé wrote: > The vtd_find_as_from_bus_num() function was introduced (in commit > dbaabb25f) in a code format that could return an incorrect pointer, > which was later fixed by commit a2e1cd41ccf. > We could have avoided this by writing th

Re: [PATCH v6 13/18] s390x: protvirt: Disable address checks for PV guest IO emulation

2020-03-05 Thread Janosch Frank
On 3/5/20 11:00 AM, David Hildenbrand wrote: > On 05.03.20 10:42, Janosch Frank wrote: >> On 3/4/20 6:55 PM, David Hildenbrand wrote: >>> On 04.03.20 12:42, Janosch Frank wrote: IO instruction data is routed through SIDAD for protected guests, so adresses do not need to be checked, as thi

Re: [PATCH v6 13/18] s390x: protvirt: Disable address checks for PV guest IO emulation

2020-03-05 Thread David Hildenbrand
On 05.03.20 12:26, Janosch Frank wrote: > On 3/5/20 11:00 AM, David Hildenbrand wrote: >> On 05.03.20 10:42, Janosch Frank wrote: >>> On 3/4/20 6:55 PM, David Hildenbrand wrote: On 04.03.20 12:42, Janosch Frank wrote: > IO instruction data is routed through SIDAD for protected guests, so >

Re: [PATCH v2] hw/net/imx_fec: write TGSR and TCSR3 in imx_enet_write()

2020-03-05 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200305105325.31264-1-kuhn.chen...@huawei.com/ Hi, This series failed the docker-quick@centos7 build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. === TEST SCRIPT BEGI

Re: [PATCH v2] hw/net/imx_fec: write TGSR and TCSR3 in imx_enet_write()

2020-03-05 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20200305105325.31264-1-kuhn.chen...@huawei.com/ Hi, This series failed the docker-mingw@fedora 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

Re: [PATCH v7 06/10] iotests: limit line length to 79 chars

2020-03-05 Thread Kevin Wolf
Am 05.03.2020 um 00:14 hat John Snow geschrieben: > > > On 3/4/20 4:58 PM, Philippe Mathieu-Daudé wrote: Adding back the context: > -sys.stderr.write('qemu-img received signal %i: %s\n' % (-exitcode, ' > '.join(qemu_img_args + list(args > +sys.stderr.write('qemu-img receive

Re: [PATCH 3/6] hw/usb/quirks: Use smaller types to reduce .rodata by 10KiB

2020-03-05 Thread Gerd Hoffmann
> > And went this less intrusive way. > > > > I'll respin with s/-1/UINT8_MAX/. > > Problem, now this entry is ignored (interface_class==-1): Yep, "-1" is used as "not used" or "end-of-list" indicator, and it is outside the valid range to avoid that kind of clashes. You need some other way to ex

Re: [PATCH v3 2/2] spapr: Enable virtio iommu_platform=on by default

2020-03-05 Thread Greg Kurz
On Thu, 5 Mar 2020 15:30:09 +1100 David Gibson wrote: > Traditionally, virtio devices don't do DMA by the usual path on the > guest platform. In particular they usually bypass any virtual IOMMU > the guest has, using hypervisor magic to access untranslated guest > physical addresses. > > There

Re: [PATCH v6 06/18] s390x: protvirt: Inhibit balloon when switching to protected mode

2020-03-05 Thread Christian Borntraeger
On 04.03.20 12:42, Janosch Frank wrote: > Ballooning in protected VMs can only be done when the guest shares the > pages it gives to the host. If pages are not shared, the integrity > checks will fail once those pages have been altered and are given back > to the guest. > > Hence, until we have

Re: [PATCH 3/6] hw/usb/quirks: Use smaller types to reduce .rodata by 10KiB

2020-03-05 Thread Philippe Mathieu-Daudé
On 3/5/20 12:59 PM, Gerd Hoffmann wrote: And went this less intrusive way. I'll respin with s/-1/UINT8_MAX/. Problem, now this entry is ignored (interface_class==-1): Yep, "-1" is used as "not used" or "end-of-list" indicator, and it is outside the valid range to avoid that kind of clashes.

Re: [PATCH v2 1/4] qapi: net: Add query-netdevs command

2020-03-05 Thread Markus Armbruster
Alexey Kirillov writes: > Add a qmp command that provides information about currently attached > network devices and their configuration. Closes a gap in QMP; appreciated! > Signed-off-by: Alexey Kirillov [...] > diff --git a/qapi/net.json b/qapi/net.json > index 1cb9a7d782..4f329a1de0 100644

Re: [PATCH v6 02/18] s390x: protvirt: Add diag308 subcodes 8 - 10

2020-03-05 Thread Janosch Frank
On 3/4/20 6:04 PM, David Hildenbrand wrote: > On 04.03.20 12:42, Janosch Frank wrote: >> For diag308 subcodes 8 - 10 we have a new ipib of type 5. The ipib >> holds the address and length of the secure execution header, as well >> as a list of guest components. >> >> Each component is a block of me

Re: [PATCH v5 4/5] qcow2: add zstd cluster compression

2020-03-05 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > 04.03.2020 16:35, Denis Plotnikov wrote: >> zstd significantly reduces cluster compression time. >> It provides better compression performance maintaining >> the same level of the compression ratio in comparison with >> zlib, which, at the moment, is the onl

[PATCH v3 0/7] hw/scsi/spapr_vscsi: Fix time bomb buffer overflow

2020-03-05 Thread Philippe Mathieu-Daudé
This series fixes a possible buffer overflow. Simples patches first (dissociate the buffer holding DMA requests with pointer to SRP Information Unit packets) to clean the issue in the penultimate patch. v3: - Fixed typo reported by Greg Kurz - Addressed Paolo Bonzini review comments as an extra p

[PATCH v3 1/7] hw/scsi/viosrp: Add missing 'hw/scsi/srp.h' include

2020-03-05 Thread Philippe Mathieu-Daudé
This header use the srp_* structures declared in "hw/scsi/srp.h". Signed-off-by: Philippe Mathieu-Daudé --- hw/scsi/viosrp.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/scsi/viosrp.h b/hw/scsi/viosrp.h index d8e365db1e..25676c2383 100644 --- a/hw/scsi/viosrp.h +++ b/hw/scsi/viosrp.h

[PATCH v3 2/7] hw/scsi/spapr_vscsi: Use SRP_MAX_IU_LEN instead of sizeof flexible array

2020-03-05 Thread Philippe Mathieu-Daudé
Replace sizeof() flexible arrays union srp_iu/viosrp_iu by the SRP_MAX_IU_LEN definition, which is what this code actually meant to use. Signed-off-by: Philippe Mathieu-Daudé --- hw/scsi/spapr_vscsi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/scsi/spapr_vscsi.c

[PATCH v3 3/7] hw/scsi/spapr_vscsi: Simplify a bit

2020-03-05 Thread Philippe Mathieu-Daudé
We already have a 'iu' pointer, use it (this simplifies the next commit). Signed-off-by: Philippe Mathieu-Daudé --- since v2: fixed typo in description (Greg Kurz) --- hw/scsi/spapr_vscsi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/scsi/spapr_vscsi.c b/hw/scsi/

[PATCH v3 6/7] hw/scsi/spapr_vscsi: Prevent buffer overflow

2020-03-05 Thread Philippe Mathieu-Daudé
Depending on the length of sense data, vscsi_send_rsp() can overrun the buffer size. Do not copy more than SRP_MAX_IU_DATA_LEN bytes, and assert that vscsi_send_iu() is always called with a size in range. Reported-by: Paolo Bonzini Suggested-by: Paolo Bonzini Signed-off-by: Philippe Mathieu-Daud

[PATCH v3 4/7] hw/scsi/spapr_vscsi: Introduce req_iu() helper

2020-03-05 Thread Philippe Mathieu-Daudé
Introduce the req_iu() helper which returns a pointer to the viosrp_iu union held in the vscsi_req structure. This simplifies the next patch. Signed-off-by: Philippe Mathieu-Daudé --- v2: Simplify req_iu, rename 'ui -> iu' in commit description (dgibson) --- hw/scsi/spapr_vscsi.c | 39 ++

Re: QAPI schema for desired state of LUKS keyslots (was: [PATCH 02/13] qcrypto-luks: implement encryption key management)

2020-03-05 Thread Maxim Levitsky
On Tue, 2020-03-03 at 11:18 +0200, Maxim Levitsky wrote: > On Sat, 2020-02-15 at 15:51 +0100, Markus Armbruster wrote: > > Review of this patch led to a lengthy QAPI schema design discussion. > > Let me try to condense it into a concrete proposal. > > > > This is about the QAPI schema, and therefo

Re: [PATCH v3 0/2] net: tulip: add checks to avoid OOB access

2020-03-05 Thread P J P
+-- On Tue, 3 Mar 2020, no-re...@patchew.org wrote --+ | Patchew URL: https://patchew.org/QEMU/20200303104724.233375-1-ppan...@redhat.com/ | fatal: unable to access 'https://github.com/patchew-project/qemu/': Failed connect to github.com:443; No route to host @Jason, @Sven, These errors seem un

  1   2   3   4   5   >