Re: [PATCH v3 1/6] block: add bitmap-populate job

2020-06-23 Thread Vladimir Sementsov-Ogievskiy
23.06.2020 00:44, Eric Blake wrote: On 6/19/20 11:16 PM, Vladimir Sementsov-Ogievskiy wrote: 19.06.2020 22:56, Eric Blake wrote: From: John Snow This job copies the allocation map into a bitmap. It's a job because there's no guarantee that allocation interrogation will be quick (or won't hang

Re: [PATCH v3 00/14] mps2: Add few more peripherals

2020-06-23 Thread Philippe Mathieu-Daudé
On 6/22/20 7:08 PM, Peter Maydell wrote: > On Wed, 17 Jun 2020 at 08:25, Philippe Mathieu-Daudé wrote: >> >> Few patches while playing with Zephyr on the MPS2: >> >> - clean 'versatile_i2c' a bit, >> - describe it as 'ARM SBCon two-wire serial bus interface' >> which is common on the ARM documen

Re: [PATCH v1 00/10] vDPA support in qemu

2020-06-23 Thread Markus Armbruster
Cindy Lu writes: > vDPA device is a device that uses a datapath which complies with the > virtio specifications with vendor specific control path. vDPA devices > can be both physically located on the hardware or emulated by software. > This RFC introduce the vDPA support in qemu > TODO > 1) vIOM

Re: [PATCH v1 01/10] net: introduce qemu_get_peer

2020-06-23 Thread Jason Wang
On 2020/6/22 下午11:37, Cindy Lu wrote: This is a small function that can get the peer from given NetClientState and queue_index Signed-off-by: Cindy Lu --- include/net/net.h | 1 + net/net.c | 6 ++ 2 files changed, 7 insertions(+) diff --git a/include/net/net.h b/include/net/

Re: [PATCH v1 10/10] vhost-vdpa: introduce vhost-vdpa net client

2020-06-23 Thread Markus Armbruster
QAPI schema review only. Cindy Lu writes: > This patch set introduces a new net client type: vhost-vdpa. > vhost-vdpa net client will set up a vDPA device which is specified > by a "vhostdev" parameter. > > Signed-off-by: Lingshan Zhu > Signed-off-by: Tiwei Bie > Signed-off-by: Cindy Lu [...]

Re: [PATCH v1 04/10] virtio-pci: implement queue_enabled method

2020-06-23 Thread Jason Wang
On 2020/6/22 下午11:37, Cindy Lu wrote: From: Jason Wang With version 1, we can detect whether a queue is enabled via queue_enabled. Signed-off-by: Jason Wang Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 18 ++ 1 file changed, 18 insertions(+) diff --git a/hw/virt

Re: [PATCH v1 06/10] vhsot_net: introduce set_config & get_config function

2020-06-23 Thread Jason Wang
On 2020/6/22 下午11:37, Cindy Lu wrote: This patch introduces set_config & get_config method which allows One space is sufficient between get_config and method. vhost_net set/get the config to backend Typo in the subject. Signed-off-by: Cindy Lu --- hw/net/vhost_net.c | 11 +

Re: [PATCH] nbd: Avoid off-by-one in long export name truncation

2020-06-23 Thread Vladimir Sementsov-Ogievskiy
23.06.2020 00:03, Eric Blake wrote: When snprintf returns the same value as the buffer size, the final byte was truncated to ensure a NUL terminator. Fortunately, such long export names are unusual enough, with no real impact other than what is displayed to the user. Fixes: 5c86bdf12089 Oh, I

Re: [PATCH QEMU v25 17/17] qapi: Add VFIO devices migration stats in Migration stats

2020-06-23 Thread Markus Armbruster
QAPI review only. The only changes since I reviewed v23 is the rename of VfioStats member @bytes to @transferred, and the move of MigrationInfo member @vfio next to @ram and @disk. Good. I'm copying my other questions in the hope of getting answers :) Kirti Wankhede writes: > Added amount of

[PATCH v2 1/3] hw/arm/aspeed: Remove extraneous MemoryRegion object owner

2020-06-23 Thread Philippe Mathieu-Daudé
I'm confused by this code, 'bmc' is created as: bmc = g_new0(AspeedBoardState, 1); Then we use it as QOM owner for different MemoryRegion objects. But looking at memory_region_init_ram (similarly for ROM): void memory_region_init_ram(MemoryRegion *mr, struct Obj

[PATCH v2 0/3] hw/arm/aspeed: Improve QOM usage

2020-06-23 Thread Philippe Mathieu-Daudé
Yet another cleanup. Simplify aspeed machine QOM usage. Since v1, addressed Cédric review comments: - Rename AspeedBoardState -> AspeedMachineState Philippe Mathieu-Daudé (3): hw/arm/aspeed: Remove extraneous MemoryRegion object owner hw/arm/aspeed: Rename AspeedBoardState as AspeedMachineSta

[PATCH v2 2/3] hw/arm/aspeed: Rename AspeedBoardState as AspeedMachineState

2020-06-23 Thread Philippe Mathieu-Daudé
To have a more consistent naming, rename AspeedBoardState as AspeedMachineState. Suggested-by: Cédric Le Goater Signed-off-by: Philippe Mathieu-Daudé --- include/hw/arm/aspeed.h | 4 ++-- hw/arm/aspeed.c | 20 ++-- 2 files changed, 12 insertions(+), 12 deletions(-) dif

[PATCH v2 3/3] hw/arm/aspeed: QOM'ify AspeedMachineState

2020-06-23 Thread Philippe Mathieu-Daudé
AspeedMachineState seems crippled. We use incorrectly 2 different structures to do the same thing. Merge them altogether: - Move AspeedMachine fields to AspeedMachineState - AspeedMachineState is now QOM - Remove unused AspeedMachine structure Signed-off-by: Philippe Mathieu-Daudé --- include/hw

