Re: [Qemu-devel] [Webpage PATCH] add support page

2019-08-21 Thread Marc-André Lureau
On Mon, Aug 19, 2019 at 2:58 PM Alex Bennée wrote: > > This is intended to be a useful page we can link to in the banner of > the IRC channel explaining the various support options someone might > have. > > Signed-off-by: Alex Bennée May be you should remove "bug reporting" and "contact" section

[Qemu-devel] [PULL 05/42] migration: Do not re-read the clock on pre_save in case of paused guest

2019-08-21 Thread David Gibson
From: "Maxiwell S. Garcia" Re-read the timebase before migrate was ported from x86 commit: 6053a86fe7bd: kvmclock: reduce kvmclock difference on migration The clock move makes the guest knows about the paused time between the stop and migrate commands. This is an issue in an already-paused VM

[Qemu-devel] [PULL 04/42] spapr_pci: Allow 2MiB and 16MiB IOMMU pagesizes by default

2019-08-21 Thread David Gibson
We've had the qemu and kernel KVM infrastructure to handle larger TCE page sizes for a while, but forgot to update the defaults to actually allow them. This turns that change on. Signed-off-by: David Gibson --- hw/ppc/spapr.c | 6 ++ hw/ppc/spapr_pci.c | 3 ++- 2 files changed, 8 insert

[Qemu-devel] [PULL 01/42] spapr: quantify error messages regarding capability settings

2019-08-21 Thread David Gibson
From: Daniel Black Its not immediately obvious how cap-X=Y setting need to be applied to the command line so, for spapr capability error messages, this has been clarified to: appending -machine cap-X=Y The wrong value messages have been left as is, as the user has found the right location. Re

[Qemu-devel] [PULL 09/42] target/ppc: Optimize emulation of vgbbd instruction

2019-08-21 Thread David Gibson
From: Stefan Brankovic Optimize altivec instruction vgbbd (Vector Gather Bits by Bytes by Doubleword) All ith bits (i in range 1 to 8) of each byte of doubleword element in source register are concatenated and placed into ith byte of appropriate doubleword element in destination register. Follow

[Qemu-devel] [PULL 02/42] spapr_iommu: Fix xlate trace to print translated address

2019-08-21 Thread David Gibson
From: Alexey Kardashevskiy Currently we basically print IO address twice, fix this. Fixes: 7e472264e9e2 ("PPC: spapr: iommu: rework traces") Signed-off-by: Alexey Kardashevskiy Message-Id: <20190812054202.125492-1-...@ozlabs.ru> Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: David Gibson

[Qemu-devel] [PULL 10/42] target/ppc: Optimize emulation of vclzd instruction

2019-08-21 Thread David Gibson
From: Stefan Brankovic Optimize Altivec instruction vclzd (Vector Count Leading Zeros Doubleword). This instruction counts the number of leading zeros of each doubleword element in source register and places result in the appropriate doubleword element of destination register. Using tcg-s count

[Qemu-devel] [PULL 03/42] hw: add compat machines for 4.2

2019-08-21 Thread David Gibson
From: Cornelia Huck Add 4.2 machine types for arm/i440fx/q35/s390x/spapr. For i440fx and q35, unversioned cpu models are still translated to -v1, as 0788a56bd1ae ("i386: Make unversioned CPU models be aliases") states this should only transition to the latest cpu model version in 4.3 (or later).

[Qemu-devel] [PULL 26/42] ppc/xive: Provide unconditional escalation support

2019-08-21 Thread David Gibson
From: Cédric Le Goater When the 'u' bit is set the escalation is said to be 'unconditional' which means that the ESe PQ bits are not used. Introduce a xive_router_end_es_notify() routine to share code with the ESn notification. Signed-off-by: Cédric Le Goater Message-Id: <20190718115420.19919-7

[Qemu-devel] [PULL 00/42] ppc-for-4.2 queue 20190821

2019-08-21 Thread David Gibson
pc-for-4.2-20190821 for you to fetch changes up to c0e6616b6685ffdb4c5e091bc152e46e14703dd1: ppc: Fix emulated single to double denormalized conversions (2019-08-21 17:17:39 +1000) ppc patch queue for 2019-08-21 First ppc and

[Qemu-devel] [PULL 19/42] docs/specs: initial spec summary for Ultravisor-related hcalls

2019-08-21 Thread David Gibson
From: Michael Roth For now this only covers hcalls relating to TPM communication since it's the only one particularly important from a QEMU perspective atm, but others can be added here where it makes sense. The full specification for all hcalls/ucalls will eventually be made available in the pu

[Qemu-devel] [PULL 08/42] target/ppc: move opcode decode tables to PowerPCCPU

2019-08-21 Thread David Gibson
From: Alex Bennée The opcode decode tables aren't really part of the CPUPPCState but an internal implementation detail for the translator. This can cause problems with memcpy in cpu_copy as any table created during ppc_cpu_realize get written over causing a memory leak. To avoid this move the tab

[Qemu-devel] [PULL 33/42] spapr/pci: Consolidate de-allocation of MSIs

2019-08-21 Thread David Gibson
From: Greg Kurz When freeing MSIs, we need to: - remove them from the machine's MSI bitmap - remove them from the IC backend - remove them from the PHB's MSI cache This is currently open coded in two places in rtas_ibm_change_msi(), and we're about to need this in spapr_phb_reset() as well. Inst

[Qemu-devel] [PULL 11/42] target/ppc: Optimize emulation of vclzw instruction

