Re: [PATCH for-6.0] esp: fix setting of ESPState mig_version_id when launching QEMU with -S option

2021-04-09 Thread Thomas Huth
On 07/04/2021 14.48, Mark Cave-Ayland wrote: If QEMU is launched with the -S option then the ESPState mig_version_id property is left unset due to the ordering of the VMState fields in the VMStateDescription for sysbusespscsi and pciespscsi. If the VM is migrated and restored in this stopped

Re: Discussion: Patch series that adds disable-tcg option for ppc targets

2021-04-09 Thread Thomas Huth
On 06/04/2021 08.11, David Gibson wrote: On Mon, Apr 05, 2021 at 01:32:18PM +, Bruno Piazera Larsen wrote: [...] * exclude 8 files from the build (dfp_helper.c, excp_helper.c, fpu_helper.c, int_helper.c, mem_helper.c, misc_helper.c, * translate.c, timebase_helper.c);

Re: [PATCH 1/2] qdev: Separate implementations of qdev_get_machine() for user and system

2021-04-09 Thread Thomas Huth
On 09/04/2021 18.03, Greg Kurz wrote: Despite its simple name and common usage of "getting a pointer to the machine" in system-mode emulation, qdev_get_machine() has some subtilities. First, it can be called when running user-mode emulation : this is because user-mode partly relies on qdev to

Re: [PATCH 2/2] cpu/core: Fix "help" of CPU core device types

2021-04-09 Thread Thomas Huth
On 09/04/2021 18.03, Greg Kurz wrote: Calling qdev_get_machine() from a QOM instance_init function is fragile because we can't be sure the machine object actually exists. And this happens to break when passing ",help" on the command line to get the list of properties for a CPU core device types

Re: [PATCH 2/2] docs/devel/qgraph: add troubleshooting information

2021-04-09 Thread Thomas Huth
On 09/04/2021 21.01, Stefan Hajnoczi wrote: It can be tricky to troubleshoot qos-test when a test won't execute. Add an explanation of how to trace qgraph node connectivity and find which node has the problem. Cc: Emanuele Giuseppe Esposito Cc: Paolo Bonzini Signed-off-by: Stefan Hajnoczi

gitlab-ci check-dco test