Re: [PATCH v1 08/10] vhost: implement vhost_dev_start method

2020-06-23 Thread Jason Wang
On 2020/6/22 下午11:37, Cindy Lu wrote: use the vhost_dev_start callback to send the status to backend I suggest to squash this into previous patch. Signed-off-by: Cindy Lu --- hw/virtio/vhost.c | 17 + include/hw/virtio/vhost.h | 2 ++ 2 files changed, 19 ins

Re: [PATCH v4 1/8] hw/i2c/core: Add i2c_try_create_slave() and i2c_realize_and_unref()

2020-06-23 Thread Markus Armbruster
Philippe Mathieu-Daudé writes: > On 6/22/20 5:17 PM, Markus Armbruster wrote: >> >> No objections, except I want to see actual users. > > You weren't Cc'ed on the whole series. > > User is patch #6/8 "hw/arm/aspeed: Describe each PCA9552 device": > https://www.mail-archive.com/qemu-devel@nongnu.

[PATCH v6 1/9] hw/i2c/core: Add i2c_try_create_slave() and i2c_realize_and_unref()

2020-06-23 Thread Philippe Mathieu-Daudé
Extract i2c_try_create_slave() and i2c_realize_and_unref() from i2c_create_slave(). We can now set properties on a I2CSlave before it is realized. This is in line with the recent qdev/QOM changes merged in commit 6675a653d2e. Reviewed-by: Corey Minyard Reviewed-by: Cédric Le Goater Signed-off-b

[PATCH v6 0/9] hw/misc/pca9552: Trace GPIO change events

2020-06-23 Thread Philippe Mathieu-Daudé
This series add trace events to better display GPIO changes. We'll continue in the following series by connecting LEDs to these GPIOs. This helps me to work on a generic LED device, see: https://www.mail-archive.com/qemu-devel@nongnu.org/msg711917.html Since v5, addressed Cédric review comment: -

[PATCH v6 4/9] hw/misc/pca9552: Add generic PCA955xClass, parent of TYPE_PCA9552

2020-06-23 Thread Philippe Mathieu-Daudé
Extract the code common to the PCA955x family in PCA955xClass, keeping the PCA9552 specific parts into pca9552_class_init(). Remove the 'TODO' comment added in commit 5141d4158cf. Suggested-by: Cédric Le Goater Reviewed-by: Cédric Le Goater Signed-off-by: Philippe Mathieu-Daudé --- include/hw/

[PATCH v6 9/9] hw/misc/pca9552: Model qdev output GPIOs

2020-06-23 Thread Philippe Mathieu-Daudé
The PCA9552 has 16 GPIOs which can be used as input, output or PWM mode. QEMU models the output GPIO with the qemu_irq type. Let the device expose the 16 GPIOs to allow us to later connect LEDs to these outputs. Reviewed-by: Cédric Le Goater Signed-off-by: Philippe Mathieu-Daudé --- include/hw/

[PATCH v6 8/9] hw/misc/pca9552: Trace GPIO change events

2020-06-23 Thread Philippe Mathieu-Daudé
Emit a trace event when a GPIO change its state. Example booting obmc-phosphor-image: $ qemu-system-arm -M witherspoon-bmc -trace pca955x_gpio_change 1592690552.687372:pca955x_gpio_change pca1 GPIO id:0 status: 0 -> 1 1592690552.690169:pca955x_gpio_change pca1 GPIO id:1 status: 0 -> 1 159

[PATCH v6 2/9] hw/misc/pca9552: Rename 'nr_leds' as 'pin_count'

2020-06-23 Thread Philippe Mathieu-Daudé
The PCA9552 device does not expose LEDs, but simple pins to connnect LEDs to. To be clearer with the device model, rename 'nr_leds' as 'pin_count'. Reviewed-by: Cédric Le Goater Signed-off-by: Philippe Mathieu-Daudé --- include/hw/misc/pca9552.h | 2 +- hw/misc/pca9552.c | 10 +

[PATCH v6 3/9] hw/misc/pca9552: Rename generic code as pca955x

2020-06-23 Thread Philippe Mathieu-Daudé
Various code from the PCA9552 device model is generic to the PCA955X family. We'll split the generic code in a base class in the next commit. To ease review, first do a dumb renaming. Reviewed-by: Cédric Le Goater Signed-off-by: Philippe Mathieu-Daudé --- include/hw/misc/pca9552.h | 10 ++--- h

Re: [PATCH 1/2] qcow2: Force preallocation with data-file-raw

2020-06-23 Thread Max Reitz
On 22.06.20 19:36, Alberto Garcia wrote: [...] > You would still have problems with images created with raw data files > but without preallocation. Yeah, sure, but, well. Bug in qemu. :/ Max signature.asc Description: OpenPGP digital signature

[PATCH v6 5/9] hw/misc/pca9552: Add a 'description' property for debugging purpose

2020-06-23 Thread Philippe Mathieu-Daudé
Add a description field to distinguish between multiple devices. Reviewed-by: Cédric Le Goater Signed-off-by: Philippe Mathieu-Daudé --- include/hw/misc/pca9552.h | 1 + hw/misc/pca9552.c | 18 ++ 2 files changed, 19 insertions(+) diff --git a/include/hw/misc/pca9552.h

Re: [PATCH v1 09/10] vhost-vdpa: introduce vhost-vdpa backend

2020-06-23 Thread Jason Wang
On 2020/6/22 下午11:37, Cindy Lu wrote: Currently we have 2 types of vhost backends in QEMU: vhost kernel and vhost-user. The above patch provides a generic device for vDPA purpose, this vDPA device exposes to user space a non-vendor-specific configuration interface for setting up a vhost HW acce