2019-08-21 Thread David Gibson
From: Stefan Brankovic Optimize Altivec instruction vclzw (Vector Count Leading Zeros Word). This instruction counts the number of leading zeros of each word element in source register and places result in the appropriate word element of destination register. Counting is to be performed in four

[Qemu-devel] [PULL 15/42] spapr: Implement dispatch tracking for tcg

2019-08-21 Thread David Gibson
From: Nicholas Piggin Implement cpu_exec_enter/exit on ppc which calls into new methods of the same name in PPCVirtualHypervisorClass. These are used by spapr to implement the splpar VPA dispatch counter initially. Signed-off-by: Nicholas Piggin Message-Id: <20190718034214.14948-2-npig...@gmail

[Qemu-devel] [PULL 06/42] target/ppc: Optimize emulation of lvsl and lvsr instructions

2019-08-21 Thread David Gibson
From: Stefan Brankovic Adding simple macro that is calling tcg implementation of appropriate instruction if altivec support is active. Optimization of altivec instruction lvsl (Load Vector for Shift Left). Place bytes sh:sh+15 of value 0x00 || 0x01 || 0x02 || ... || 0x1E || 0x1F in destination r

[Qemu-devel] [PULL 37/42] spapr/xive: Mask the EAS when allocating an IRQ

2019-08-21 Thread David Gibson
From: Cédric Le Goater If an IRQ is allocated and not configured, such as a MSI requested by a PCI driver, it can be saved in its default state and possibly later on restored using the same state. If not initially MASKED, KVM will try to find a matching priority/target tuple for the interrupt and

[Qemu-devel] [PULL 07/42] target/ppc: Optimize emulation of vsl and vsr instructions

2019-08-21 Thread David Gibson
From: Stefan Brankovic Optimization of altivec instructions vsl and vsr(Vector Shift Left/Rigt). Perform shift operation (left and right respectively) on 128 bit value of register vA by value specified in bits 125-127 of register vB. Lowest 3 bits in each byte element of register vB must be ident

[Qemu-devel] [PULL 12/42] ppc: fix memory leak in spapr_caps_add_properties

2019-08-21 Thread David Gibson
From: Shivaprasad G Bhat Free the capability name string after setting the capability. Signed-off-by: Shivaprasad G Bhat Message-Id: <156335156198.82682.8756968724044750843.st...@lep8c.aus.stglabs.ibm.com> Reviewed-by: Greg Kurz Signed-off-by: David Gibson --- hw/ppc/spapr_caps.c | 4 +++-

[Qemu-devel] [PULL 34/42] spapr/pci: Free MSIs during reset

2019-08-21 Thread David Gibson
From: Greg Kurz When the machine is reset, the MSI bitmap is cleared but the allocated MSIs are not freed. Some operating systems, such as AIX, can detect the previous configuration and assert. Empty the MSI cache, this performs the needed cleanup. Signed-off-by: Greg Kurz Message-Id: <1564152

[Qemu-devel] [PULL 29/42] machine: Add wakeup method to MachineClass

2019-08-21 Thread David Gibson
From: Nicholas Piggin Waking from suspend is not logically a machine reset on all machines, particularly in the paravirtualized case rather than hardware emulated. The ppc spapr machine for example just invokes hypervisor to suspend, and expects that call to return with the machine in the same st

[Qemu-devel] [PULL 16/42] spapr: Implement H_PROD

2019-08-21 Thread David Gibson
From: Nicholas Piggin H_PROD is added, and H_CEDE is modified to test the prod bit according to PAPR. Signed-off-by: Nicholas Piggin Message-Id: <20190718034214.14948-3-npig...@gmail.com> Reviewed-by: Greg Kurz Signed-off-by: David Gibson --- hw/ppc/spapr.c | 1 + hw/ppc/sp

[Qemu-devel] [PULL 18/42] spapr: Implement H_JOIN

2019-08-21 Thread David Gibson
From: Nicholas Piggin This has been useful to modify and test the Linux pseries suspend code but it requires modification to the guest to call it (due to being gated by other unimplemented features). It is not otherwise used by Linux yet, but work is slowly progressing there. Signed-off-by: Nich

[Qemu-devel] [PULL 41/42] ppc: Fix emulated INFINITY and NAN conversions

2019-08-21 Thread David Gibson
From: "Paul A. Clarke" helper_todouble() was not properly converting INFINITY from 32 bit float to 64 bit double. (Normalized operand conversion is unchanged, other than indentation.) Signed-off-by: Paul A. Clarke Message-Id: <1566242388-9244-1-git-send-email...@us.ibm.com> Reviewed-by: Richar

[Qemu-devel] [PULL 28/42] ppc/xive: Improve 'info pic' support

2019-08-21 Thread David Gibson
From: Cédric Le Goater Provide a better output of the XIVE END structures including the escalation information and extend the PowerNV machine 'info pic' command with a dump of the END EAS table used for escalations. Signed-off-by: Cédric Le Goater Message-Id: <20190718115420.19919-9-...@kaod.or

[Qemu-devel] [PULL 13/42] ppc: fix memory leak in spapr_dt_drc()

2019-08-21 Thread David Gibson
From: Shivaprasad G Bhat Leaking the drc_name while preparing the DT properties. Fixing that. Also, remove the const qualifier from spapr_drc_name(). Signed-off-by: Shivaprasad G Bhat Message-Id: <156335159028.82682.5404622104535818162.st...@lep8c.aus.stglabs.ibm.com> Reviewed-by: Greg Kurz

[Qemu-devel] [PULL 17/42] spapr: Implement H_CONFER