2021-04-09 Thread Richard Henderson
On development branches, it's not uncommon to push temporary --fixup patches, and normally one doesn't sign those. But then of course one get hate-mail from the gitlab-ci job about the failing test. Is there a way to make it fatal on staging, but merely a warning on other branches (a-la

Re: [RFC PATCH-for-6.1 v2 6/6] hw/mips/loongson3_virt: Raise CPU clock to 2 GHz

2021-04-09 Thread Huacai Chen
Hi, Philippe, On Fri, Apr 9, 2021 at 5:36 PM Philippe Mathieu-Daudé wrote: > > Commit cd3a53b727d ("clock: Add clock_ns_to_ticks() function") > removed the limitation of using clock with a frequency of 1 GHz > or more. > > The previous commit converted the MIPS CP0 timer to use this > new

Re: [PATCH v2 4/4] hw/i2c: add pca954x i2c-mux switch

2021-04-09 Thread Patrick Venture
On Fri, Apr 9, 2021 at 2:20 PM Philippe Mathieu-Daudé wrote: > > +Paolo/Thomas > > On 4/9/21 7:21 PM, Patrick Venture wrote: > > On Fri, Apr 9, 2021 at 9:51 AM Philippe Mathieu-Daudé > > wrote: > >> > >> Hi Patrick, > >> > >> On 4/9/21 6:25 PM, Patrick Venture wrote: > >>> The pca954x is an i2c

Re: [PATCH v2 4/4] hw/i2c: add pca954x i2c-mux switch

2021-04-09 Thread Philippe Mathieu-Daudé
+Paolo/Thomas On 4/9/21 7:21 PM, Patrick Venture wrote: > On Fri, Apr 9, 2021 at 9:51 AM Philippe Mathieu-Daudé wrote: >> >> Hi Patrick, >> >> On 4/9/21 6:25 PM, Patrick Venture wrote: >>> The pca954x is an i2c mux, and this adds support for two variants of >>> this device: the pca9546 and

Re: [PATCH 2/4] target/ppc: added solutions for building with disable-tcg

2021-04-09 Thread Fabiano Rosas
"Bruno Larsen (billionai)" writes: > this commit presents 2 possible solutions for substituting TCG emulation > with KVM calls. One - used in machine.c and arch_dump.c - explicitly As I mentioned in my reply to your introductory email I don't think we should be replacing TCG routines with calls

[PULL 1/2] i386: Add missing cpu feature bits in EPYC-Rome model

2021-04-09 Thread Eduardo Habkost
From: Babu Moger Found the following cpu feature bits missing from EPYC-Rome model. ibrs: Indirect Branch Restricted Speculation ssbd: Speculative Store Bypass Disable These new features will be added in EPYC-Rome-v2. The -cpu help output after the change. x86 EPYC-Rome

[PULL 2/2] cpu/core: Fix "help" of CPU core device types

2021-04-09 Thread Eduardo Habkost
From: Greg Kurz Calling qdev_get_machine() from a QOM instance_init function is fragile because we can't be sure the machine object actually exists. And this happens to break when passing ",help" on the command line to get the list of properties for a CPU core device types : $

[PULL 0/2] x86 and CPU bug fixes for 6.0-rc3

2021-04-09 Thread Eduardo Habkost
The following changes since commit 471387aa1446e2583f372f79327cc0a8c802b4b4: Merge remote-tracking branch 'remotes/cohuck-gitlab/tags/s390x-20210409' into staging (2021-04-09 17:21:18 +0100) are available in the Git repository at: https://gitlab.com/ehabkost/qemu.git tags/x86-next-pull

[PATCH v3 4/4] hw/i2c: add pca954x i2c-mux switch

2021-04-09 Thread Patrick Venture
The pca954x is an i2c mux, and this adds support for two variants of this device: the pca9546 and pca9548. This device is very common on BMCs to route a different channel to each PCIe i2c bus downstream from the BMC. Signed-off-by: Patrick Venture Reviewed-by: Hao Wu Reviewed-by: Havard

[PATCH v3 0/4] hw/i2c: Adds pca954x i2c mux switch device

2021-04-09 Thread Patrick Venture
The i2c mux device pca954x implements two devices: - the pca9546 and pca9548. v3: - fixup comment with missing end parenthesis. - removed superfluous object cast. v2: - the core i2c bus now calls a match method on each i2c child, which by default will only check for a match against itself.

[PATCH v3 3/4] hw/i2c: move search to i2c_scan_bus method

2021-04-09 Thread Patrick Venture
Moves the search for matching devices on an i2c bus into a separate method. This allows for an object that owns an I2CBus can avoid duplicating this method. Tested: A BMC firmware was booted to userspace and i2c devices were detected. Signed-off-by: Patrick Venture Reviewed-by: Hao Wu ---

[PATCH v3 2/4] hw/i2c: add match method for device search

2021-04-09 Thread Patrick Venture
At the start of an i2c transaction, the i2c bus searches its list of children to identify which devices correspond to the address (or broadcast). Now the I2CSlave device has a method "match" that encapsulates the lookup behavior. This allows the behavior to be changed to support devices, such as

[PATCH v3 1/4] hw/i2c: name I2CNode list in I2CBus

2021-04-09 Thread Patrick Venture
To enable passing the current_devs field as a parameter, we need to use a named struct type. Tested: BMC firmware with i2c devices booted to userspace. Signed-off-by: Patrick Venture Reviewed-by: Hao Wu Reviewed-by: Philippe Mathieu-Daudé --- include/hw/i2c/i2c.h | 4 +++- 1 file changed, 3

Re: [PATCH 1/2] qdev: Separate implementations of qdev_get_machine() for user and system

2021-04-09 Thread Eduardo Habkost
On Fri, Apr 09, 2021 at 06:03:38PM +0200, Greg Kurz wrote: [...] > In order to avoid further subtle breakages like this, change the > implentation of qdev_get_machine() to: > - keep the existing behaviour of creating the dummy "container" > object for the user-mode case only ; > - abort() if the

Re: [PATCH 2/2] cpu/core: Fix "help" of CPU core device types

2021-04-09 Thread Eduardo Habkost
On Fri, Apr 09, 2021 at 06:03:39PM +0200, Greg Kurz wrote: > Calling qdev_get_machine() from a QOM instance_init function is > fragile because we can't be sure the machine object actually > exists. And this happens to break when passing ",help" on the > command line to get the list of properties

Re: [PATCH 1/2] libqos/qgraph: fix "UNAVAILBLE" typo

2021-04-09 Thread Philippe Mathieu-Daudé
On 4/9/21 9:01 PM, Stefan Hajnoczi wrote: > Cc: Emanuele Giuseppe Esposito > Cc: Paolo Bonzini > Signed-off-by: Stefan Hajnoczi > --- > tests/qtest/libqos/qgraph.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Philippe Mathieu-Daudé

Re: [PATCH 1/4] target/ppc: Code motion required to build disabling tcg

2021-04-09 Thread Fabiano Rosas
"Bruno Larsen (billionai)" writes: A general advice for this whole series is: make sure you add in some words explaining why you decided to make a particular change. It will be much easier to review if we know what were the logical steps leading to the change. > This commit does the necessary

Re: Mac OS real USB device support issue

2021-04-09 Thread Programmingkid
> On Apr 7, 2021, at 1:28 AM, Howard Spoelstra wrote: > > On Wed, Apr 7, 2021 at 7:26 AM Howard Spoelstra wrote: >> >> On Wed, Apr 7, 2021 at 3:53 AM Programmingkid >> wrote: >>> >>> >>> On Apr 6, 2021, at 7:18 PM, BALATON Zoltan wrote: On Tue, 6 Apr 2021,

Re: [PATCH v2 0/4] hw/i2c: Adds pca954x i2c mux switch device

2021-04-09 Thread Patrick Venture
On Fri, Apr 9, 2021 at 11:31 AM Corey Minyard wrote: > > On Fri, Apr 09, 2021 at 09:25:41AM -0700, Patrick Venture wrote: > > The i2c mux device pca954x implements two devices: > > - the pca9546 and pca9548. > > > > v2: > > - the core i2c bus now calls a match method on each i2c child, which >

Re: [PATCH v2 4/4] hw/i2c: add pca954x i2c-mux switch

2021-04-09 Thread Patrick Venture
On Fri, Apr 9, 2021 at 11:34 AM Corey Minyard wrote: > > On Fri, Apr 09, 2021 at 09:25:45AM -0700, Patrick Venture wrote: > > The pca954x is an i2c mux, and this adds support for two variants of > > this device: the pca9546 and pca9548. > > > > This device is very common on BMCs to route a

[PATCH 2/2] docs/devel/qgraph: add troubleshooting information

2021-04-09 Thread Stefan Hajnoczi
It can be tricky to troubleshoot qos-test when a test won't execute. Add an explanation of how to trace qgraph node connectivity and find which node has the problem. Cc: Emanuele Giuseppe Esposito Cc: Paolo Bonzini Signed-off-by: Stefan Hajnoczi --- docs/devel/qgraph.rst | 58

[PATCH 1/2] libqos/qgraph: fix "UNAVAILBLE" typo

2021-04-09 Thread Stefan Hajnoczi
Cc: Emanuele Giuseppe Esposito Cc: Paolo Bonzini Signed-off-by: Stefan Hajnoczi --- tests/qtest/libqos/qgraph.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qtest/libqos/qgraph.c b/tests/qtest/libqos/qgraph.c index b3b1a31f81..d1dc491930 100644 ---

[PATCH 0/2] docs/devel/qgraph: add troubleshooting information

2021-04-09 Thread Stefan Hajnoczi
I recently needed to troubleshoot a case where qos-test terminated immediately with no output. In other words, qos-test decided that no tests are runnable. After lots of head scratching and some help from Emanuele it turned out that the machine types weren't being detected as expected. These

Re: [PATCH v2 4/4] hw/i2c: add pca954x i2c-mux switch

2021-04-09 Thread Corey Minyard
On Fri, Apr 09, 2021 at 09:25:45AM -0700, Patrick Venture wrote: > The pca954x is an i2c mux, and this adds support for two variants of > this device: the pca9546 and pca9548. > > This device is very common on BMCs to route a different channel to each > PCIe i2c bus downstream from the BMC. > >

Re: [PATCH v2 0/4] hw/i2c: Adds pca954x i2c mux switch device

2021-04-09 Thread Corey Minyard
On Fri, Apr 09, 2021 at 09:25:41AM -0700, Patrick Venture wrote: > The i2c mux device pca954x implements two devices: > - the pca9546 and pca9548. > > v2: > - the core i2c bus now calls a match method on each i2c child, which > by default will only check for a match against itself. > - the

[Bug 1923197] Re: RISC-V priviledged instruction error

2021-04-09 Thread Teodori Serge
** Changed in: qemu Status: New => Confirmed -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1923197 Title: RISC-V priviledged instruction error Status in QEMU: Confirmed Bug description:

Re: [PULL for-6.0 0/1] s390x fix

2021-04-09 Thread Peter Maydell
are available in the Git repository at: > > https://gitlab.com/cohuck/qemu.git tags/s390x-20210409 > > for you to fetch changes up to d895d25ae2bb8519aa715dd2a97f09d4a66b189d: > > s390x: css: report errors from ccw_dstrea

Resetting non-qdev children in a 3-phase reset device

2021-04-09 Thread Peter Maydell
I wanted to convert the hw/misc/mps2-scc.c device from old-style to 3-phase reset as a prerequisite for another change to the device, but I ran into a problem because currently it has some TYPE_DEVICE QOM child objects, the LEDs. Because TYPE_DEVICE don't live in the qbus hierarchy, the device

Re: [PATCH] checkpatch: Fix use of uninitialized value

2021-04-09 Thread Isaku Yamahata
On Fri, Apr 09, 2021 at 07:40:11AM +0200, Greg Kurz wrote: > On Thu, 8 Apr 2021 10:49:13 -0700 > Isaku Yamahata wrote: > > > > > How about initializing them explicitly as follows? > > ($realfile ne '') prevents the case realfile eq '' && acpi_testexpted eq ''. > > Anyway your patch also

Re: [PATCH for-6.0 v2 6/8] hw/block/nvme: update dmsrl limit on namespace detachment

2021-04-09 Thread Thomas Huth
On 06/04/2021 09.24, Klaus Jensen wrote: On Apr 6 09:10, Philippe Mathieu-Daudé wrote: On 4/5/21 7:54 PM, Klaus Jensen wrote: From: Klaus Jensen The Non-MDTS DMSRL limit must be recomputed when namespaces are detached. Fixes: 645ce1a70cb6 ("hw/block/nvme: support namespace attachment

Re: [PATCH v2 4/4] hw/i2c: add pca954x i2c-mux switch

2021-04-09 Thread Patrick Venture
On Fri, Apr 9, 2021 at 9:51 AM Philippe Mathieu-Daudé wrote: > > Hi Patrick, > > On 4/9/21 6:25 PM, Patrick Venture wrote: > > The pca954x is an i2c mux, and this adds support for two variants of > > this device: the pca9546 and pca9548. > > > > This device is very common on BMCs to route a

Re: [PATCH v4 02/19] flake8: Enforce shorter line length for comments and docstrings

2021-04-09 Thread John Snow
On 4/9/21 5:33 AM, Markus Armbruster wrote: Daniel P. Berrangé writes: On Fri, Mar 26, 2021 at 04:44:25PM +, Peter Maydell wrote: On Fri, 26 Mar 2021 at 16:33, John Snow wrote: Being less terse about it: Mostly, I don't like how it enforces this column width even for indented

Re: General question about parsing an rbd filename

2021-04-09 Thread Connor Kuehl
On 4/9/21 9:27 AM, Markus Armbruster wrote: Connor Kuehl writes: block/rbd.c hints that: * Configuration values containing :, @, or = can be escaped with a * leading "\". Right now, much of the parsing code will allow anyone to escape _anything_ so long as it's preceded by '\'. Is

Re: [PATCH] hw/block/nvme: slba equal to nsze is out of bounds if nlb is 1-based

2021-04-09 Thread Klaus Jensen
On Apr 10 00:30, Keith Busch wrote: On Fri, Apr 09, 2021 at 01:55:01PM +0200, Klaus Jensen wrote: On Apr 9 20:05, Minwoo Im wrote: > On 21-04-09 13:14:02, Gollu Appalanaidu wrote: > > NSZE is the total size of the namespace in logical blocks. So the max > > addressable logical block is NLB

Re: [PATCH for-6.0? 1/3] job: Add job_wait_unpaused() for block-job-complete

2021-04-09 Thread John Snow
On 4/9/21 5:57 AM, Max Reitz wrote: Just as a PS, in a reply to one of Vladimir’s mails (da048f58-43a6-6811-6ad2-0d7899737...@redhat.com) I was wondering whether it even makes sense for mirror to do all the stuff it does in mirror_complete() to do it there.  Aren’t all of those things that

Re: [PATCH v2 4/4] hw/i2c: add pca954x i2c-mux switch

2021-04-09 Thread Philippe Mathieu-Daudé
Hi Patrick, On 4/9/21 6:25 PM, Patrick Venture wrote: > The pca954x is an i2c mux, and this adds support for two variants of > this device: the pca9546 and pca9548. > > This device is very common on BMCs to route a different channel to each > PCIe i2c bus downstream from the BMC. > >

Re: [PATCH] Document qemu-img options data_file and data_file_raw

2021-04-09 Thread Connor Kuehl
On 3/23/21 6:15 PM, John Snow wrote: On 3/1/21 12:28 PM, Connor Kuehl wrote: [..] diff --git a/docs/tools/qemu-img.rst b/docs/tools/qemu-img.rst index b615aa8419..5cc585dc27 100644 --- a/docs/tools/qemu-img.rst +++ b/docs/tools/qemu-img.rst @@ -866,6 +866,18 @@ Supported image file formats:

Re: [PATCH] Document qemu-img options data_file and data_file_raw

2021-04-09 Thread Connor Kuehl
On 3/26/21 4:24 AM, Max Reitz wrote: On 01.03.21 18:28, Connor Kuehl wrote: [..] diff --git a/docs/tools/qemu-img.rst b/docs/tools/qemu-img.rst index b615aa8419..5cc585dc27 100644 --- a/docs/tools/qemu-img.rst +++ b/docs/tools/qemu-img.rst @@ -866,6 +866,18 @@ Supported image file formats:  

Re: [RFC PATCH-for-6.1 v2 4/6] target/mips/cp0_timer: Add ns_substract_to_count() helper

2021-04-09 Thread Richard Henderson
On 4/9/21 2:36 AM, Philippe Mathieu-Daudé wrote: Factor ns_substract_to_count() out to simplify a bit. Signed-off-by: Philippe Mathieu-Daudé --- target/mips/cp0_timer.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) s/substract/subtract/g Also, one usually subtracts

Re: [RFC PATCH-for-6.1 v2 5/6] target/mips/cp0_timer: Use new clock_ns_to_ticks()

2021-04-09 Thread Richard Henderson
On 4/9/21 2:36 AM, Philippe Mathieu-Daudé wrote: -static uint32_t ns_to_count(CPUMIPSState *env, uint64_t ns) +static uint32_t tick_to_count(MIPSCPU *cpu, uint64_t ticks) { -return ns / env->cp0_count_ns; +return ticks / cpu->cp0_count_rate; } I'm not clear on the difference

[PATCH v2 3/4] hw/i2c: move search to i2c_scan_bus method

2021-04-09 Thread Patrick Venture
Moves the search for matching devices on an i2c bus into a separate method. This allows for an object that owns an I2CBus can avoid duplicating this method. Tested: A BMC firmware was booted to userspace and i2c devices were detected. Signed-off-by: Patrick Venture Reviewed-by: Hao Wu ---

Re: [PATCH v2 1/4] hw/i2c: name I2CNode list in I2CBus

2021-04-09 Thread Philippe Mathieu-Daudé
On 4/9/21 6:25 PM, Patrick Venture wrote: > To enable passing the current_devs field as a parameter, we need to use > a named struct type. > > Tested: BMC firmware with i2c devices booted to userspace. > > Signed-off-by: Patrick Venture > Reviewed-by: Hao Wu > --- > include/hw/i2c/i2c.h | 4

Re: [RFC PATCH v2 02/11] python: qemu: pass the wrapper field from QEMUQtestmachine to QEMUMachine

2021-04-09 Thread John Snow
On 4/9/21 12:07 PM, Emanuele Giuseppe Esposito wrote: diff --git a/python/qemu/machine.py b/python/qemu/machine.py index c721e07d63..18d32ebe45 100644 --- a/python/qemu/machine.py +++ b/python/qemu/machine.py @@ -109,7 +109,7 @@ def __init__(self,   self._binary = binary  

Re: [PULL 0/1] Linux user for 6.0 patches

2021-04-09 Thread Peter Maydell
vier/qemu.git tags/linux-user-for-6.0-pull-request > > for you to fetch changes up to 360f0abdc51652b06a3718ed43a8688562e69ca4: > > linux-user: Use signed lengths in uaccess.c (2021-04-07 18:55:27 +0200) > > ----

[PATCH v2 4/4] hw/i2c: add pca954x i2c-mux switch

2021-04-09 Thread Patrick Venture
The pca954x is an i2c mux, and this adds support for two variants of this device: the pca9546 and pca9548. This device is very common on BMCs to route a different channel to each PCIe i2c bus downstream from the BMC. Signed-off-by: Patrick Venture Reviewed-by: Hao Wu Reviewed-by: Havard

Re: trace_FOO_tcg bit-rotted?

2021-04-09 Thread Alex Bennée
Laurent Vivier writes: > Le 06/04/2021 à 18:00, Alex Bennée a écrit : >> Hi, >> >> It's been awhile since I last played with this but I think we are >> suffering from not having some test cases for tracing code >> generation/execution in the tree. I tried adding a simple trace point to >> see

[PATCH v2 1/4] hw/i2c: name I2CNode list in I2CBus

2021-04-09 Thread Patrick Venture
To enable passing the current_devs field as a parameter, we need to use a named struct type. Tested: BMC firmware with i2c devices booted to userspace. Signed-off-by: Patrick Venture Reviewed-by: Hao Wu --- include/hw/i2c/i2c.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff

[PULL 07/10] mirror: Move open_backing_file to exit_common

2021-04-09 Thread Kevin Wolf
From: Max Reitz This is a graph change and therefore should be done in job-finalize (which is what invokes mirror_exit_common()). Signed-off-by: Max Reitz Message-Id: <20210409120422.144040-2-mre...@redhat.com> Signed-off-by: Kevin Wolf --- block/mirror.c | 22 -- 1 file

[PATCH v2 2/4] hw/i2c: add match method for device search

2021-04-09 Thread Patrick Venture
At the start of an i2c transaction, the i2c bus searches its list of children to identify which devices correspond to the address (or broadcast). Now the I2CSlave device has a method "match" that encapsulates the lookup behavior. This allows the behavior to be changed to support devices, such as

[PATCH v2 0/4] hw/i2c: Adds pca954x i2c mux switch device

2021-04-09 Thread Patrick Venture
The i2c mux device pca954x implements two devices: - the pca9546 and pca9548. v2: - the core i2c bus now calls a match method on each i2c child, which by default will only check for a match against itself. - the pca954x device overrides the i2c device match method to search the children for

[PULL 06/10] hw/block/fdc: Fix 'fallback' property on sysbus floppy disk controllers

2021-04-09 Thread Kevin Wolf
From: Philippe Mathieu-Daudé Setting the 'fallback' property corrupts the QOM instance state (FDCtrlSysBus) because it accesses an incorrect offset (it uses the offset of the FDCtrlISABus state). Cc: qemu-sta...@nongnu.org Fixes: a73275dd6fc ("fdc: Add fallback option") Signed-off-by: Philippe

[PULL 08/10] mirror: Do not enter a paused job on completion

2021-04-09 Thread Kevin Wolf
From: Max Reitz Currently, it is impossible to complete jobs on standby (i.e. paused ready jobs), but actually the only thing in mirror_complete() that does not work quite well with a paused job is the job_enter() at the end. If we make it conditional, this function works just fine even if the

[PULL 02/10] block/rbd: fix memory leak in qemu_rbd_co_create_opts()

2021-04-09 Thread Kevin Wolf
From: Stefano Garzarella When we allocate 'q_namespace', we forgot to set 'has_q_namespace' to true. This can cause several issues, including a memory leak, since qapi_free_BlockdevCreateOptions() does not deallocate that memory, as reported by valgrind: 13 bytes in 1 blocks are definitely

[PULL 05/10] iotests: Test mirror-top filter permissions

2021-04-09 Thread Kevin Wolf
From: Max Reitz Add a test accompanying commit 53431b9086b2832ca1aeff0c55e186e9ed79bd11 ("block/mirror: Fix mirror_top's permissions"). Signed-off-by: Max Reitz Message-Id: <20210331122815.51491-1-mre...@redhat.com> Reviewed-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Eric Blake

[PULL 10/10] test-blockjob: Test job_wait_unpaused()

2021-04-09 Thread Kevin Wolf
From: Max Reitz Create a job that remains on STANDBY after a drained section, and see that invoking job_wait_unpaused() will get it unstuck. Signed-off-by: Max Reitz Message-Id: <20210409120422.144040-5-mre...@redhat.com> Signed-off-by: Kevin Wolf --- tests/unit/test-blockjob.c | 121

Re: [PATCH 0/4] job: Allow complete for jobs on standby

2021-04-09 Thread Kevin Wolf
Am 09.04.2021 um 14:04 hat Max Reitz geschrieben: > Hi, > > We sometimes have a problem with jobs remaining on STANDBY after a drain > (for a short duration), so if the user immediately issues a > block-job-complete, that will fail. > > (See also >

Re: [RFC PATCH-for-6.1 v2 3/6] target/mips/cp0_timer: Add ns_to_count() helper

2021-04-09 Thread Richard Henderson
On 4/9/21 2:36 AM, Philippe Mathieu-Daudé wrote: Factor ns_to_count() out to simplify a bit. Signed-off-by: Philippe Mathieu-Daudé --- target/mips/cp0_timer.c | 18 ++ 1 file changed, 10 insertions(+), 8 deletions(-) Reviewed-by: Richard Henderson r~

[PULL 04/10] iotests: add test for removing persistent bitmap from backing file

2021-04-09 Thread Kevin Wolf
From: Vladimir Sementsov-Ogievskiy Just demonstrate one of x-blockdev-reopen usecases. We can't simply remove persistent bitmap from RO node (for example from backing file), as we need to remove it from the image too. So, we should reopen the node first. Signed-off-by: Vladimir

Re: [RFC PATCH-for-6.1 v2 2/6] target/mips/cpu: Update CP0 clock when CPU clock is propagated

2021-04-09 Thread Richard Henderson
On 4/9/21 2:36 AM, Philippe Mathieu-Daudé wrote: Setting the CP0 clock simply on CPU init is incorrect. First because the clock can not be yet propagated. Second because we aimed to support dynamic frequencies in commit a0713e85bfa, so the CPU frequency can be changed*after* init time. The

[PULL 09/10] job: Allow complete for jobs on standby

2021-04-09 Thread Kevin Wolf
From: Max Reitz The only job that implements .complete is the mirror job, and it can handle completion requests just fine while the job is paused. Buglink: https://bugzilla.redhat.com/show_bug.cgi?id=1945635 Signed-off-by: Max Reitz Message-Id: <20210409120422.144040-4-mre...@redhat.com>

[PULL 03/10] iotests/qsd-jobs: Filter events in the first test

2021-04-09 Thread Kevin Wolf
From: Max Reitz The job may or may not be ready before the 'quit' is issued. Whether it is is irrelevant; for the purpose of the test, it only needs to still be there. Filter the job status change and READY events from the output so it becomes reliable. Reported-by: Peter Maydell

Re: [RFC PATCH-for-6.1 v2 1/6] target/mips/cpu: Use clock_has_source() instead of clock_get()

2021-04-09 Thread Richard Henderson
On 4/9/21 2:36 AM, Philippe Mathieu-Daudé wrote: clock_get() returns the clock period. With an unconnected clock we get 0. This is not what we want here. Use the API properly by using the clock_has_source() function instead. Fixes: a0713e85bfa ("target/mips/cpu: Allow the CPU to use dynamic

[PULL 01/10] block/rbd: fix memory leak in qemu_rbd_connect()

2021-04-09 Thread Kevin Wolf
From: Stefano Garzarella In qemu_rbd_connect(), 'mon_host' is allocated by qemu_rbd_mon_host() using g_strjoinv(), but it's only freed in the error path, leaking memory in the success path as reported by valgrind: 80 bytes in 4 blocks are definitely lost in loss record 5,028 of 6,516 at

[PULL 00/10] Block layer fixes for 6.0-rc3

2021-04-09 Thread Kevin Wolf
The following changes since commit ce69aa92d71e13db9c3702a8e8305e8d2463aeb8: Merge remote-tracking branch 'remotes/jasowang/tags/net-pull-request' into staging (2021-04-08 16:45:31 +0100) are available in the Git repository at: git://repo.or.cz/qemu/kevin.git tags/for-upstream for you to

Re: [RFC PATCH v2 02/11] python: qemu: pass the wrapper field from QEMUQtestmachine to QEMUMachine

2021-04-09 Thread Emanuele Giuseppe Esposito
diff --git a/python/qemu/machine.py b/python/qemu/machine.py index c721e07d63..18d32ebe45 100644 --- a/python/qemu/machine.py +++ b/python/qemu/machine.py @@ -109,7 +109,7 @@ def __init__(self,   self._binary = binary   self._args = list(args) -    self._wrapper = wrapper + 

Re: [RFC PATCH v2 04/11] qemu-iotests: delay QMP socket timers

2021-04-09 Thread Emanuele Giuseppe Esposito
On 08/04/2021 21:03, Paolo Bonzini wrote: Il gio 8 apr 2021, 18:06 Emanuele Giuseppe Esposito > ha scritto: On 08/04/2021 17:40, Paolo Bonzini wrote: > On 07/04/21 15:50, Emanuele Giuseppe Esposito wrote: >>   def

[PATCH 1/2] qdev: Separate implementations of qdev_get_machine() for user and system

2021-04-09 Thread Greg Kurz
Despite its simple name and common usage of "getting a pointer to the machine" in system-mode emulation, qdev_get_machine() has some subtilities. First, it can be called when running user-mode emulation : this is because user-mode partly relies on qdev to instantiate its CPU model. Second, but

[PATCH for-6.0 2/2] block/nbd: ensure ->connection_thread is always valid

2021-04-09 Thread Roman Kagan
Simplify lifetime management of BDRVNBDState->connection_thread by delaying the possible cleanup of it until the BDRVNBDState itself goes away. This also fixes possible use-after-free in nbd_co_establish_connection when it races with nbd_co_establish_connection_cancel. Signed-off-by: Roman Kagan

[PATCH 2/2] cpu/core: Fix "help" of CPU core device types

2021-04-09 Thread Greg Kurz
Calling qdev_get_machine() from a QOM instance_init function is fragile because we can't be sure the machine object actually exists. And this happens to break when passing ",help" on the command line to get the list of properties for a CPU core device types : $ ./qemu-system-ppc64 -device

[PATCH for-6.0 1/2] block/nbd: fix channel object leak

2021-04-09 Thread Roman Kagan
nbd_free_connect_thread leaks the channel object if it hasn't been stolen. Unref it and fix the leak. Signed-off-by: Roman Kagan --- block/nbd.c | 1 + 1 file changed, 1 insertion(+) diff --git a/block/nbd.c b/block/nbd.c index c26dc5a54f..d86df3afcb 100644 --- a/block/nbd.c +++ b/block/nbd.c

[PATCH for-6.0 0/2] block/nbd: assorted bugfixes

2021-04-09 Thread Roman Kagan
A couple of bugfixes to block/nbd that look appropriate for 6.0. Roman Kagan (2): block/nbd: fix channel object leak block/nbd: ensure ->connection_thread is always valid block/nbd.c | 59 +++-- 1 file changed, 30 insertions(+), 29

Re: [RFC PATCH v2 01/11] python: qemu: add timer parameter for qmp.accept socket

2021-04-09 Thread Emanuele Giuseppe Esposito
--- a/python/qemu/qtest.py +++ b/python/qemu/qtest.py @@ -138,9 +138,9 @@ def _pre_launch(self) -> None:   super()._pre_launch()   self._qtest = QEMUQtestProtocol(self._qtest_path, server=True) -    def _post_launch(self) -> None: +    def _post_launch(self, timer) -> None:

[PATCH 0/2] cpu/core: Fix "help" of CPU core device types

2021-04-09 Thread Greg Kurz
Thomas Huth recently reported an annoying crash: $ ./qemu-system-ppc64 -device power8_v2.0-spapr-cpu-core,help /home/thuth/devel/qemu/include/hw/boards.h:24: MACHINE: Object 0x5635bd53af10 is not an instance of type machine Aborted (core dumped) This is caused by an early use of

Re: [RFC PATCH 0/4] target/ppc: add disable-tcg option

2021-04-09 Thread no-reply
Patchew URL: https://patchew.org/QEMU/20210409151916.97326-1-bruno.lar...@eldorado.org.br/ Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20210409151916.97326-1-bruno.lar...@eldorado.org.br Subject: [RFC PATCH 0/4]

Re: [Virtio-fs] [PATCH] vhost-user-fs: fix features handling

2021-04-09 Thread Vivek Goyal
On Thu, Apr 08, 2021 at 10:55:34PM +0300, Anton Kuchin wrote: > Make virtio-fs take into account server capabilities. > > Just returning requested features assumes they all of then are implemented > by server and results in setting unsupported configuration if some of them > are absent. > >

Re: [PATCH v2 3/7] ACPI ERST: support for ACPI ERST feature

2021-04-09 Thread Eric DeVolder
Hi Igor, Thank you for reviewing. I've responded inline below. eric From: Igor Mammedov Sent: Tuesday, April 6, 2021 2:31 PM To: Eric DeVolder Cc: m...@redhat.com ; marcel.apfelb...@gmail.com ; pbonz...@redhat.com ; r...@twiddle.net ; ehabk...@redhat.com ;

[RFC PATCH 0/4] target/ppc: add disable-tcg option

2021-04-09 Thread Bruno Larsen (billionai)
This patch series aims to add the option to build without TCG for the powerpc target. This RFC shows mostly the strategies employed when dealing with compilation problems, and ask for input on the bits we don't quite understand yet. The first patch mostly code motion, as referenced in

[PATCH 3/4] target/ppc: Add stubs for tcg functions, so it builds

2021-04-09 Thread Bruno Larsen (billionai)
This file basically adds all stubs required to build the project with disable-tcg. most of these are not going to remain stubs by the end, but this part is where it got complicated, and I wanted to get an RFC ASAP. Most of these have to do with mmu emulation, so they'll probably be replaced by a

[PATCH 2/4] target/ppc: added solutions for building with disable-tcg

2021-04-09 Thread Bruno Larsen (billionai)
this commit presents 2 possible solutions for substituting TCG emulation with KVM calls. One - used in machine.c and arch_dump.c - explicitly adds the KVM function and has the possibility of adding the TCG one for more generic compilation, prioritizing te KVM option. The second option, implemented

[PATCH 4/4] target/ppc: updated build rules for disable-tcg option

2021-04-09 Thread Bruno Larsen (billionai)
updated the meson file to respect the disable-tcg option and only add relevant files to the build process Signed-off-by: Bruno Larsen (billionai) --- target/ppc/meson.build | 22 +++--- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/target/ppc/meson.build

[PATCH 1/4] target/ppc: Code motion required to build disabling tcg

2021-04-09 Thread Bruno Larsen (billionai)
This commit does the necessary code motion from translate_init.c.inc This moves all functions that start with gdb_* into target/ppc/gdbstub.c and creates a new function that calls those and is called by ppc_cpu_realize All functions related to realizing the cpu have been moved to cpu.c, which may

Re: [PATCH v3] hw/block/nvme: add device self test command support

2021-04-09 Thread Keith Busch
On Wed, Mar 31, 2021 at 02:54:27PM +0530, Gollu Appalanaidu wrote: > This is to add support for Device Self Test Command (DST) and > DST Log Page. Refer NVM Express specification 1.4b section 5.8 > ("Device Self-test command") Please don't write change logs that just say what you did. I can read

Re: [PATCH v2] monitor/qmp: fix race on CHR_EVENT_CLOSED without OOB

2021-04-09 Thread Markus Armbruster
I considered this for 6.0, but decided not to rock the boat at this late stage. Queued for 6.1, thanks!

Re: [PATCH] hw/block/nvme: slba equal to nsze is out of bounds if nlb is 1-based

2021-04-09 Thread Keith Busch
On Fri, Apr 09, 2021 at 01:55:01PM +0200, Klaus Jensen wrote: > On Apr 9 20:05, Minwoo Im wrote: > > On 21-04-09 13:14:02, Gollu Appalanaidu wrote: > > > NSZE is the total size of the namespace in logical blocks. So the max > > > addressable logical block is NLB minus 1. So your starting logical

Re: [PATCH v4 cxl-2.0-doe 3/3] PCIe standard header for DOE

2021-04-09 Thread Jonathan Cameron
On Wed, 31 Mar 2021 12:37:08 -0400 Chris Browy wrote: > From: hchkuo > > Signed-off-by: hchkuo Code must build after each patch, so this needs to go first in the series, not last. git rebase -i HEAD~3 and reorder the patches should be an easy way to do it. + add a note to say

Re: [PATCH for-6.0 1/2] hw/arm/mps2-tz: Fix MPC setting for AN524 SRAM block

2021-04-09 Thread Philippe Mathieu-Daudé
On 4/9/21 5:05 PM, Peter Maydell wrote: > The AN524 has three MPCs: one for the BRAM, one for the QSPI flash, > and one for the DDR. We incorrectly set the .mpc field in the > RAMInfo struct for the SRAM block to 1, giving it the same MPC we are > using for the QSPI. The effect of this was that

Re: [PATCH v4 cxl-2.0-doe 2/3] CXL Data Object Exchange implementation

2021-04-09 Thread Jonathan Cameron
On Wed, 31 Mar 2021 12:36:58 -0400 Chris Browy wrote: > From: hchkuo Again, must have a description, plus a sign off from Chris if Chris is the person sending the patch out. > > Signed-off-by: hchkuo Please split this into 2 patches. Add the DOE + CDAT in first patch, and compliance in

Re: [PATCH] virtiofsd: Fix side-effect in assert()

2021-04-09 Thread Philippe Mathieu-Daudé
Hi Stefan, On 4/9/21 5:11 PM, Stefan Weil wrote: > Am 09.04.21 um 12:06 schrieb Greg Kurz: > >> It is bad practice to put an expression with a side-effect in >> assert() because the side-effect won't happen if the code is >> compiled with -DNDEBUG. >> >> Use an intermediate variable. Consolidate

Re: [PATCH for-6.0 0/2] mps3-an524: Fix MPC setting for SRAM block

2021-04-09 Thread Richard Henderson
On 4/9/21 8:05 AM, Peter Maydell wrote: Peter Maydell (2): hw/arm/mps2-tz: Fix MPC setting for AN524 SRAM block hw/arm/mps2-tz: Assert if more than one RAM is attached to an MPC Reviewed-by: Richard Henderson r~

Re: [PATCH] virtiofsd: Fix side-effect in assert()

2021-04-09 Thread Stefan Weil
Am 09.04.21 um 12:06 schrieb Greg Kurz: It is bad practice to put an expression with a side-effect in assert() because the side-effect won't happen if the code is compiled with -DNDEBUG. Use an intermediate variable. Consolidate this in an macro to have proper line numbers when the assertion

[Bug 1893040] Re: External modules retreval using Go1.15 on s390x appears to have checksum and ECDSA verification issues

2021-04-09 Thread Alex Bennée
** Tags added: s390x ** Tags added: tcg -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1893040 Title: External modules retreval using Go1.15 on s390x appears to have checksum and ECDSA

Re: [PATCH] checkpatch: Fix use of uninitialized value

2021-04-09 Thread Alex Bennée
Greg Kurz writes: > checkfilename() doesn't always set $acpi_testexpected. Fix the following > warning: > > Use of uninitialized value $acpi_testexpected in string eq at > ./scripts/checkpatch.pl line 1529. > > Fixes: d2f1af0e4120 ("checkpatch: don't emit warning on newly created acpi > data

[PATCH for-6.0 1/2] hw/arm/mps2-tz: Fix MPC setting for AN524 SRAM block

2021-04-09 Thread Peter Maydell
The AN524 has three MPCs: one for the BRAM, one for the QSPI flash, and one for the DDR. We incorrectly set the .mpc field in the RAMInfo struct for the SRAM block to 1, giving it the same MPC we are using for the QSPI. The effect of this was that the QSPI didn't get mapped into the system

[PATCH for-6.0 2/2] hw/arm/mps2-tz: Assert if more than one RAM is attached to an MPC

2021-04-09 Thread Peter Maydell
Each board in mps2-tz.c specifies a RAMInfo[] array providing information about each RAM in the board. The .mpc field of the RAMInfo struct specifies which MPC, if any, the RAM is attached to. We already assert if the array doesn't have any entry for an MPC, but we don't diagnose the error of

[PATCH for-6.0 0/2] mps3-an524: Fix MPC setting for SRAM block

2021-04-09 Thread Peter Maydell
The AN524 FPGA image has three MPCs: one for the BRAM, one for the QSPI flash, and one for the DDR. In the an524_raminfo[] array that defines the various RAM blocks on the board, we incorrectly set the .mpc field for the SRAM to 1 as well as for the QSPI flash. The effect of this was to cause the

  1   2   3   >