[PATCH v6 6/9] hw/misc/pca9552: Trace GPIO High/Low events

2020-06-23 Thread Philippe Mathieu-Daudé
Add a trivial representation of the PCA9552 GPIOs. Example booting obmc-phosphor-image: $ qemu-system-arm -M witherspoon-bmc -trace pca955x_gpio_status 1592689902.327837:pca955x_gpio_status pca-unspecified GPIOs 0-15 [*...] 1592689902.329934:pca955x_gpio_status pca-unspecified

[PATCH v6 7/9] hw/arm/aspeed: Describe each PCA9552 device

2020-06-23 Thread Philippe Mathieu-Daudé
We have 2 distinct PCA9552 devices. Set their description to distinguish them when looking at the trace events. Description name taken from: https://github.com/open-power/witherspoon-xml/blob/master/witherspoon.xml Reviewed-by: Cédric Le Goater Signed-off-by: Philippe Mathieu-Daudé --- Cc: Mark

Re: [PATCH 0/2] qcow2: Force preallocation with data-file-raw

2020-06-23 Thread Max Reitz
On 22.06.20 19:44, Alberto Garcia wrote: > On Mon 22 Jun 2020 11:47:32 AM CEST, Max Reitz wrote: >>> I don't know the internals of qcow2 data_file, but are we really using >>> qcow2 metadata when accessing the data file? >> >> Yes. >> >>> This may have unwanted performance consequences. >> >> I don

Re: [PATCH v4] target/i386: Add notes for versioned CPU models

2020-06-23 Thread Paolo Bonzini
On 21/05/20 08:37, Tao Xu wrote: > Hi Eduardo > > Could you review this patch? > > Tao Xu > > On 3/24/2020 1:10 PM, Xu, Tao3 wrote: >> Add which features are added or removed in this version. >> >> Signed-off-by: Tao Xu >> --- >> >> The output is as follows: >> qemu-system-x86_64 -cpu help | gr

[Bug 1884719] [NEW] Function not implemented when using libaio

2020-06-23 Thread Martin Grigorov
Public bug reported: Hello I experience "Function not implemented" errors when trying to use Linux libaio library in foreign architecture, e.g. aarch64. I've faced this problem while using https://github.com/multiarch/qemu-user-static, i.e. Docker+QEMU. I understand that I do not use plain QEM

Re: [PATCH v3 3/7] hw/misc/led: Emit a trace event when LED intensity has changed

2020-06-23 Thread Philippe Mathieu-Daudé
On 6/22/20 6:48 PM, Richard Henderson wrote: > On 6/21/20 3:25 PM, Philippe Mathieu-Daudé wrote: >> Anyway I switched to a percent value. What is better to hold >> it, an 'unsigned' or 'uint8_t' type? > > Might as well use unsigned; you'll not be saving space with uint8_t. Bah if we want to migra

Re: [PATCH QEMU v25 04/17] vfio: Add migration region initialization and finalize function

2020-06-23 Thread Cornelia Huck
On Sun, 21 Jun 2020 01:51:13 +0530 Kirti Wankhede wrote: > Whether the VFIO device supports migration or not is decided based of > migration region query. If migration region query is successful and migration > region initialization is successful then migration is supported else > migration is bl

Re: [PATCH v9 04/10] configure: Generate rule to calculate the base architecture of a target

2020-06-23 Thread Claudio Fontana
Hi Philippe, Alex, On 6/18/20 2:33 PM, Philippe Mathieu-Daudé wrote: > From: Alex Bennée > > As we encode the base architecture in configure.sh, we can emit > the base-arch() function into config-host.mak. > > Signed-off-by: Alex Bennée > Signed-off-by: Philippe Mathieu-Daudé I found this ch

Re: [PATCH v5 1/9] hw/i2c/core: Add i2c_try_create_slave() and i2c_realize_and_unref()

2020-06-23 Thread Markus Armbruster
Philippe Mathieu-Daudé writes: > Extract i2c_try_create_slave() and i2c_realize_and_unref() > from i2c_create_slave(). > We can now set properties on a I2CSlave before it is realized. > > This is in line with the recent qdev/QOM changes merged > in commit 6675a653d2e. > > Signed-off-by: Philippe

Re: [PATCH] fuzz: do not use POSIX shm for coverage bitmap

2020-06-23 Thread Darren Kenny
Hi Alex, On Monday, 2020-06-22 at 12:50:40 -04, Alexander Bulekov wrote: > We used shm_open with mmap to share libfuzzer's coverage bitmap with > child (runner) processes. The same functionality can be achieved with > MAP_SHARED | MAP_ANONYMOUS, since we do not care about naming or > permissioning

Re: [PATCH QEMU v25 05/17] vfio: Add VM state change handler to know state of VM

2020-06-23 Thread Cornelia Huck
On Sun, 21 Jun 2020 01:51:14 +0530 Kirti Wankhede wrote: > VM state change handler gets called on change in VM's state. This is used to > set > VFIO device state to _RUNNING. > > Signed-off-by: Kirti Wankhede > Reviewed-by: Neo Jia > Reviewed-by: Dr. David Alan Gilbert > --- > hw/vfio/migra

Re: [PATCH QEMU v25 06/17] vfio: Add migration state change notifier

2020-06-23 Thread Cornelia Huck
On Sun, 21 Jun 2020 01:51:15 +0530 Kirti Wankhede wrote: > Added migration state change notifier to get notification on migration state > change. These states are translated to VFIO device state and conveyed to > vendor > driver. > > Signed-off-by: Kirti Wankhede > Reviewed-by: Neo Jia > Revi

Re: [PATCH v2 2/3] hw/arm/aspeed: Rename AspeedBoardState as AspeedMachineState