2019-08-21 Thread David Gibson
From: Nicholas Piggin This does not do directed yielding and is not quite as strict as PAPR specifies in terms of precise dispatch behaviour. This generally will mean suboptimal performance, rather than guest misbehaviour. Linux does not rely on exact dispatch behaviour. Signed-off-by: Nicholas

[Qemu-devel] [PULL 36/42] spapr: Implement better workaround in spapr-vty device

2019-08-21 Thread David Gibson
From: Paul Mackerras Linux guest kernels have code which scans the string of characters returned from the H_GET_TERM_CHAR hypercall and removes any \0 character which comes immediately after a \r character. This is to work around a bug which was present in some ancient versions of PowerVM. In o

[Qemu-devel] [PULL 14/42] ppc: fix leak in h_client_architecture_support

2019-08-21 Thread David Gibson
From: Shivaprasad G Bhat Free all SpaprOptionVector local pointers after use. Signed-off-by: Shivaprasad G Bhat Message-Id: <156335160761.82682.11912058325777251614.st...@lep8c.aus.stglabs.ibm.com> Reviewed-by: Greg Kurz Signed-off-by: David Gibson --- hw/ppc/spapr_hcall.c | 2 ++ 1 file ch

[Qemu-devel] [PULL 23/42] ppc/xive: Implement TM_PULL_OS_CTX special command

2019-08-21 Thread David Gibson
From: Cédric Le Goater When a vCPU is not dispatched anymore on a HW thread, the Hypervisor (KVM on Linux) invalidates the OS interrupt context of a vCPU with this special command. It returns the OS CAM line value and resets the VO bit. Signed-off-by: Cédric Le Goater Message-Id: <2019071811542

[Qemu-devel] [PULL 38/42] target/ppc: Add Directed Privileged Door-bell Exception State (DPDES) SPR

2019-08-21 Thread David Gibson
From: Alexey Kardashevskiy DPDES stores a status of a doorbell message and if it is lost in migration, the destination CPU won't receive it. This does not hit us much as IPIs complete too quick to catch a pending one and even if we missed one, broadcasts happen often enough to wake that CPU. Thi

[Qemu-devel] [PULL 20/42] spapr: initial implementation for H_TPM_COMM/spapr-tpm-proxy

2019-08-21 Thread David Gibson
From: Michael Roth This implements the H_TPM_COMM hypercall, which is used by an Ultravisor to pass TPM commands directly to the host's TPM device, or a TPM Resource Manager associated with the device. This also introduces a new virtual device, spapr-tpm-proxy, which is used to configure the hos

[Qemu-devel] [PULL 22/42] ppc/xive: use an abstract type for XiveNotifier

2019-08-21 Thread David Gibson
From: Cédric Le Goater Signed-off-by: Cédric Le Goater Message-Id: <20190718115420.19919-2-...@kaod.org> Signed-off-by: David Gibson --- include/hw/ppc/xive.h | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/include/hw/ppc/xive.h b/include/hw/ppc/xive.h index 9399c77d2

[Qemu-devel] [PULL 27/42] ppc/xive: Provide silent escalation support

2019-08-21 Thread David Gibson
From: Cédric Le Goater When the 's' bit is set the escalation is said to be 'silent' or 'silent/gather'. In such configuration, the notification sequence is skipped and only the escalation sequence is performed. This is used to configure all the EQs of a vCPU to escalate on a single EQ which will

[Qemu-devel] [PULL 42/42] ppc: Fix emulated single to double denormalized conversions

2019-08-21 Thread David Gibson
From: "Paul A. Clarke" helper_todouble() was not properly converting any denormalized 32 bit float to 64 bit double. Fix-suggested-by: Richard Henderson Signed-off-by: Paul A. Clarke v2: - Splitting patch "ppc: Three floating point fixes"; this is just one part. - Original suggested "fix" was

[Qemu-devel] [PULL 24/42] ppc/xive: Provide backlog support

2019-08-21 Thread David Gibson
From: Cédric Le Goater If backlog is activated ('b' bit) on the END, the pending priority of a missed event is recorded in the IPB field of the NVT for a later resend. Signed-off-by: Cédric Le Goater Message-Id: <20190718115420.19919-5-...@kaod.org> Signed-off-by: David Gibson --- hw/intc/xiv

[Qemu-devel] [PULL 25/42] ppc/xive: Provide escalation support

2019-08-21 Thread David Gibson
From: Cédric Le Goater If the XIVE presenter can not find the NVT dispatched on any of the HW threads, it can not deliver the interrupt. XIVE offers an escalation mechanism to handle such scenarios and inform the hypervisor that an action should be taken. Escalation is configured by setting the

[Qemu-devel] [PULL 32/42] ppc: remove idle_timer logic

2019-08-21 Thread David Gibson
From: Shivaprasad G Bhat The logic is broken for multiple vcpu guests, also causing memory leak. The logic is in place to handle kvm not having KVM_CAP_PPC_IRQ_LEVEL, which is part of the kernel now since 2.6.37. Instead of fixing the leak, drop the redundant logic which is not excercised on new

[Qemu-devel] [PULL 40/42] ppc: conform to processor User's Manual for xscvdpspn

2019-08-21 Thread David Gibson
From: "Paul A. Clarke" The POWER8 and POWER9 User's Manuals specify the implementation behavior for what the ISA leaves "undefined" behavior for the xscvdpspn and xscvdpsp instructions. This patch corrects the QEMU implementation to match the hardware implementation for that case. ISA 3.0B has