2020-06-23 Thread Cédric Le Goater
On 6/23/20 9:21 AM, Philippe Mathieu-Daudé wrote: > To have a more consistent naming, rename AspeedBoardState > as AspeedMachineState. > > Suggested-by: Cédric Le Goater > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Cédric Le Goater > --- > include/hw/arm/aspeed.h | 4 ++-- > hw/arm/

Re: [PATCH v2 3/3] hw/arm/aspeed: QOM'ify AspeedMachineState

2020-06-23 Thread Cédric Le Goater
On 6/23/20 9:21 AM, Philippe Mathieu-Daudé wrote: > AspeedMachineState seems crippled. We use incorrectly 2 > different structures to do the same thing. Merge them > altogether: > - Move AspeedMachine fields to AspeedMachineState > - AspeedMachineState is now QOM > - Remove unused AspeedMachine str

Re: [PATCH v6 0/9] hw/misc/pca9552: Trace GPIO change events

2020-06-23 Thread Cédric Le Goater
On 6/23/20 9:27 AM, Philippe Mathieu-Daudé wrote: > This series add trace events to better display GPIO changes. > We'll continue in the following series by connecting LEDs to > these GPIOs. > > This helps me to work on a generic LED device, see: > https://www.mail-archive.com/qemu-devel@nongnu.or

Re: [PATCH 4/5] linux-user: Support CLONE_VM and extended clone options

2020-06-23 Thread Alex Bennée
Josh Kunz writes: > Thanks for the responses Alex. I'm working on your comments, but > wanted to clarify some of the points you brought up before mailing a > second version. Responses inline. > > On Tue, Jun 16, 2020 at 9:08 AM Alex Bennée wrote: >> Which by the way fail on some targets: >> >>

Re: [PATCH v3 1/5] qdev: Introduce DEFINE_PROP_RESERVED_REGION

2020-06-23 Thread Auger Eric
Hi Markus, On 6/22/20 1:22 PM, Markus Armbruster wrote: > Eric Auger writes: > >> Introduce a new property defining a reserved region: >> , , . >> >> This will be used to encode reserved IOVA regions. >> >> For instance, in virtio-iommu use case, reserved IOVA regions >> will be passed by the ma

[PATCH v2] tests/qtest/arm-cpu-features: Add feature setting tests

2020-06-23 Thread Andrew Jones
Some cpu features may be enabled and disabled for all configurations that support the feature. Let's test that. A recent regression[*] inspired adding these tests. [*] '-cpu host,pmu=on' caused a segfault Based-on: "target/arm: Check supported KVM features globally (not per vCPU)" Signed-off-by:

Re: [PATCH 0/2] checkpatch: Do appropriate kernel->qemu renaming

2020-06-23 Thread Stefan Hajnoczi
On Sat, Jun 20, 2020 at 05:20:41PM +0200, Aleksandar Markovic wrote: > суб, 20. јун 2020. у 17:09 Aleksandar Markovic > је написао/ла: > > > > суб, 20. јун 2020. у 16:25 Peter Maydell је > > написао/ла: > > > > > > On Sat, 20 Jun 2020 at 14:33, Aleksandar Markovic > > > wrote: > > > > There are

Re: [PATCH v3 00/25] risu cleanups and improvements

2020-06-23 Thread Alex Bennée
Peter Maydell writes: > Just a note that I'm assuming this is still on Alex's plate to review. > Ping me if it gets reviews and is ready to apply. Thanks for the reminder - it had dropped off my radar. I'll have a quick scan through now. -- Alex Bennée

Re: [PATCH 0/2] checkpatch: Do appropriate kernel->qemu renaming

2020-06-23 Thread Michael S. Tsirkin
On Sat, Jun 20, 2020 at 03:32:05PM +0200, Aleksandar Markovic wrote: > There are several places where 'kernel' is mentioned instead of > 'qemu' in checkpatch.pl. > > This small series corrects this. fine by me Acked-by: Michael S. Tsirkin > Aleksandar Markovic (2): > checkpatch: Rename top_

Re: [PATCH QEMU v25 15/17] vfio: Add ioctl to get dirty pages bitmap during dma unmap.

2020-06-23 Thread Cornelia Huck
On Sun, 21 Jun 2020 01:51:24 +0530 Kirti Wankhede wrote: > With vIOMMU, IO virtual address range can get unmapped while in pre-copy > phase of migration. In that case, unmap ioctl should return pages pinned > in that range and QEMU should find its correcponding guest physical > addresses and repo

Re: [PATCH v3 14/25] Merge reginfo.c into risu.c

2020-06-23 Thread Alex Bennée
Richard Henderson writes: > The distinction between the two is artificial. Following > patches will rearrange the functions involved to make it > easier for dumping of the trace file. > > Signed-off-by: Richard Henderson Reviewed-by: Alex Bennée -- Alex Bennée

RE: [PATCH 08/22] qga: Plug unlikely memory leak in guest-set-memory-blocks

2020-06-23 Thread Zhanghailiang
Reviewed-by: zhanghailiang > -Original Message- > From: Markus Armbruster [mailto:arm...@redhat.com] > Sent: Monday, June 22, 2020 6:43 PM > To: qemu-devel@nongnu.org > Cc: Michael Roth ; Zhanghailiang > > Subject: [PATCH 08/22] qga: Plug unlikely memory leak in > guest-set-memory-blocks

Re: sysbus failed assert for xen_sysdev

2020-06-23 Thread Markus Armbruster
Jason Andryuk writes: > On Mon, Jun 22, 2020 at 5:17 PM Mark Cave-Ayland > wrote: >> >> On 22/06/2020 21:33, Jason Andryuk wrote: >> >> > Hi, >> > >> > Running qemu devel for a Xen VM is failing an assert after the recent >> > "qdev: Rework how we plug into the parent bus" sysbus changes. >> > >