[Qemu-devel] [PULL 35/42] spapr/irq: Drop spapr_irq_msi_reset()

2019-08-21 Thread David Gibson
From: Greg Kurz PHBs already take care of clearing the MSIs from the bitmap during reset or unplug. No need to do this globally from the machine code. Rather add an assert to ensure that PHBs have acted as expected. Signed-off-by: Greg Kurz Message-Id: <156415228966.1064338.190189424190233355.s

[Qemu-devel] [PATCH v2] virtio pmem: user document

2019-08-21 Thread Pankaj Gupta
This patch documents the steps to use virtio pmem. It also documents other useful information about virtio pmem e.g use-case, comparison with Qemu NVDIMM backend and current limitations. Signed-off-by: Pankaj Gupta --- v1->v2 - Fixes on text format and 'Guest Data persistence' section - Corne

[Qemu-devel] [PULL 30/42] i386: use machine class ->wakeup method

2019-08-21 Thread David Gibson
From: Nicholas Piggin Move the i386 suspend_wakeup logic out of the fallback path, and into the new ->wakeup method. Signed-off-by: Nicholas Piggin Message-Id: <20190722061752.22114-1-npig...@gmail.com> Acked-by: Paolo Bonzini Signed-off-by: David Gibson --- hw/i386/pc.c | 8 vl.c

[Qemu-devel] [PULL 31/42] spapr: Implement ibm,suspend-me