Re: [PATCH v5 7/9] hw/arm/aspeed: Describe each PCA9552 device

2020-06-23 Thread Markus Armbruster
Philippe Mathieu-Daudé writes: > We have 2 distinct PCA9552 devices. Set their description > to distinguish them when looking at the trace events. > > Description name taken from: > https://github.com/open-power/witherspoon-xml/blob/master/witherspoon.xml > > Signed-off-by: Philippe Mathieu-Daudé

Re: [PATCH] fuzz: do not use POSIX shm for coverage bitmap

2020-06-23 Thread Stefan Hajnoczi
On Mon, Jun 22, 2020 at 12:50:40PM -0400, Alexander Bulekov wrote: > We used shm_open with mmap to share libfuzzer's coverage bitmap with > child (runner) processes. The same functionality can be achieved with > MAP_SHARED | MAP_ANONYMOUS, since we do not care about naming or > permissioning the sh

Re: [PATCH v9 04/10] configure: Generate rule to calculate the base architecture of a target

2020-06-23 Thread Philippe Mathieu-Daudé
On 6/23/20 10:01 AM, Claudio Fontana wrote: > Hi Philippe, Alex, > > On 6/18/20 2:33 PM, Philippe Mathieu-Daudé wrote: >> From: Alex Bennée >> >> As we encode the base architecture in configure.sh, we can emit >> the base-arch() function into config-host.mak. >> >> Signed-off-by: Alex Bennée >>

Re: [PATCH RFC 01/22] arm/cpuhp: Add QMP vcpu params validation support

2020-06-23 Thread Andrew Jones
On Sat, Jun 13, 2020 at 10:36:08PM +0100, Salil Mehta wrote: > For now, vcpu hotplug is only supported with single socket single thread, > single die. NUMA is not supported either and everthing falls into single > node. Work to properly support these could be taken later once community > agrees wit

Re: [PULL 027/115] hw/i386/vmport: Propagate IOPort read to vCPU EAX register

2020-06-23 Thread Laurent Vivier
On 11/06/2020 21:43, Paolo Bonzini wrote: > From: Liran Alon > > vmport_ioport_read() returns the value that should propagate to vCPU EAX > register when guest reads VMPort IOPort (i.e. By x86 IN instruction). > > However, because vmport_ioport_read() calls cpu_synchronize_state(), the > returne

Re: [PATCH v3 15/25] Rearrange reginfo and memblock buffers

2020-06-23 Thread Alex Bennée
Richard Henderson writes: > For send_register_info from master_sigill, do not keep a > reginfo buffer on the stack. At the moment, this struct > is quite large for aarch64. > > Put the two reginfo buffers into an array, for the benefit > of future dumping. For recv_and_compare_register_info,

Re: [PATCH RFC 2/3] gitlab: build all container images during CI

2020-06-23 Thread Daniel P . Berrangé
On Mon, Jun 22, 2020 at 07:26:39PM +0100, Alex Bennée wrote: > > Daniel P. Berrangé writes: > > > We have a number of container images in tests/docker/dockerfiles > > that are intended to provide well defined environments for doing > > test builds. We want our CI system to use these containers t

Re: [PATCH v3 1/2] util: Introduce qemu_get_host_name()

2020-06-23 Thread Daniel P . Berrangé
On Mon, Jun 22, 2020 at 08:19:35PM +0200, Michal Privoznik wrote: > This function offers operating system agnostic way to fetch host > name. It is implemented for both POSIX-like and Windows systems. > > Signed-off-by: Michal Privoznik > --- > include/qemu/osdep.h | 10 ++ > util/oslib-p

Re: [PATCH v3 2/2] qga: Use qemu_get_host_name() instead of g_get_host_name()

2020-06-23 Thread Daniel P . Berrangé
On Mon, Jun 22, 2020 at 08:19:36PM +0200, Michal Privoznik wrote: > Problem with g_get_host_name() is that on the first call it saves > the hostname into a global variable and from then on, every > subsequent call returns the saved hostname. Even if the hostname > changes. This doesn't play nicely

[Bug 1884728] [NEW] facing build error for qemu-4.0.0 on SUSE11 OS

2020-06-23 Thread Harshit Monish
Public bug reported: I am trying to compile qemu-4.0.0 on suse11 OS and facing the following error on the console: ERROR: sizeof(size_t) doesn't match GLIB_SIZEOF_SIZE_T. You probably need to set PKG_CONFIG_LIBDIR to point to the right pkg-config files for your build target

Re: [PATCH v1 10/10] vhost-vdpa: introduce vhost-vdpa net client

2020-06-23 Thread Jason Wang
On 2020/6/22 下午11:37, Cindy Lu wrote: This patch set introduces a new net client type: vhost-vdpa. vhost-vdpa net client will set up a vDPA device which is specified by a "vhostdev" parameter. Signed-off-by: Lingshan Zhu Signed-off-by: Tiwei Bie Signed-off-by: Cindy Lu --- include/net/vho

Re: [PATCH v3 1/5] qdev: Introduce DEFINE_PROP_RESERVED_REGION

2020-06-23 Thread Markus Armbruster
Auger Eric writes: > Hi Markus, > > On 6/22/20 1:22 PM, Markus Armbruster wrote: >> Eric Auger writes: >> >>> Introduce a new property defining a reserved region: >>> , , . >>> >>> This will be used to encode reserved IOVA regions. >>> >>> For instance, in virtio-iommu use case, reserved IOVA r

Re: [PATCH v2] Stop vhost-user sending uninitialized mmap_offsets

2020-06-23 Thread Peter Maydell
On Tue, 23 Jun 2020 at 00:50, Raphael Norwitz wrote: > > Prior to this change, the vhost_user_fill_msg_region function filled out > all elements of the VhostUserMemoryRegion struct except the mmap_offset. > > This function is often called on uninitialized structs, which are then > copied into VHOS

Re: [PATCH v3 00/25] risu cleanups and improvements

2020-06-23 Thread Alex Bennée
Richard Henderson writes: > Version 3 changes the --dump option to --fulldump and --diffdump, > after an off-hand suggestion by Alex. > > These are now mode options, similar to --master. Which means that > dumping is an orthogonal apprentice type, which means that we can > dump from a socket.

Re: [PATCH RFC 07/22] arm/cpuhp: Init PMU at host for all possible vcpus

2020-06-23 Thread Andrew Jones
On Sat, Jun 13, 2020 at 10:36:14PM +0100, Salil Mehta wrote: > PMU for all possible vcpus must be initialized at the virt machine > initialization time. This patch refactors existing code to accomodate possible > vcpus. This also assumes that all processor being used are identical at least > for no

[PATCH v3 2/2] target/arm: Check supported KVM features globally (not per vCPU)

2020-06-23 Thread Philippe Mathieu-Daudé
Since commit d70c996df23f, when enabling the PMU we get: $ qemu-system-aarch64 -cpu host,pmu=on -M virt,accel=kvm,gic-version=3 Segmentation fault (core dumped) Thread 1 "qemu-system-aar" received signal SIGSEGV, Segmentation fault. 0xaae356d0 in kvm_ioctl (s=0x0, type=44547) at

[PATCH v3 0/2] target/arm: Fix using pmu=on on KVM

2020-06-23 Thread Philippe Mathieu-Daudé
Since v2: - include Drew test fix (addressed Peter review comments) - addressed Drew review comments - collected R-b/A-b Andrew Jones (1): tests/qtest/arm-cpu-features: Add feature setting tests Philippe Mathieu-Daudé (1): target/arm: Check supported KVM features globally (not per vCPU) tar

Re: [PATCH v2] Stop vhost-user sending uninitialized mmap_offsets

2020-06-23 Thread Michael S. Tsirkin
On Tue, Jun 23, 2020 at 09:58:23AM +0100, Peter Maydell wrote: > On Tue, 23 Jun 2020 at 00:50, Raphael Norwitz > wrote: > > > > Prior to this change, the vhost_user_fill_msg_region function filled out > > all elements of the VhostUserMemoryRegion struct except the mmap_offset. > > > > This functio

[PATCH v3 1/2] tests/qtest/arm-cpu-features: Add feature setting tests

2020-06-23 Thread Philippe Mathieu-Daudé
From: Andrew Jones Some cpu features may be enabled and disabled for all configurations that support the feature. Let's test that. A recent regression[*] inspired adding these tests. [*] '-cpu host,pmu=on' caused a segfault Signed-off-by: Andrew Jones Message-Id: <20200623082310.17577-1-drjo.

Re: [PULL v2 03/32] riscv: Generalize CPU init routine for the base CPU

2020-06-23 Thread Markus Armbruster
Bin Meng writes: > Hi Alistair, > > On Sat, Jun 20, 2020 at 1:09 AM Alistair Francis > wrote: >> >> From: Bin Meng >> >> There is no need to have two functions that have exactly the same >> codes for 32-bit and 64-bit base CPUs. >> >> Signed-off-by: Bin Meng >> Reviewed-by: Alistair Francis >

Re: [PATCH RFC 00/22] Support of Virtual CPU Hotplug for ARMv8 Arch

2020-06-23 Thread Andrew Jones
On Sat, Jun 13, 2020 at 10:36:07PM +0100, Salil Mehta wrote: > This patch-set introduces the virtual cpu hotplug support for ARMv8 > architecture in QEMU. Idea is to be able to hotplug and hot-unplug the vcpus > while guest VM is running and no reboot is required. This does *not* makes any > assump

[Bug 1884728] Re: facing build error for qemu-4.0.0 on SUSE11 OS

2020-06-23 Thread Peter Maydell
The part of the log you quote isn't the part which caused the failure. This bit is: funcs: do_compiler do_cc compile_prog main lines: 92 128 3672 0 /grid/avs/install/xcelium/1803/latest//tools/cdsgcc/gcc/bin/64bit/gcc -pthread -I/grid/common/pkgs/glib/v2.56.1/include/glib-2.0 -I/grid/common/pkg

Re: [PATCH v1 00/10] vDPA support in qemu

2020-06-23 Thread Cindy Lu
On Tue, Jun 23, 2020 at 3:07 PM Markus Armbruster wrote: > > Cindy Lu writes: > > > vDPA device is a device that uses a datapath which complies with the > > virtio specifications with vendor specific control path. vDPA devices > > can be both physically located on the hardware or emulated by soft

Re: [PATCH v1 01/10] net: introduce qemu_get_peer

2020-06-23 Thread Cindy Lu
On Tue, Jun 23, 2020 at 3:10 PM Jason Wang wrote: > > > On 2020/6/22 下午11:37, Cindy Lu wrote: > > This is a small function that can get the peer > > from given NetClientState and queue_index > > > > Signed-off-by: Cindy Lu > > --- > > include/net/net.h | 1 + > > net/net.c | 6 ++ >

Re: [PATCH v3 0/2] target/arm: Fix using pmu=on on KVM

2020-06-23 Thread Andrew Jones
On Tue, Jun 23, 2020 at 11:06:20AM +0200, Philippe Mathieu-Daudé wrote: > Since v2: > - include Drew test fix (addressed Peter review comments) > - addressed Drew review comments > - collected R-b/A-b > > Andrew Jones (1): > tests/qtest/arm-cpu-features: Add feature setting tests > > Philippe M