2019-08-21 Thread David Gibson
From: Nicholas Piggin This has been useful to modify and test the Linux pseries suspend code but it requires modification to the guest to call it (due to being gated by other unimplemented features). It is not otherwise used by Linux yet, but work is slowly progressing there. This allows a (ligh

[Qemu-devel] [PULL 39/42] ppc: Add support for 'mffsl' instruction

2019-08-21 Thread David Gibson
From: "Paul A. Clarke" ISA 3.0B added a set of Floating-Point Status and Control Register (FPSCR) instructions: mffsce, mffscdrn, mffscdrni, mffscrn, mffscrni, mffsl. This patch adds support for 'mffsl'. 'mffsl' is identical to 'mffs', except it only returns mode, status, and enable bits from th

Re: [Qemu-devel] Regression with floppy drive controller

2019-08-21 Thread Paolo Bonzini
On 21/08/19 08:42, Gerd Hoffmann wrote: >> So we should use '-cpu Conroe' or '-cpu core2duo' minimum? > -cpu Conroe for -M isapc is kida silly though ... > > Maybe we should simply build seabios with CONFIG_TSC_TIMER=n ? > > Using the TSC in a virtual machine is problematic anyway, the > calibrat

Re: [Qemu-devel] [PATCH RFC 0/4] intel_iommu: Do sanity check of vfio-pci earlier

2019-08-21 Thread Paolo Bonzini
On 21/08/19 07:03, Peter Xu wrote: > On Tue, Aug 20, 2019 at 08:24:49AM +0200, Paolo Bonzini wrote: >> On 20/08/19 07:22, Peter Xu wrote: >>> On Mon, Aug 12, 2019 at 09:45:27AM +0200, Peter Xu wrote: This is a RFC series. The VT-d code has some defects, one of them is that we cannot

Re: [Qemu-devel] [PATCH v3 0/4] memory: Fix up coalesced_io_del not working for KVM

2019-08-21 Thread Paolo Bonzini
Looks great, thanks! I'm even squashing together 1/3/4 since it's actually quite readable and the intermediate states aren't really bisectable. Paolo On 20/08/19 16:13, Peter Xu wrote: > v3: > - dropping patch 1 because I'm going to drop the has_coalesced_ranges > variable later... > - moving

Re: [Qemu-devel] [PATCH v4 0/2] char-socket: Fix race condition

2019-08-21 Thread Paolo Bonzini
On 12/08/19 17:58, Andrey Shinkevich wrote: > This fixes a race condition in which the tcp_chr_read() ioc handler > can close a connection that is being written to from another thread. > > v4: > The functions qemu_idle_add() and tcp_chr_be_event_closed() were removed > because the callback

[Qemu-devel] [PATCH 1/1] Fix cacheline detection on FreeBSD/powerpc.

2019-08-21 Thread Laurent Vivier
From: Justin Hibbits machdep.cacheline_size is an integer, not a long. Since PowerPC is big-endian this causes sysctlbyname() to fill in the upper bits of the argument, rather than the correct 'lower bits' of the word. Specify the correct type to fix this. Fixes: b255b2c8a548 ("util: add cache

[Qemu-devel] [PATCH 0/1] Fix cacheline detection on FreeBSD/powerpc

2019-08-21 Thread Laurent Vivier
This is the patch originally sent by Justin, modified to change the parameter size on FreeBSD only. Justin, could you review and test on FreeBSD? Peter, could you run "make check" on your MacOS X host? Thanks, Laurent Justin Hibbits (1): Fix cacheline detection on FreeBSD/powerpc. util/cache

Re: [Qemu-devel] [PULL 00/42] ppc-for-4.2 queue 20190821

2019-08-21 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20190821072542.23090-1-da...@gibson.dropbear.id.au/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Subject: [Qemu-devel] [PULL 00/42] ppc-for-4.2 queue 20190821 Message-id

Re: [Qemu-devel] [Qemu-trivial] [PATCH v2] test: Use g_strndup instead of plain strndup

2019-08-21 Thread Laurent Vivier
Le 08/06/2019 à 07:25, tony.ngu...@bt.com a écrit : > Due to memory management rules. See HACKING. > > Signed-off-by: Tony Nguyen > > diff --git a/tests/check-qjson.c b/tests/check-qjson.c > index fa2afcc..07a773e 100644 > --- a/tests/check-qjson.c > +++ b/tests/check-qjson.c > @@ -767,7 +76

Re: [Qemu-devel] [Qemu-trivial] [PATCH] misc: fix naming scheme of compatiblity arrays

2019-08-21 Thread Laurent Vivier
Le 08/07/2019 à 22:49, Marc-André Lureau a écrit : > Since merge 31ed41889e6e13699871040fe089a2884dca46cb ("Merge > remote-tracking branch > 'remotes/elmarco/tags/machine-props-pull-request' into staging"), the > compat arrays are in lowercase. > > Signed-off-by: Marc-André Lureau > --- > docs/d

Re: [Qemu-devel] [Qemu-trivial] [PATCH] configure: remove obsoleted $sparc_cpu variable

2019-08-21 Thread Laurent Vivier
Le 10/07/2019 à 01:43, Carlo Marcelo Arenas Belón a écrit : > 9b9c37c364 ("tcg-sparc: Assume v9 cpu always, i.e. force v8plus in > 32-bit mode.", 2012-09-21) removed the need for this variable and > most of the references to it, but this one. > > Remove defunct code, no effect or functionality cha

Re: [Qemu-devel] [PATCH] configure: fix sdl detection using sdl2-config

2019-08-21 Thread Laurent Vivier
Le 11/07/2019 à 00:55, Carlo Marcelo Arenas Belón a écrit : > If SDL2 is requested but pkg-config doesn't have a module for it > configure should fallback to use sdl*-config, but wasn't able to > because and old variable (from SDL) was being used by mistake. > > Correct the variable name and compl

[Qemu-devel] [PULL 00/15] Audio 20190821 patches

2019-08-21 Thread Gerd Hoffmann
The following changes since commit 17dc57990320edaad52ac9ea808be9719c91cea6: Merge remote-tracking branch 'remotes/huth-gitlab/tags/pull-request-2019-08-20' into staging (2019-08-20 14:14:20 +0100) are available in the Git repository at: git://git.kraxel.org/qemu tags/audio-201

Re: [Qemu-devel] [Qemu-trivial] [PATCH] .gitignore: ignore some vhost-user* related files

2019-08-21 Thread Laurent Vivier
Le 12/07/2019 à 16:41, Michal Privoznik a écrit : > Commit d52c454aadc creates > '/contrib/vhost-user-gpu/50-qemu-gpu.json' and '/vhost-user-gpu' > and commit 06914c97d3a creates '/vhost-user-input' neither of > which is ignored by git. > > Signed-off-by: Michal Privoznik > --- > .gitignore | 3

[Qemu-devel] [PULL 09/15] paaudio: properly disconnect streams in fini_*

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán Currently this needs a workaround due to bug #247 in pulseaudio. Signed-off-by: Kővágó, Zoltán Reviewed-by: Marc-André Lureau Message-id: c81019d550d9c3518185d3d08bd463ae3ccdc392.1566168923.git.dirty.ice...@gmail.com Signed-off-by: Gerd Hoffmann --- audio/paaudio.c | 25

[Qemu-devel] [PULL 05/15] audio: add audiodev properties to frontends

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán Finally add audiodev= options to audio frontends so users can specify which backend to use when multiple backends exist. Not specifying an audiodev= option currently causes the first audiodev to be used, this is fixed in the next commit. Example usage: -audiodev pa,id=foo -

[Qemu-devel] [PULL 02/15] audio: reduce glob_audio_state usage

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán Remove glob_audio_state from functions, where possible without breaking the API. This means that most static functions in audio.c now take an AudioState pointer instead of implicitly using glob_audio_state. Also included a pointer in SWVoice*, HWVoice* structs, so that func

[Qemu-devel] [PULL 08/15] paaudio: do not move stream when sink/source name is specified

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán Unless we disable stream moving, pulseaudio can easily move the stream on connect, effectively ignoring the source/sink specified by the user. Signed-off-by: Kővágó, Zoltán Reviewed-by: Marc-André Lureau Message-id: c245929463e6e46a48b2875a150815e2ccba11b4.1566168923.git.

[Qemu-devel] [PULL 01/15] audio: Add missing fall through comments

2019-08-21 Thread Gerd Hoffmann
From: Stefan Weil Signed-off-by: Stefan Weil Reviewed-by: Marc-André Lureau Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé Message-id: 20190718193441.12490-1...@weilnetz.de Signed-off-by: Gerd Hoffmann --- audio/audio.c | 2 ++ 1 file changed, 2 insertions(+) diff --

[Qemu-devel] [PULL 15/15] audio: fix memory leak reported by ASAN

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán Signed-off-by: Kővágó, Zoltán Reviewed-by: Philippe Mathieu-Daudé Message-id: ed35e9e72aa77c9376e9c8a8f3a5443703fe6fbe.1566168923.git.dirty.ice...@gmail.com Signed-off-by: Gerd Hoffmann --- audio/audio.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/audio/aud

[Qemu-devel] [PULL 07/15] audio: audiodev= parameters no longer optional when -audiodev present

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán This means you should probably stop using -soundhw (as it doesn't allow you to specify any options) and add the device manually with -device. The exception is pcspk, it's currently not possible to manually add it. To use it with audiodev, use something like this: -audiod

[Qemu-devel] [PULL 03/15] audio: basic support for multi backend audio

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán Audio functions no longer access glob_audio_state, instead they get an AudioState as a parameter. This is required in order to support multiple backends. glob_audio_state is also gone, and replaced with a tailq so we can store more than one states. Signed-off-by: Kővágó, Z

[Qemu-devel] [PULL 04/15] audio: add audiodev property to vnc and wav_capture

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán Signed-off-by: Kővágó, Zoltán Message-id: 8cbc9e865bbf40850c14340fc0549e6ac2d5fe9c.1566168923.git.dirty.ice...@gmail.com Signed-off-by: Gerd Hoffmann --- ui/vnc.h| 2 ++ monitor/misc.c | 22 +++--- ui/vnc.c| 15 ++- hmp-comman

Re: [Qemu-devel] [Qemu-trivial] [PATCH] virtio-net: remove redundant qdev from VirtIONet

2019-08-21 Thread Laurent Vivier
Could you add a commit message describing why we can remove the qdev field? Thanks, Laurent Le 16/07/2019 à 11:08, Anton Kuchin a écrit : > Signed-off-by: Anton Kuchin > --- > hw/net/virtio-net.c| 3 +-- > include/hw/virtio/virtio-net.h | 1 - > 2 files changed, 1 insertion(+), 3 de

[Qemu-devel] [PULL 12/15] paaudio: fix playback glitches

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán Pulseaudio normally assumes that when the server wants it, the client can generate the audio samples and send it right away. Unfortunately this is not the case with QEMU -- it's up to the emulated system when does it generate the samples. Buffering the samples and sending t

[Qemu-devel] [PULL 13/15] audio: remove read and write pcm_ops

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán They just called audio_pcm_sw_read/write anyway, so it makes no sense to have them too. (The noaudio's read is the only exception, but it should work with the generic code too.) Signed-off-by: Kővágó, Zoltán Message-id: 92ddc98133bc4b687c6e4608b9321e7b64c0e496.1566168923.

Re: [Qemu-devel] [PATCH] migrtion: define MigrationState/MigrationIncomingState.state as MigrationStatus

2019-08-21 Thread Wei Yang
On Mon, Aug 19, 2019 at 12:26:55PM +0100, Dr. David Alan Gilbert wrote: >* Wei Yang (richardw.y...@linux.intel.com) wrote: >> On Fri, Jun 21, 2019 at 10:27:39PM +0800, Wei Yang wrote: >> >No functional change. Add default case to fix warning. >> > >> >> Hi, David & Juan >> >> Do you like this? >

[Qemu-devel] [PATCH] ehci: fix queue->dev null ptr dereference

2019-08-21 Thread Gerd Hoffmann
In case we don't have a device for an active queue, just skip processing the queue (same we do for inactive queues) and log a guest bug. Reported-by: Guenter Roeck Signed-off-by: Gerd Hoffmann Tested-by: Guenter Roeck --- hw/usb/hcd-ehci.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a

[Qemu-devel] [PULL 11/15] audio: do not run each backend in audio_run

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán audio_run is called manually by alsa and oss backends when polling. In this case only the requesting backend should be run, not all of them. Signed-off-by: Kővágó, Zoltán Reviewed-by: Marc-André Lureau Message-id: 10221fcea2028fa18d95cf531526ffe3b1d9b21a.1566168923.git.di

Re: [Qemu-devel] [PATCH] ehci: Ensure that device is not NULL before calling usb_ep_get

2019-08-21 Thread Gerd Hoffmann
Hi, > > Yep, as long as the queue is not active this is completely harmless. > > So we need to check a bit later. In execute() looks a bit too late > > though, we don't have a good backup plan then. > > > > Does the patch below solve the problem without bad side effects? > That seems to be wo

[Qemu-devel] [PULL 06/15] paaudio: prepare for multiple audiodev

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán Have a pool of refcounted connections per server, so if the user creates multiple audiodevs to the same pa server, it will use a single connection. (It will still create different streams, so the user can manage those streams separately in pulseaudio.) Signed-off-by: Kővágó

Re: [Qemu-devel] [Qemu-trivial] [PATCH-for-4.1? 1/7] json: Move switch 'fall through' comment to correct place

2019-08-21 Thread Laurent Vivier
Le 19/07/2019 à 15:14, Philippe Mathieu-Daudé a écrit : > Reported by GCC9 when building with CFLAG -Wimplicit-fallthrough=2: > > qobject/json-parser.c: In function ‘parse_literal’: > qobject/json-parser.c:492:24: error: this statement may fall through > [-Werror=implicit-fallthrough=] >

[Qemu-devel] [PULL 10/15] audio: remove audio_MIN, audio_MAX

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán There's already a MIN and MAX macro in include/qemu/osdep.h, use them instead. Signed-off-by: Kővágó, Zoltán Reviewed-by: Marc-André Lureau Message-id: 303222477df6f7373217e0df768635fab5855745.1566168923.git.dirty.ice...@gmail.com Signed-off-by: Gerd Hoffmann --- audio/

Re: [Qemu-devel] [Qemu-trivial] [PATCH-for-4.1? 4/7] hw/ipmi: Rewrite a fall through comment

2019-08-21 Thread Laurent Vivier
Le 19/07/2019 à 15:14, Philippe Mathieu-Daudé a écrit : > GCC9 is confused by this comment when building with CFLAG > -Wimplicit-fallthrough=2: > > hw/ipmi/ipmi_bmc_extern.c: In function ‘addchar’: > hw/ipmi/ipmi_bmc_extern.c:178:12: error: this statement may fall through > [-Werror=implicit-

[Qemu-devel] [PULL 14/15] audio: use size_t where makes sense

2019-08-21 Thread Gerd Hoffmann
From: Kővágó, Zoltán Signed-off-by: Kővágó, Zoltán Message-id: c5193e687fc6cc0f60cb3e90fe69ddf2027d0df1.1566168923.git.dirty.ice...@gmail.com Signed-off-by: Gerd Hoffmann --- audio/audio.h | 4 +- audio/audio_int.h | 26 +++ audio/audio_template.h | 14 ++-- audio/mix

Re: [Qemu-devel] [PATCH 1/7] ati-vga: Add registers for getting apertures

2019-08-21 Thread Gerd Hoffmann
On Sun, Aug 11, 2019 at 11:14:53PM +0200, BALATON Zoltan wrote: > Some drivers (e.g. Linux radeon drm and MacOS) access these to find > apertures to access card. Try to implement these but not sure these > are correct yet. Queued up patch series. thanks, Gerd

Re: [Qemu-devel] [Qemu-trivial] [PATCH] hw/net/e1000: Fix erroneous comment

2019-08-21 Thread Laurent Vivier
Le 15/07/2019 à 12:22, Philippe Mathieu-Daudé a écrit : > Missed during the QOM convertion in 9af21dbee14. > > Signed-off-by: Philippe Mathieu-Daudé > --- > hw/net/e1000.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/hw/net/e1000.c b/hw/net/e1000.c > index 1dc1466332

Re: [Qemu-devel] [Qemu-trivial] [PATCH-for-4.1? 6/7] vl: Rewrite a fall through comment

2019-08-21 Thread Laurent Vivier
Le 19/07/2019 à 15:14, Philippe Mathieu-Daudé a écrit : > GCC9 is confused by this comment when building with CFLAG > -Wimplicit-fallthrough=2: > > vl.c: In function ‘qemu_ref_timedate’: > vl.c:773:15: error: this statement may fall through > [-Werror=implicit-fallthrough=] > 773 |

Re: [Qemu-devel] [PATCH v2] usb: reword -usb command-line option and mention xHCI

2019-08-21 Thread Gerd Hoffmann
On Thu, Aug 15, 2019 at 03:14:28PM +0100, Stefan Hajnoczi wrote: > The -usb section of the man page is not very clear on what exactly -usb > does and fails to mention xHCI as a modern alternative (-device > nec-usb-xhci). > > Signed-off-by: Stefan Hajnoczi Added to usb patch queue. thanks, Ge

Re: [Qemu-devel] [PATCH 2/2] hw/display: Compile various display devices as common object

2019-08-21 Thread Gerd Hoffmann
On Mon, Aug 12, 2019 at 01:37:38PM +0200, Philippe Mathieu-Daudé wrote: > Various display devices are not target-specific and can > be compiled once for all the targets. > After this commit, the 'make world' target is reduced by > 54 objects Doesn't apply, needs a rebase. cheers, Gerd

Re: [Qemu-devel] [Qemu-trivial] [PATCH-for-4.1? 2/7] hw/dma/omap_dma: Move switch 'fall through' comment to correct place

2019-08-21 Thread Laurent Vivier
Le 19/07/2019 à 15:14, Philippe Mathieu-Daudé a écrit : > Reported by GCC9 when building with CFLAG -Wimplicit-fallthrough=2: > > CC hw/dma/omap_dma.o > hw/dma/omap_dma.c: In function ‘omap_dma_write’: > hw/dma/omap_dma.c:1532:12: error: this statement may fall through > [-Werror=imp

Re: [Qemu-devel] [PATCH 2/3] ati-vga: Support unaligned access to hardware cursor registers

2019-08-21 Thread Gerd Hoffmann
Hi, > @@ -672,48 +678,71 @@ static void ati_mm_write(void *opaque, hwaddr addr, > case 0xf00 ... 0xfff: > /* read-only copy of PCI config space so ignore writes */ > break; > -case CUR_OFFSET: > -if (s->regs.cur_offset != (data & 0x87f0)) { > -s

Re: [Qemu-devel] [PATCH 1/2] hw/display/sm501: Remove unused include

2019-08-21 Thread Laurent Vivier
Le 12/08/2019 à 13:37, Philippe Mathieu-Daudé a écrit : > The "cpu.h" include makes devices target-specific. Since it > is not used, remove it, so the device become generic (we can > now compile it once for all targets). > > Signed-off-by: Philippe Mathieu-Daudé > --- > hw/display/sm501.c | 1 -

Re: [Qemu-devel] [PATCH 08/15] ipmi: Split out BT-specific code from ISA BT code

2019-08-21 Thread Philippe Mathieu-Daudé
On 8/19/19 10:16 PM, miny...@acm.org wrote: > From: Corey Minyard > > Get ready for PCI and other BT interfaces. > > No functional changes, just split the code into generic BT code > and ISA-specific BT code. > > Signed-off-by: Corey Minyard Reviewed-by: Philippe Mathieu-Daudé > --- > hw/i

Re: [Qemu-devel] [Qemu-trivial] [PATCH-for-4.1? 5/7] target/ppc: Rewrite a fall through comment

2019-08-21 Thread Laurent Vivier
Le 19/07/2019 à 15:14, Philippe Mathieu-Daudé a écrit : > GCC9 is confused by this comment when building with CFLAG > -Wimplicit-fallthrough=2: > > target/ppc/mmu_helper.c: In function ‘dump_mmu’: > target/ppc/mmu_helper.c:1349:12: error: this statement may fall through > [-Werror=implicit-fa

Re: [Qemu-devel] [PATCH 07/15] ipmi: Split out KCS-specific code from ISA KCS code

2019-08-21 Thread Philippe Mathieu-Daudé
On 8/19/19 10:16 PM, miny...@acm.org wrote: > From: Corey Minyard > > Get ready for PCI and other KCS interfaces. > > No functional changes, just split the code into the generic KCS code > and the ISA-specific code. > > Signed-off-by: Corey Minyard Reviewed-by: Philippe Mathieu-Daudé > ---

Re: [Qemu-devel] [Qemu-trivial] [PATCH-for-4.1? 7/7] spapr_events: Rewrite a fall through comment

2019-08-21 Thread Laurent Vivier
Le 19/07/2019 à 15:14, Philippe Mathieu-Daudé a écrit : > GCC9 is confused by this comment when building with CFLAG > -Wimplicit-fallthrough=2: > > CC ppc64-softmmu/hw/ppc/spapr_rtc.o > hw/ppc/spapr_events.c: In function ‘rtas_event_log_to_source’: > hw/ppc/spapr_events.c:312:12: erro

Re: [Qemu-devel] [PATCH 3/3] ati-vga: Silence some noisy traces

2019-08-21 Thread Gerd Hoffmann
On Fri, Aug 16, 2019 at 12:18:09AM +0200, BALATON Zoltan wrote: > Some registers are accessed very frequently so exclude these from > traces to avoid flooding output with a lot of trace logs when traces > are enabled thus helping debugging. > > Signed-off-by: BALATON Zoltan > --- > hw/display/at

Re: [Qemu-devel] [PATCH 1/3] ati-vga: Implement dummy VBlank IRQ

2019-08-21 Thread Gerd Hoffmann
On Fri, Aug 16, 2019 at 12:18:09AM +0200, BALATON Zoltan wrote: > The MacOS driver exits if the card does not have an interrupt. If we > set PCI_INTERRUPT_PIN to 1 then it enables VBlank interrupts and it > boots but the mouse pointer cannot be moved. This patch implements a > dummy VBlank interrup

[Qemu-devel] [PATCH 1/2] xen-bus: Fix backend state transition on device reset

2019-08-21 Thread Anthony PERARD
When a frontend want to reset its state and the backend one, it start with setting "Closing", then wait for the backend (QEMU) to do the same. But when QEMU is setting "Closing" to its state, it trigger an event (xenstore watch) that re-execute xen_device_backend_changed() and set the backend stat

Re: [Qemu-devel] [PATCH] curses: assert get_wch return value is okay

2019-08-21 Thread Gerd Hoffmann
On Thu, Jul 18, 2019 at 02:01:04PM +0200, Paolo Bonzini wrote: > This prevents the compiler from reporting a possible uninitialized use > of maybe_keycode in function curses_refresh. Fixed whitespace, added to ui queue. thanks, Gerd

[Qemu-devel] [PATCH 0/2] Fix for the xen-bus driver

2019-08-21 Thread Anthony PERARD
Cheers, Anthony PERARD (2): xen-bus: Fix backend state transition on device reset xen-bus: Avoid rewriting identical values to xenstore hw/xen/xen-bus.c | 41 +++-- 1 file changed, 27 insertions(+), 14 deletions(-) -- Anthony PERARD

[Qemu-devel] [PATCH 2/2] xen-bus: Avoid rewriting identical values to xenstore

2019-08-21 Thread Anthony PERARD
When QEMU receive a xenstore watch event suggesting that the "state" or "online" status of the frontend or the backend changed, it record this in its own state but it also re-write the value back into xenstore even so there were no changed. This trigger an unnecessary xenstore watch event which QEM

[Qemu-devel] [PATCH v1 1/4] s390x/tcg: Use guest_addr_valid() instead of h2g_valid() in probe_write_access()

2019-08-21 Thread David Hildenbrand
If I'm not completely wrong, we are dealing with guest addresses here and not with host addresses. Use the right check. Fixes: c5a7392cfb96 ("s390x/tcg: Provide probe_write_access helper") Signed-off-by: David Hildenbrand --- target/s390x/mem_helper.c | 2 +- 1 file changed, 1 insertion(+), 1 de

[Qemu-devel] [PATCH v1 0/4] s390x/tcg: MOVE (MVC): Fault-safe handling

2019-08-21 Thread David Hildenbrand
Newer versions of glibc use memcpy() in memmove() for forward moves. The implementation makese use of MVC. The TCG implementation of MVC is currently not able to handle faults reliably when crossing pages. MVC can cross with 256 bytes at most two pages. In case we get a fault on the second page, w

[Qemu-devel] [PATCH v1 2/4] s390x/tcg: Introduce probe_read_access()

2019-08-21 Thread David Hildenbrand
Let's introduce a helper to probe read access (by actually reading a piece of data of every page) and add a comment why this might not be 100% safe in all scenarios. Once we actually run into that issue, we'll have to think of something else. Signed-off-by: David Hildenbrand --- target/s390x/int

[Qemu-devel] [PATCH v1 3/4] s390x/tcg: MOVE (MVC): Increment the length once

2019-08-21 Thread David Hildenbrand
Let's increment the length once. While at it, cleanup the comment. The memset() example is given as a programming note in the PoP, so drop the description. Signed-off-by: David Hildenbrand --- target/s390x/mem_helper.c | 20 1 file changed, 12 insertions(+), 8 deletions(-)

  1   2   3   4   5   >