Re: [PATCH v1 04/10] virtio-pci: implement queue_enabled method

2020-06-23 Thread Cindy Lu
On Tue, Jun 23, 2020 at 3:13 PM Jason Wang wrote: > > > On 2020/6/22 下午11:37, Cindy Lu wrote: > > From: Jason Wang > > > > With version 1, we can detect whether a queue is enabled via > > queue_enabled. > > > > Signed-off-by: Jason Wang > > Signed-off-by: Cindy Lu > > --- > > hw/virtio/virtio

Re: [PATCH v1 10/10] vhost-vdpa: introduce vhost-vdpa net client

2020-06-23 Thread Cindy Lu
On Tue, Jun 23, 2020 at 3:13 PM Markus Armbruster wrote: > > QAPI schema review only. > > Cindy Lu writes: > > > This patch set introduces a new net client type: vhost-vdpa. > > vhost-vdpa net client will set up a vDPA device which is specified > > by a "vhostdev" parameter. > > > > Signed-off-by

Re: [PATCH v3 0/2] target/arm: Fix using pmu=on on KVM

2020-06-23 Thread Peter Maydell
On Tue, 23 Jun 2020 at 10:18, Andrew Jones wrote: > > On Tue, Jun 23, 2020 at 11:06:20AM +0200, Philippe Mathieu-Daudé wrote: > > Since v2: > > - include Drew test fix (addressed Peter review comments) > > - addressed Drew review comments > > - collected R-b/A-b > > > > Andrew Jones (1): > > tes

Re: [PATCH v1 06/10] vhsot_net: introduce set_config & get_config function

2020-06-23 Thread Cindy Lu
On Tue, Jun 23, 2020 at 3:18 PM Jason Wang wrote: > > > On 2020/6/22 下午11:37, Cindy Lu wrote: > > This patch introduces set_config & get_config method which allows > > > One space is sufficient between get_config and method. > > > > vhost_net set/get the config to backend > > > Typo in the subjec

Re: [PATCH v3 0/2] target/arm: Fix using pmu=on on KVM

2020-06-23 Thread Philippe Mathieu-Daudé
On 6/23/20 11:19 AM, Peter Maydell wrote: > On Tue, 23 Jun 2020 at 10:18, Andrew Jones wrote: >> >> On Tue, Jun 23, 2020 at 11:06:20AM +0200, Philippe Mathieu-Daudé wrote: >>> Since v2: >>> - include Drew test fix (addressed Peter review comments) >>> - addressed Drew review comments >>> - collect

Re: [PATCH v4] osdep: Make MIN/MAX evaluate arguments only once

2020-06-23 Thread Paolo Bonzini
On 04/06/20 23:52, Eric Blake wrote: > I'm not aware of any immediate bugs in qemu where a second runtime > evalution of the arguments to MIN() or MAX() causes a problem, but > proactively preventing such abuse is easier than falling prey to an > unintended case down the road. At any rate, here's

[PATCH v4 0/5] VIRTIO-IOMMU probe request support and MSI bypass on ARM

2020-06-23 Thread Eric Auger
By default the virtio-iommu translates MSI transactions. This behavior is inherited from ARM SMMU. However the virt machine code knows where the MSI doorbells are, so we can easily declare those regions as VIRTIO_IOMMU_RESV_MEM_T_MSI. With that setting the guest iommu subsystem will not need to map

[PATCH v4 4/5] virtio-iommu-pci: Add array of Interval properties

2020-06-23 Thread Eric Auger
The machine may need to pass reserved regions to the virtio-iommu-pci device (such as the MSI window on x86 or the MSI doorbells on ARM). So let's add an array of Interval properties. Note: if some reserved regions are already set by the machine code - which should be the case in general -, the l

Re: [PATCH v2] numa: forbid '-numa node,mem' for 5.1 and newer machine types

2020-06-23 Thread Paolo Bonzini
On 05/06/20 14:13, Igor Mammedov wrote: > Deprecation period is run out and it's a time to flip the switch > introduced by cd5ff8333a. Disable legacy option for new machine > types (since 5.1) and amend documentation. > > '-numa node,memdev' shall be used instead of disabled option > with new mac

[PATCH v4 1/5] qdev: Introduce DEFINE_PROP_RESERVED_REGION

2020-06-23 Thread Eric Auger
Introduce a new property defining a reserved region: ::. This will be used to encode reserved IOVA regions. For instance, in virtio-iommu use case, reserved IOVA regions will be passed by the machine code to the virtio-iommu-pci device (an array of those). The type of the reserved region will mat

[PATCH v4 3/5] virtio-iommu: Handle reserved regions in the translation process

2020-06-23 Thread Eric Auger
When translating an address we need to check if it belongs to a reserved virtual address range. If it does, there are 2 cases: - it belongs to a RESERVED region: the guest should neither use this address in a MAP not instruct the end-point to DMA on them. We report an error - It belongs to an

Re: [PATCH v3] numa: forbid '-numa node,mem' for 5.1 and newer machine types

2020-06-23 Thread Paolo Bonzini
On 05/06/20 18:03, Igor Mammedov wrote: > Deprecation period is run out and it's a time to flip the switch > introduced by cd5ff8333a. Disable legacy option for new machine > types (since 5.1) and amend documentation. > > '-numa node,memdev' shall be used instead of disabled option > with new mac

[PATCH v4 2/5] virtio-iommu: Implement RESV_MEM probe request

2020-06-23 Thread Eric Auger
This patch implements the PROBE request. At the moment, only THE RESV_MEM property is handled. The first goal is to report iommu wide reserved regions such as the MSI regions set by the machine code. On x86 this will be the IOAPIC MSI region, [0xFEE0 - 0xFEEF], on ARM this may be the ITS do

Re: [PULL 027/115] hw/i386/vmport: Propagate IOPort read to vCPU EAX register

2020-06-23 Thread Liran Alon
On 23/06/2020 11:46, Laurent Vivier wrote: On 11/06/2020 21:43, Paolo Bonzini wrote: From: Liran Alon vmport_ioport_read() returns the value that should propagate to vCPU EAX register when guest reads VMPort IOPort (i.e. By x86 IN instruction). However, because vmport_ioport_read() calls cp

[PATCH v4 5/5] hw/arm/virt: Let the virtio-iommu bypass MSIs

2020-06-23 Thread Eric Auger
At the moment the virtio-iommu translates MSI transactions. This behavior is inherited from ARM SMMU. The virt machine code knows where the guest MSI doorbells are so we can easily declare those regions as VIRTIO_IOMMU_RESV_MEM_T_MSI. With that setting the guest will not map MSIs through the IOMMU

Re: [PATCH RFC 2/3] gitlab: build all container images during CI

2020-06-23 Thread Alex Bennée
Daniel P. Berrangé writes: > On Mon, Jun 22, 2020 at 07:26:39PM +0100, Alex Bennée wrote: >> >> Daniel P. Berrangé writes: >> >> > We have a number of container images in tests/docker/dockerfiles >> > that are intended to provide well defined environments for doing >> > test builds. We want

Re: [PATCH v4] numa: forbid '-numa node,mem' for 5.1 and newer machine types

2020-06-23 Thread Paolo Bonzini
On 08/06/20 14:03, Igor Mammedov wrote: > Deprecation period is run out and it's a time to flip the switch > introduced by cd5ff8333a. Disable legacy option for new machine > types (since 5.1) and amend documentation. > > '-numa node,memdev' shall be used instead of disabled option > with new mac

Re: [PATCH v1 08/10] vhost: implement vhost_dev_start method

2020-06-23 Thread Cindy Lu
On Tue, Jun 23, 2020 at 3:21 PM Jason Wang wrote: > > > On 2020/6/22 下午11:37, Cindy Lu wrote: > > use the vhost_dev_start callback to send the status to backend > > > I suggest to squash this into previous patch. > Sure will do > > > > > Signed-off-by: Cindy Lu > > --- > > hw/virtio/vhost.c

Re: [PATCH v2 00/11] tpm: Split hw/ vs backends/

2020-06-23 Thread Paolo Bonzini
On 11/06/20 18:02, Philippe Mathieu-Daudé wrote: > Hi, > > Yesterday I started to review some vTPM patches and got very > confused by the files under hw/tpm/. In particular after > running: > > $ git grep TYPE_TPM_BACKEND > backends/tpm.c:188:.name = TYPE_TPM_BACKEND, > hw/tpm/tpm_emula

Re: [PATCH v1 08/10] vhost: implement vhost_dev_start method

2020-06-23 Thread Jason Wang
On 2020/6/23 下午5:34, Cindy Lu wrote: On Tue, Jun 23, 2020 at 3:21 PM Jason Wang wrote: On 2020/6/22 下午11:37, Cindy Lu wrote: use the vhost_dev_start callback to send the status to backend I suggest to squash this into previous patch. Sure will do Signed-off-by: Cindy Lu --- hw/virtio/

Re: [PATCH v1 08/10] vhost: implement vhost_dev_start method

2020-06-23 Thread Cindy Lu
On Tue, Jun 23, 2020 at 5:38 PM Jason Wang wrote: > > > On 2020/6/23 下午5:34, Cindy Lu wrote: > > On Tue, Jun 23, 2020 at 3:21 PM Jason Wang wrote: > >> On 2020/6/22 下午11:37, Cindy Lu wrote: > >>> use the vhost_dev_start callback to send the status to backend > >> I suggest to squash this into pre

Re: [PATCH v3 00/12] tpm: Split hw/ vs backends/

2020-06-23 Thread Paolo Bonzini
On 12/06/20 10:54, Philippe Mathieu-Daudé wrote: > Missing review: last patch > - #12 "tpm: Move backend code under the 'backends/' directory" > > Hi, > > Yesterday I started to review some vTPM patches and got very > confused by the files under hw/tpm/. In particular after > running: > > $ gi

RE: [PATCH RFC 01/22] arm/cpuhp: Add QMP vcpu params validation support

2020-06-23 Thread Salil Mehta
Hi Andrew, > From: Andrew Jones [mailto:drjo...@redhat.com] > Sent: Tuesday, June 23, 2020 9:46 AM > To: Salil Mehta > Cc: qemu-devel@nongnu.org; qemu-...@nongnu.org; peter.mayd...@linaro.org; > sudeep.ho...@arm.com; gs...@redhat.com; m...@redhat.com; jiakern...@gmail.com; > m...@kernel.org; zhuk

Re: [PATCH v1 09/10] vhost-vdpa: introduce vhost-vdpa backend

2020-06-23 Thread Cindy Lu
On Tue, Jun 23, 2020 at 3:31 PM Jason Wang wrote: > > > On 2020/6/22 下午11:37, Cindy Lu wrote: > > Currently we have 2 types of vhost backends in QEMU: vhost kernel and > > vhost-user. The above patch provides a generic device for vDPA purpose, > > this vDPA device exposes to user space a non-vendo

Re: [PATCH v1 00/10] vDPA support in qemu

2020-06-23 Thread Jason Wang
On 2020/6/23 下午5:16, Cindy Lu wrote: On Tue, Jun 23, 2020 at 3:07 PM Markus Armbruster wrote: Cindy Lu writes: vDPA device is a device that uses a datapath which complies with the virtio specifications with vendor specific control path. vDPA devices can be both physically located on the ha

  1   2   3   4   5   6   >