Re: [PATCH v2 3/3] virtiofsd: probe unshare(CLONE_FS) and print an error

2020-07-29 Thread Stefan Hajnoczi
On Wed, Jul 29, 2020 at 09:59:01AM +0200, Roman Mohr wrote: > On Tue, Jul 28, 2020 at 3:13 PM Vivek Goyal wrote: > > > On Tue, Jul 28, 2020 at 12:00:20PM +0200, Roman Mohr wrote: > > > On Tue, Jul 28, 2020 at 3:07 AM misono.tomoh...@fujitsu.com < > > > misono.tomoh...@fujitsu.com> wrote: > > > >

Re: [PATCH 3/3] hw/arm/virt: Implement kvm-steal-time

2020-07-29 Thread Andrew Jones
On Tue, Jul 21, 2020 at 11:46:12AM +0100, Peter Maydell wrote: > > +if (!probed) { > > +probed = true; > > +if (kvm_check_extension(kvm_state, KVM_CAP_VCPU_ATTRIBUTES)) { > > +if (!kvm_arm_create_scratch_host_vcpu(NULL, fdarray, NULL)) { > > +error_re

Re: [PATCH for 5.1] docs: fix trace docs build with sphinx 3.1.1

2020-07-29 Thread Stefan Hajnoczi
On Wed, Jul 29, 2020 at 12:34:15PM +0100, Daniel P. Berrangé wrote: > On Wed, Jul 29, 2020 at 11:37:19AM +0100, Stefan Hajnoczi wrote: > > On Tue, Jul 14, 2020 at 05:26:59PM +0100, Daniel P. Berrangé wrote: > > > In Fedora 33 rawhide, we now have sphinx 3.1.1, as opposed > > > to previous 2.2.2. Th

Re: [PULL 0/4] target-hppa fixes

2020-07-29 Thread Peter Maydell
On Tue, 28 Jul 2020 at 20:35, Helge Deller wrote: > > Please pull to fix those two bugs in target-hppa: > > * Fix the SeaBIOS-hppa firmware build with gcc-10 on Debian > > * Fix the following runtime warning with artist framebuffer: > "write outside bounds: wants 1256x1023, max size 1280x1024" >

Re: [PATCH] hw/net/ftgmac100: Fix integer overflow in ftgmac100_do_tx()

2020-07-29 Thread Cédric Le Goater
Sorry for the late answer. On 7/13/20 6:15 PM, Peter Maydell wrote: > On Mon, 13 Jul 2020 at 15:19, Cédric Le Goater wrote: >> On 7/10/20 1:33 PM, Peter Maydell wrote: >>> Andrew, Cedric: do you have the datasheet for this device? Do you >>> know if we should also be flagging the error back to th

Re: [PATCH 02/16] hw/block/nvme: add mapping helpers

2020-07-29 Thread Minwoo Im
Hi Klaus, On 20-07-20 13:37:34, Klaus Jensen wrote: > From: Klaus Jensen > > Add nvme_map_addr, nvme_map_addr_cmb and nvme_addr_to_cmb helpers and > use them in nvme_map_prp. > > This fixes a bug where in the case of a CMB transfer, the device would > map to the buffer with a wrong length. > >

Re: [PATCH 03/16] hw/block/nvme: replace dma_acct with blk_acct equivalent

2020-07-29 Thread Minwoo Im
Klaus, On 20-07-20 13:37:35, Klaus Jensen wrote: > From: Klaus Jensen > > The QSG isn't always initialized, so accounting could be wrong. Issue a > call to blk_acct_start instead with the size taken from the QSG or IOV > depending on the kind of I/O. > > Signed-off-by: Klaus Jensen > Reviewed-

Re: [PATCH 04/16] hw/block/nvme: remove redundant has_sg member

2020-07-29 Thread Minwoo Im
Klaus, On 20-07-20 13:37:36, Klaus Jensen wrote: > From: Klaus Jensen > > Remove the has_sg member from NvmeRequest since it's redundant. > > Also, make sure the request iov is destroyed at completion time. > > Signed-off-by: Klaus Jensen > Reviewed-by: Maxim Levitsky > --- > hw/block/nvme.

Re: [PATCH 05/16] hw/block/nvme: refactor dma read/write

2020-07-29 Thread Minwoo Im
Klaus, On 20-07-20 13:37:37, Klaus Jensen wrote: > From: Klaus Jensen > > Refactor the nvme_dma_{read,write}_prp functions into a common function > taking a DMADirection parameter. > > Signed-off-by: Klaus Jensen > Reviewed-by: Maxim Levitsky Reviewed-by: Minwoo Im Thanks,

[PATCH for-5.1] tracetool: carefully define SDT_USE_VARIADIC

2020-07-29 Thread Stefan Hajnoczi
The dtrace backend defines SDT_USE_VARIADIC as a workaround for a conflict with a LTTng UST header file, which requires SDT_USE_VARIADIC to be defined. LTTng UST breaks if included after generated dtrace headers because SDT_USE_VARIADIC will already be defined: #ifdef LTTNG_UST_HAVE_SDT_INTEGR

Re: [PATCH v8 1/7] tests/virtio-9p: added split readdir tests

2020-07-29 Thread Greg Kurz
On Wed, 29 Jul 2020 10:10:23 +0200 Christian Schoenebeck wrote: > The previous, already existing 'basic' readdir test simply used a > 'count' parameter big enough to retrieve all directory entries with a > single Treaddir request. > > In the 3 new 'split' readdir tests added by this patch, direc

Re: [PATCH v8 2/7] 9pfs: make v9fs_readdir_response_size() public

2020-07-29 Thread Greg Kurz
On Wed, 29 Jul 2020 10:11:15 +0200 Christian Schoenebeck wrote: > Rename function v9fs_readdir_data_size() -> v9fs_readdir_response_size() > and make it callable from other units. So far this function is only > used by 9p.c, however subsequent patches require the function to be > callable from an

Re: [PATCH 1/4] linux-user: Add support for a group of btrfs ioctls used for subvolumes

2020-07-29 Thread Laurent Vivier
Le 09/07/2020 à 17:52, Filip Bozuta a écrit : > This patch implements functionality of following ioctls: > > BTRFS_IOC_SUBVOL_CREATE - Creating a btrfs subvolume > > Create a btrfs subvolume. The subvolume is created using the ioctl's > third argument which represents a pointer to a follo

Re: [PATCH] linux-user: Correctly start brk after executable

2020-07-29 Thread Richard Henderson
On 7/28/20 3:46 PM, Timothy E Baldwin wrote: > info->brk was erroneously set to the end of highest addressed > writable segment which could result it in overlapping the executable. > > As per load_elf_binary in fs/binfmt_elf.c in Linux, it should be > set to end of highest addressed segment. > >

Re: [PATCH 06/16] hw/block/nvme: pass request along for tracing

2020-07-29 Thread Minwoo Im
Klaus, On 20-07-20 13:37:38, Klaus Jensen wrote: > From: Klaus Jensen > > Pass along the NvmeRequest in various functions since it is very useful > for tracing. One doubt here. This patch has put NvmeRequest argument to the nvme_map_prp() to trace the request's command id. But can we just

Re: [PULL 0/4] target-hppa fixes

2020-07-29 Thread Helge Deller
On 29.07.20 17:06, Peter Maydell wrote: > On Tue, 28 Jul 2020 at 20:35, Helge Deller wrote: >> >> Please pull to fix those two bugs in target-hppa: >> >> * Fix the SeaBIOS-hppa firmware build with gcc-10 on Debian >> >> * Fix the following runtime warning with artist framebuffer: >> "write outsi

Re: [PATCH 07/16] hw/block/nvme: add request mapping helper

2020-07-29 Thread Minwoo Im
Klaus, On 20-07-20 13:37:39, Klaus Jensen wrote: > From: Klaus Jensen > > Introduce the nvme_map helper to remove some noise in the main nvme_rw > function. > > Signed-off-by: Klaus Jensen > Reviewed-by: Maxim Levitsky > --- > hw/block/nvme.c | 13 ++--- > 1 file changed, 10 insertio

Re: [PATCH 2/4] linux-user: Add support for a group of btrfs ioctls used for snapshots

2020-07-29 Thread Laurent Vivier
Le 09/07/2020 à 17:52, Filip Bozuta a écrit : > This patch implements functionality for following ioctls: > > BTRFS_IOC_SNAP_CREATE - Creating a subvolume snapshot > > Create a snapshot of a btrfs subvolume. The snapshot is created using the > ioctl's third argument that is a pointer to a

Re: [PATCH v2 2/3] trace: Add support for recorder back-end

2020-07-29 Thread Christophe de Dinechin
On 2020-07-29 at 13:53 CEST, Markus Armbruster wrote... > Christophe de Dinechin writes: > >> On 2020-07-27 at 10:23 CEST, Markus Armbruster wrote... >>> Christophe de Dinechin writes: >>> On 2020-07-23 at 16:06 CEST, Markus Armbruster wrote... > Christophe de Dinechin writes: > [...]

Re: [PATCH 09/16] hw/block/nvme: refactor request bounds checking

2020-07-29 Thread Minwoo Im
On 20-07-20 13:37:41, Klaus Jensen wrote: > From: Klaus Jensen > > Hoist bounds checking into its own function and check for wrap-around. > > Signed-off-by: Klaus Jensen > Reviewed-by: Maxim Levitsky Reviewed-by: Minwoo Im

Re: [PATCH 08/16] hw/block/nvme: verify validity of prp lists in the cmb

2020-07-29 Thread Minwoo Im
On 20-07-20 13:37:40, Klaus Jensen wrote: > From: Klaus Jensen > > Before this patch the device already supported PRP lists in the CMB, but > it did not check for the validity of it nor announced the support in the > Identify Controller data structure LISTS field. > > If some of the PRPs in a PR

Re: [PATCH 10/16] hw/block/nvme: add check for mdts

2020-07-29 Thread Minwoo Im
On 20-07-20 13:37:42, Klaus Jensen wrote: > From: Klaus Jensen > > Add 'mdts' device parameter to control the Maximum Data Transfer Size of > the controller and check that it is respected. > > Signed-off-by: Klaus Jensen > Reviewed-by: Maxim Levitsky > --- > hw/block/nvme.c | 32 +++

Re: [PATCH 3/4] linux-user: Add support for a group of btrfs ioctls used to manipulate with devices

2020-07-29 Thread Laurent Vivier
Le 09/07/2020 à 17:52, Filip Bozuta a écrit : > This patch implements functionality for following ioctls: > > BTRFS_IOC_SCAN_DEV - Scanning device for a btrfs filesystem > > Scan a device for a btrfs filesystem. The device that is to > be scanned is passed in the ioctl's third argument wh

Re: [PATCH 2/7] build: fix device module builds

2020-07-29 Thread Christophe de Dinechin
On 2020-07-28 at 18:37 CEST, Philippe Mathieu-Daudé wrote... > On 7/23/20 7:46 PM, Christophe de Dinechin wrote: >> From: Gerd Hoffmann >> >> See comment. Feels quite hackish. Better ideas anyone? > > I don't understand this patch, how is it related to the rest of > your series? It's a leftov

Re: sysbus_create_simple Vs qdev_create

2020-07-29 Thread Paolo Bonzini
On 29/07/20 16:32, Eduardo Habkost wrote: > On Wed, Jul 29, 2020 at 11:54:35AM +0200, Paolo Bonzini wrote: >> On 29/07/20 00:47, Eduardo Habkost wrote: > [...] >>> Do we really need need QOM children to be accessible using the QOM >>> property API? >>> >>> Using the same code for both user-configur

Re: [PATCH v8 3/7] 9pfs: split out fs driver core of v9fs_co_readdir()

2020-07-29 Thread Greg Kurz
On Wed, 29 Jul 2020 10:11:54 +0200 Christian Schoenebeck wrote: > The implementation of v9fs_co_readdir() has two parts: the outer > part is executed by main I/O thread, whereas the inner part is > executed by fs driver on a background I/O thread. > > Move the inner part to its own new, private

Re: [PATCH 12/16] hw/block/nvme: refactor NvmeRequest clearing

2020-07-29 Thread Minwoo Im
On 20-07-20 13:37:44, Klaus Jensen wrote: > From: Klaus Jensen > > Move clearing of the structure from "clear before use" to "clear > after use". Yah, agree on this. Reviewed-by: Minwoo Im

Re: [PATCH 11/16] hw/block/nvme: be consistent about zeros vs zeroes

2020-07-29 Thread Minwoo Im
Reviewed-by: Minwoo Im Thanks,

Re: [PATCH 13/16] hw/block/nvme: add a namespace reference in NvmeRequest

2020-07-29 Thread Minwoo Im
On 20-07-20 13:37:45, Klaus Jensen wrote: > From: Klaus Jensen > > Instead of passing around the NvmeNamespace, add it as a member in the > NvmeRequest structure. > > Signed-off-by: Klaus Jensen Reviewed-by: Minwoo Im

Re: sysbus_create_simple Vs qdev_create

2020-07-29 Thread Paolo Bonzini
On 29/07/20 15:18, Markus Armbruster wrote: >> Even code riddled by backwards-compatibility special cases, such as >> -accel and -machine, can share code between themselves and -object to >> some extent; this is thanks to functions such as object_property_parse, >> whose parsing is deferred to visi

Re: [PATCH 14/16] hw/block/nvme: consolidate qsg/iov clearing

2020-07-29 Thread Minwoo Im
On 20-07-20 13:37:46, Klaus Jensen wrote: > From: Klaus Jensen > > Always destroy the request qsg/iov at the end of request use. > > Signed-off-by: Klaus Jensen > --- > hw/block/nvme.c | 48 +--- > 1 file changed, 17 insertions(+), 31 deletions(-) >

Re: sysbus_create_simple Vs qdev_create

2020-07-29 Thread Eduardo Habkost
On Wed, Jul 29, 2020 at 06:01:31PM +0200, Paolo Bonzini wrote: > On 29/07/20 16:32, Eduardo Habkost wrote: > > On Wed, Jul 29, 2020 at 11:54:35AM +0200, Paolo Bonzini wrote: > >> On 29/07/20 00:47, Eduardo Habkost wrote: > > [...] > >>> Do we really need need QOM children to be accessible using the

Re: [PATCH 4/4] linux-user: Add support for a group of btrfs ioctls used to get/set features

2020-07-29 Thread Laurent Vivier
Le 09/07/2020 à 17:52, Filip Bozuta a écrit : > This patch implements functionality for following ioctls: > > BTRFS_IOC_GET_FEATURES - Getting feature flags > > Read feature flags for a btrfs filesystem. The feature flags > are returned inside the ioctl's third argument which represents >

Re: [PATCH 15/16] hw/block/nvme: remove NvmeCmd parameter

2020-07-29 Thread Minwoo Im
On 20-07-20 13:37:47, Klaus Jensen wrote: > From: Klaus Jensen > > Keep a copy of the raw nvme command in the NvmeRequest and remove the > now redundant NvmeCmd parameter. > > Signed-off-by: Klaus Jensen I would really have suggested this change from 13th patch! Reviewed-by: Minwoo Im Thank

Re: [RFC v2 2/3] libvhost-user: handle endianness as mandated by the spec

2020-07-29 Thread Marc Hartmayer
On Wed, Jul 29, 2020 at 10:13 AM -0400, "Michael S. Tsirkin" wrote: > On Tue, Jul 28, 2020 at 12:52:11PM +0200, Marc Hartmayer wrote: >> On Tue, Jul 21, 2020 at 06:44 PM +0200, Halil Pasic >> wrote: >> > On Tue, 21 Jul 2020 09:40:10 -0400 >> > "Michael S. Tsirkin" wrote: >> > >> >> On Fri, Jul

Re: sysbus_create_simple Vs qdev_create

2020-07-29 Thread Paolo Bonzini
On 29/07/20 18:08, Eduardo Habkost wrote: The main thing we get from it is that the QOM paths treat children and links the same, and links are properties. To be honest it's not a feature that is very much developed, so perhaps we can remove it but we need to evaluate the impact

Re: [PATCH 16/16] hw/block/nvme: use preallocated qsg/iov in nvme_dma_prp

2020-07-29 Thread Minwoo Im
On 20-07-20 13:37:48, Klaus Jensen wrote: > From: Klaus Jensen > > Since clean up of the request qsg/iov is now always done post-use, there > is no need to use a stack-allocated qsg/iov in nvme_dma_prp. > > Signed-off-by: Klaus Jensen > Acked-by: Keith Busch > Reviewed-by: Maxim Levitsky > -

Re: What this mean "dead: 1" and "dead: 0 1" on each tb block start?

2020-07-29 Thread Richard Henderson
On 7/29/20 7:27 AM, tugouxp wrote: > HI folks: >   on each tb block start, there are following ir code, and the most confusing > me is that  the postfix of each line "dead:" flag, what it is represent > precisely? > i guess it may be related to the register or varible liveness for help > generatin

Re: [PATCH v2 1/4] linux-user: Add support for a group of btrfs inode ioctls

2020-07-29 Thread Laurent Vivier
Le 17/07/2020 à 16:44, Filip Bozuta a écrit : > This patch implements functionality of following ioctls: > > BTRFS_IOC_INO_LOOKUP - Reading tree root id and path > > Read tree root id and path for a given file or directory. > The name and tree root id are returned in an ioctl's third >

Re: [PATCH v2 2/4] linux-user: Add support for two btrfs ioctls used for subvolume

2020-07-29 Thread Laurent Vivier
Le 17/07/2020 à 16:44, Filip Bozuta a écrit : > This patch implements functionality for following ioctl: > > BTRFS_IOC_DEFAULT_SUBVOL - Setting a default subvolume > > Set a default subvolume for a btrfs filesystem. The third > ioctl's argument is a '__u64' (unsigned long long) which >

Re: [PATCH v2 3/4] linux-user: Add support for btrfs ioctls used to manage quota

2020-07-29 Thread Laurent Vivier
Le 17/07/2020 à 16:44, Filip Bozuta a écrit : > This patch implements functionality for following ioctls: > > BTRFS_IOC_QUOTA_CTL - Enabling/Disabling quota support > > Enable or disable quota support for a btrfs filesystem. Quota > support is enabled or disabled using the ioctls third ar

Re: [PATCH 1/4] hw/hppa: Sync hppa_hardware.h file with SeaBIOS sources

2020-07-29 Thread Richard Henderson
On 7/27/20 2:46 PM, Helge Deller wrote: > The hppa_hardware.h file is shared with SeaBIOS. Sync it. > > Signed-off-by: Helge Deller > --- > hw/hppa/hppa_hardware.h | 6 ++ > hw/hppa/lasi.c | 2 -- > 2 files changed, 6 insertions(+), 2 deletions(-) Acked-by: Richard Henderson r~

Re: [PATCH v2 4/4] linux-user: Add support for btrfs ioctls used to scrub a filesystem

2020-07-29 Thread Laurent Vivier
Le 17/07/2020 à 16:44, Filip Bozuta a écrit : > This patch implements functionality for following ioctls: > > BTRFS_IOC_SCRUB - Starting a btrfs filesystem scrub > > Start a btrfs filesystem scrub. The third ioctls argument > is a pointer to a following type: > > struct btrfs_ioctl_s

Re: [PATCH v0 3/4] migration: add background snapshot

2020-07-29 Thread Peter Xu
On Wed, Jul 29, 2020 at 03:54:46PM +0300, Denis Plotnikov wrote: > > Besides current solution, do you think we can make it simpler by only > > deliver > > the fault request to the background thread? We can let the background > > thread > > to do all the rests and IIUC we can drop all the complic

Re: [PATCH 1/1] s390x/s390-virtio-ccw: fix off-by-one in loadparm getter

2020-07-29 Thread Cornelia Huck
On Wed, 29 Jul 2020 15:02:22 +0200 Halil Pasic wrote: > As pointed out by Peter, g_memdup(ms->loadparm, sizeof(ms->loadparm) + 1) > reads one past of the end of ms->loadparm, so g_memdup() can not be used > here. > > Let's use malloc and memcpy instead! > > Fixes: d664548328 ("s390x/s390-virtio

Re: [PATCH 1/1] s390x/s390-virtio-ccw: fix off-by-one in loadparm getter

2020-07-29 Thread Peter Maydell
On Wed, 29 Jul 2020 at 14:05, Halil Pasic wrote: > > As pointed out by Peter, g_memdup(ms->loadparm, sizeof(ms->loadparm) + 1) > reads one past of the end of ms->loadparm, so g_memdup() can not be used > here. > > Let's use malloc and memcpy instead! > > Fixes: d664548328 ("s390x/s390-virtio-ccw:

Re: [PATCH for-5.2 0/6] Continue booting in case the first device is not bootable

2020-07-29 Thread Cornelia Huck
[restored cc:s] On Wed, 29 Jul 2020 13:42:05 +0200 Viktor Mihajlovski wrote: > On 7/28/20 8:37 PM, Thomas Huth wrote: > > If the user did not specify a "bootindex" property, the s390-ccw bios > > tries to find a bootable device on its own. Unfortunately, it alwasy > > stops at the very first dev

Re: [PATCH v8 1/7] tests/virtio-9p: added split readdir tests

2020-07-29 Thread Christian Schoenebeck
On Mittwoch, 29. Juli 2020 17:42:54 CEST Greg Kurz wrote: > On Wed, 29 Jul 2020 10:10:23 +0200 > > Christian Schoenebeck wrote: > > The previous, already existing 'basic' readdir test simply used a > > 'count' parameter big enough to retrieve all directory entries with a > > single Treaddir reque

Re: [PATCH 4/4] hw/display/artist.c: fix out of bounds check

2020-07-29 Thread Richard Henderson
On 7/27/20 2:46 PM, Helge Deller wrote: > -for (i = 0; i < pix_count; i++) { > +for (i = 0; i < pix_count && offset + i < buf->size; i++) { > artist_rop8(s, p + offset + pix_count - 1 - i, > (data & 1) ? (s->plane_mask >> 24) : 0); >

Re: [PATCH 05/16] hw/block/nvme: refactor dma read/write

2020-07-29 Thread Maxim Levitsky
On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > From: Klaus Jensen > > Refactor the nvme_dma_{read,write}_prp functions into a common function > taking a DMADirection parameter. > > Signed-off-by: Klaus Jensen > Reviewed-by: Maxim Levitsky > --- > hw/block/nvme.c | 88 +++

Re: [PATCH v8 3/7] 9pfs: split out fs driver core of v9fs_co_readdir()

2020-07-29 Thread Christian Schoenebeck
On Mittwoch, 29. Juli 2020 18:02:56 CEST Greg Kurz wrote: > On Wed, 29 Jul 2020 10:11:54 +0200 > > Christian Schoenebeck wrote: > > The implementation of v9fs_co_readdir() has two parts: the outer > > part is executed by main I/O thread, whereas the inner part is > > executed by fs driver on a ba

Re: [PATCH 11/16] hw/block/nvme: be consistent about zeros vs zeroes

2020-07-29 Thread Maxim Levitsky
On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > From: Klaus Jensen > > The NVM Express specification generally uses 'zeroes' and not 'zeros', > so let us align with it. > > Cc: Fam Zheng > Signed-off-by: Klaus Jensen > --- > block/nvme.c | 4 ++-- > hw/block/nvme.c | 8 +

Re: [PATCH 12/16] hw/block/nvme: refactor NvmeRequest clearing

2020-07-29 Thread Maxim Levitsky
On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > From: Klaus Jensen > > Move clearing of the structure from "clear before use" to "clear > after use". > > Signed-off-by: Klaus Jensen > --- > hw/block/nvme.c | 7 ++- > 1 file changed, 6 insertions(+), 1 deletion(-) > > diff --git a

Re: [PATCH 13/16] hw/block/nvme: add a namespace reference in NvmeRequest

2020-07-29 Thread Maxim Levitsky
On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > From: Klaus Jensen > > Instead of passing around the NvmeNamespace, add it as a member in the > NvmeRequest structure. > > Signed-off-by: Klaus Jensen > --- > hw/block/nvme.c | 21 ++--- > hw/block/nvme.h | 1 + > 2 file

Re: [PATCH 14/16] hw/block/nvme: consolidate qsg/iov clearing

2020-07-29 Thread Maxim Levitsky
On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > From: Klaus Jensen > > Always destroy the request qsg/iov at the end of request use. > > Signed-off-by: Klaus Jensen > --- > hw/block/nvme.c | 48 +--- > 1 file changed, 17 insertions(+), 31 de

Re: [PATCH 1/4] hw/hppa: Sync hppa_hardware.h file with SeaBIOS sources

2020-07-29 Thread Philippe Mathieu-Daudé
On 7/27/20 11:46 PM, Helge Deller wrote: > The hppa_hardware.h file is shared with SeaBIOS. Sync it. > > Signed-off-by: Helge Deller > --- > hw/hppa/hppa_hardware.h | 6 ++ > hw/hppa/lasi.c | 2 -- > 2 files changed, 6 insertions(+), 2 deletions(-) > > diff --git a/hw/hppa/hppa_har

Re: [PATCH 02/16] hw/block/nvme: add mapping helpers

2020-07-29 Thread Klaus Jensen
On Jul 29 16:57, Maxim Levitsky wrote: > On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Add nvme_map_addr, nvme_map_addr_cmb and nvme_addr_to_cmb helpers and > > use them in nvme_map_prp. > > > > This fixes a bug where in the case of a CMB transfer, the dev

Re: [PATCH 15/16] hw/block/nvme: remove NvmeCmd parameter

2020-07-29 Thread Maxim Levitsky
On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > From: Klaus Jensen > > Keep a copy of the raw nvme command in the NvmeRequest and remove the > now redundant NvmeCmd parameter. Shouldn't you clear the req->cmd in nvme_req_clear too for consistency? Other than that looks OK, but I might

Re: [PATCH 04/16] hw/block/nvme: remove redundant has_sg member

2020-07-29 Thread Klaus Jensen
On Jul 30 00:29, Minwoo Im wrote: > Klaus, > Hi Minwoo, Thanks for the reviews and welcome to the party! :) > On 20-07-20 13:37:36, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Remove the has_sg member from NvmeRequest since it's redundant. > > > > Also, make sure the request iov is de

Re: [PATCH 07/16] hw/block/nvme: add request mapping helper

2020-07-29 Thread Maxim Levitsky
On Thu, 2020-07-30 at 00:52 +0900, Minwoo Im wrote: > Klaus, > > On 20-07-20 13:37:39, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Introduce the nvme_map helper to remove some noise in the main nvme_rw > > function. > > > > Signed-off-by: Klaus Jensen > > Reviewed-by: Maxim Levitsky >

Re: [PATCH v3 07/18] hw/block/nvme: add support for the get log page command

2020-07-29 Thread Maxim Levitsky
On Wed, 2020-07-29 at 13:44 +0200, Klaus Jensen wrote: > On Jul 29 13:24, Maxim Levitsky wrote: > > On Mon, 2020-07-06 at 08:12 +0200, Klaus Jensen wrote: > > > From: Klaus Jensen > > > > > > Add support for the Get Log Page command and basic implementations of > > > the mandatory Error Informati

Re: [PATCH 05/16] hw/block/nvme: refactor dma read/write

2020-07-29 Thread Klaus Jensen
On Jul 29 20:35, Maxim Levitsky wrote: > On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Refactor the nvme_dma_{read,write}_prp functions into a common function > > taking a DMADirection parameter. > > > > Signed-off-by: Klaus Jensen > > Reviewed-by: Maxim

Re: [PATCH v5] hw/pci-host: save/restore pci host config register for old ones

2020-07-29 Thread Dr. David Alan Gilbert
* Michael S. Tsirkin (m...@redhat.com) wrote: > On Tue, Jul 28, 2020 at 11:27:09AM +0800, Hogan Wang wrote: > > The i440fx and q35 machines integrate i440FX or MCH PCI device by default. > > Refer to i440FX and ICH9-LPC spcifications, there are some reserved > > configuration registers can used to

Re: [PATCH v3 08/18] hw/block/nvme: add support for the asynchronous event request command

2020-07-29 Thread Maxim Levitsky
On Wed, 2020-07-29 at 15:37 +0200, Klaus Jensen wrote: > On Jul 29 13:43, Maxim Levitsky wrote: > > On Mon, 2020-07-06 at 08:12 +0200, Klaus Jensen wrote: > > > From: Klaus Jensen > > > > > > Add support for the Asynchronous Event Request command. Required for > > > compliance with NVMe revision

Re: [PATCH v3 12/18] hw/block/nvme: support the get/set features select and save fields

2020-07-29 Thread Maxim Levitsky
On Wed, 2020-07-29 at 15:48 +0200, Klaus Jensen wrote: > On Jul 29 16:17, Maxim Levitsky wrote: > > On Mon, 2020-07-06 at 08:12 +0200, Klaus Jensen wrote: > > > From: Klaus Jensen > > > > > > Since the device does not have any persistent state storage, no > > > features are "saveable" and setting

[PATCH] schemas: Add vim modeline

2020-07-29 Thread Andrea Bolognani
The various schemas included in QEMU use a JSON-based format which is, however, strictly speaking not valid JSON. As a consequence, when vim tries to apply syntax highlight rules for JSON (as guessed from the file name), the result is an unreadable mess which mostly consist of red markers pointing

Re: [PATCH 12/16] hw/block/nvme: refactor NvmeRequest clearing

2020-07-29 Thread Klaus Jensen
On Jul 29 20:47, Maxim Levitsky wrote: > On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Move clearing of the structure from "clear before use" to "clear > > after use". > > > > Signed-off-by: Klaus Jensen > > --- > > hw/block/nvme.c | 7 ++- > > 1 fil

Re: device compatibility interface for live migration with assigned devices

2020-07-29 Thread Dr. David Alan Gilbert
* Alex Williamson (alex.william...@redhat.com) wrote: > On Mon, 27 Jul 2020 15:24:40 +0800 > Yan Zhao wrote: > > > > > As you indicate, the vendor driver is responsible for checking version > > > > information embedded within the migration stream. Therefore a > > > > migration should fail early

[PATCH for-5.1] qapi/machine.json: Fix missing newline in doc comment

2020-07-29 Thread Peter Maydell
In commit 176d2cda0dee9f4 we added the @die-id field to the CpuInstanceProperties struct, but in the process accidentally removed the newline between the doc-comment lines for @core-id and @thread-id. Put the newline back in; this fixes a misformatting in the generated HTML QMP reference manual.

Re: device compatibility interface for live migration with assigned devices

2020-07-29 Thread Alex Williamson
On Wed, 29 Jul 2020 12:28:46 +0100 Sean Mooney wrote: > On Wed, 2020-07-29 at 16:05 +0800, Yan Zhao wrote: > > On Mon, Jul 27, 2020 at 04:23:21PM -0600, Alex Williamson wrote: > > > On Mon, 27 Jul 2020 15:24:40 +0800 > > > Yan Zhao wrote: > > > > > > > > > As you indicate, the vendor driver

Re: [PATCH 07/16] hw/block/nvme: add request mapping helper

2020-07-29 Thread Klaus Jensen
On Jul 29 21:31, Maxim Levitsky wrote: > On Thu, 2020-07-30 at 00:52 +0900, Minwoo Im wrote: > > Klaus, > > > > On 20-07-20 13:37:39, Klaus Jensen wrote: > > > From: Klaus Jensen > > > > > > Introduce the nvme_map helper to remove some noise in the main nvme_rw > > > function. > > > > > > Signe

Re: [PATCH for-5.1] qapi/machine.json: Fix missing newline in doc comment

2020-07-29 Thread Eric Blake
On 7/29/20 2:10 PM, Peter Maydell wrote: In commit 176d2cda0dee9f4 we added the @die-id field to the CpuInstanceProperties struct, but in the process accidentally removed the newline between the doc-comment lines for @core-id and @thread-id. Put the newline back in; this fixes a misformatting in

Re: [PATCH 10/16] hw/block/nvme: add check for mdts

2020-07-29 Thread Klaus Jensen
On Jul 30 01:00, Minwoo Im wrote: > On 20-07-20 13:37:42, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Add 'mdts' device parameter to control the Maximum Data Transfer Size of > > the controller and check that it is respected. > > > > Signed-off-by: Klaus Jensen > > Reviewed-by: Maxim Lev

Re: [PATCH 15/16] hw/block/nvme: remove NvmeCmd parameter

2020-07-29 Thread Klaus Jensen
On Jul 30 01:10, Minwoo Im wrote: > On 20-07-20 13:37:47, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Keep a copy of the raw nvme command in the NvmeRequest and remove the > > now redundant NvmeCmd parameter. > > > > Signed-off-by: Klaus Jensen > > I would really have suggested this cha

Re: [PATCH for-5.1] qapi/machine.json: Fix missing newline in doc comment

2020-07-29 Thread Philippe Mathieu-Daudé
On 7/29/20 9:10 PM, Peter Maydell wrote: > In commit 176d2cda0dee9f4 we added the @die-id field > to the CpuInstanceProperties struct, but in the process > accidentally removed the newline between the doc-comment > lines for @core-id and @thread-id. > > Put the newline back in; this fixes a misfor

Re: [PATCH 14/16] hw/block/nvme: consolidate qsg/iov clearing

2020-07-29 Thread Klaus Jensen
On Jul 29 21:18, Maxim Levitsky wrote: > On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Always destroy the request qsg/iov at the end of request use. > > > > Signed-off-by: Klaus Jensen > > --- > > hw/block/nvme.c | 48 +---

Re: [PATCH 06/16] hw/block/nvme: pass request along for tracing

2020-07-29 Thread Klaus Jensen
On Jul 30 00:49, Minwoo Im wrote: > Klaus, > > On 20-07-20 13:37:38, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Pass along the NvmeRequest in various functions since it is very useful > > for tracing. > > One doubt here. > This patch has put NvmeRequest argument to the nvme_map_prp()

Re: [PATCH v3 0/7] Fix scsi devices plug/unplug races w.r.t virtio-scsi iothread

2020-07-29 Thread Maxim Levitsky
On Wed, 2020-07-15 at 18:01 +0300, Maxim Levitsky wrote: > Hi! > > This is a patch series that is a result of my discussion with Paulo on > how to correctly fix the root cause of the BZ #1812399. > > The root cause of this bug is the fact that IO thread is running mostly > unlocked versus main th

Re: [PATCH 16/16] hw/block/nvme: use preallocated qsg/iov in nvme_dma_prp

2020-07-29 Thread Klaus Jensen
On Jul 30 01:15, Minwoo Im wrote: > On 20-07-20 13:37:48, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Since clean up of the request qsg/iov is now always done post-use, there > > is no need to use a stack-allocated qsg/iov in nvme_dma_prp. > > > > Signed-off-by: Klaus Jensen > > Acked-by

[PATCH] configure: actually disable 'git_update' mode with --disable-git-update

2020-07-29 Thread Dan Streetman
The --disable-git-update configure param sets git_update=no, but some later checks only look for the .git dir. This changes the --enable-git-update to set git_update=yes but also fail if it does not find a .git dir. Then all the later checks for the .git dir can just be changed to a check for $git_

Re: [PATCH 15/16] hw/block/nvme: remove NvmeCmd parameter

2020-07-29 Thread Klaus Jensen
On Jul 29 21:25, Maxim Levitsky wrote: > On Mon, 2020-07-20 at 13:37 +0200, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Keep a copy of the raw nvme command in the NvmeRequest and remove the > > now redundant NvmeCmd parameter. > > Shouldn't you clear the req->cmd in nvme_req_clear too for

RE: qemu repo lockdown message for a WHPX PR

2020-07-29 Thread Sunil Muthuswamy
Adding Peter Maydell as well. > -Original Message- > From: Sunil Muthuswamy > Sent: Tuesday, July 28, 2020 12:20 PM > To: Paolo Bonzini > Cc: qemu-devel@nongnu.org > Subject: qemu repo lockdown message for a WHPX PR > > Hey Paolo, > > Following your suggestion of creating PRs for WHPX c

[PATCH] linux-user: Map signal numbers in fcntl

2020-07-29 Thread Timothy Baldwin
Map signal numbers in fcntl F_SETSIG and F_GETSIG. Signed-off-by: Timothy E Baldwin ---  linux-user/syscall.c | 10 --  1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 945fc25279..8456bad109 100644 --- a/linux-user/syscall.c

Re: [PATCH v3 08/18] hw/block/nvme: add support for the asynchronous event request command

2020-07-29 Thread Klaus Jensen
On Jul 29 21:45, Maxim Levitsky wrote: > On Wed, 2020-07-29 at 15:37 +0200, Klaus Jensen wrote: > > On Jul 29 13:43, Maxim Levitsky wrote: > > > On Mon, 2020-07-06 at 08:12 +0200, Klaus Jensen wrote: > > > > +DEFINE_PROP_UINT8("aerl", NvmeCtrl, params.aerl, 3), > > > So this is number of AERs t

Re: [PATCH v5 3/3] nvme: allow cmb and pmr to be enabled on same device

2020-07-29 Thread Klaus Jensen
On Jul 27 11:59, Andrzej Jakowski wrote: > On 7/27/20 2:06 AM, Klaus Jensen wrote: > > On Jul 23 09:03, Andrzej Jakowski wrote: > >> So far it was not possible to have CMB and PMR emulated on the same > >> device, because BAR2 was used exclusively either of PMR or CMB. This > >> patch places CMB at

Re: qemu repo lockdown message for a WHPX PR

2020-07-29 Thread Eric Blake
On 7/29/20 3:05 PM, Sunil Muthuswamy wrote: Adding Peter Maydell as well. -Original Message- From: Sunil Muthuswamy Sent: Tuesday, July 28, 2020 12:20 PM To: Paolo Bonzini Cc: qemu-devel@nongnu.org Subject: qemu repo lockdown message for a WHPX PR Hey Paolo, Following your suggestion

RE: [EXTERNAL] Re: qemu repo lockdown message for a WHPX PR

2020-07-29 Thread Sunil Muthuswamy
No, I am trying to submit a pull request as suggested by Paolo in this post: https://patchwork.ozlabs.org/project/qemu-devel/patch/sn4pr2101mb08804d23439166e81ff151f7c0...@sn4pr2101mb0880.namprd21.prod.outlook.com/#2373829 > -Original Message- > From: Eric Blake > Sent: Wednesday, July 29

Re: qemu repo lockdown message for a WHPX PR

2020-07-29 Thread Paolo Bonzini
On 28/07/20 21:19, Sunil Muthuswamy wrote: > Hey Paolo, > > Following your suggestion of creating PRs for WHPX changes, I tried creating > a PR https://github.com/qemu/qemu/pull/95 > > But, I am getting repo-lockdown message. What do I need to do differently? Hi, I was not referring to github

Re: [RFC v2 27/76] target/riscv: rvv-0.9: load/store whole register instructions

2020-07-29 Thread Richard Henderson
On 7/22/20 2:15 AM, frank.ch...@sifive.com wrote: > +static void > +vext_ldst_whole(void *vd, target_ulong base, CPURISCVState *env, uint32_t > desc, > +vext_ldst_elem_fn *ldst_elem, uint32_t esz, uintptr_t ra, > +MMUAccessType access_type) > +{ > +uint32_t i, k

Re: [PATCH 02/16] hw/block/nvme: add mapping helpers

2020-07-29 Thread Andrzej Jakowski
On 7/20/20 4:37 AM, Klaus Jensen wrote: > From: Klaus Jensen > > Add nvme_map_addr, nvme_map_addr_cmb and nvme_addr_to_cmb helpers and > use them in nvme_map_prp. > > This fixes a bug where in the case of a CMB transfer, the device would > map to the buffer with a wrong length. > > Fixes: b2b2b

[Bug 1888601] Re: QEMU v5.1.0-rc0/rc1 hang with nested virtualization

2020-07-29 Thread Simon Kaegi
``` (gdb) thread apply all bt Thread 5 (LWP 211759): #0 0x7ff56a9988d8 in g_str_hash () #1 0x7ff56a997a0c in g_hash_table_lookup () #2 0x7ff56a6c528f in type_table_lookup (name=0x7ff56ac9a9dd "virtio-bus") at qom/object.c:84 #3 type_get_by_name (name=0x7ff56ac9a9dd "virtio-bus") a

Re: qemu repo lockdown message for a WHPX PR

2020-07-29 Thread Peter Maydell
On Wed, 29 Jul 2020 at 21:29, Paolo Bonzini wrote: > I was not referring to github pull requests, but rather to a maintainer > pull request. This is also sent to the mailing list. There is no > QEMU-specific documentation since maintainers are generally experienced > enough to have observed how

[Bug 1888601] Re: QEMU v5.1.0-rc0/rc1 hang with nested virtualization

2020-07-29 Thread Simon Kaegi
Here's what I get with 5.1.0-rc2 ``` (gdb) thread apply all bt Thread 5 (LWP 23730): #0 0x7f9ae6040ebb in ioctl () #1 0x7f9ae57cf98b in kvm_vcpu_ioctl (cpu=cpu@entry=0x57539ea0, type=type@entry=44672) at /root/qemu/accel/kvm/kvm-all.c:2631 #2 0x7f9ae57cfac5 in kvm_cpu_exec (cp

Re: [PATCH 02/16] hw/block/nvme: add mapping helpers

2020-07-29 Thread Klaus Jensen
On Jul 29 13:40, Andrzej Jakowski wrote: > On 7/20/20 4:37 AM, Klaus Jensen wrote: > > From: Klaus Jensen > > > > Add nvme_map_addr, nvme_map_addr_cmb and nvme_addr_to_cmb helpers and > > use them in nvme_map_prp. > > > > This fixes a bug where in the case of a CMB transfer, the device would > >

RE: [PATCH v2 1/3] hw/i386: Initialize topo_ids from CpuInstanceProperties

2020-07-29 Thread Babu Moger
Igor, Sorry. Few more questions. > -Original Message- > From: Igor Mammedov > Sent: Wednesday, July 29, 2020 9:12 AM > To: Moger, Babu > Cc: pbonz...@redhat.com; r...@twiddle.net; qemu-devel@nongnu.org; > ehabk...@redhat.com > Subject: Re: [PATCH v2 1/3] hw/i386: Initialize topo_ids from

Re: [PATCH 02/16] hw/block/nvme: add mapping helpers

2020-07-29 Thread Andrzej Jakowski
On 7/29/20 2:24 PM, Klaus Jensen wrote: > On Jul 29 13:40, Andrzej Jakowski wrote: >> On 7/20/20 4:37 AM, Klaus Jensen wrote: >>> From: Klaus Jensen >>> >>> Add nvme_map_addr, nvme_map_addr_cmb and nvme_addr_to_cmb helpers and >>> use them in nvme_map_prp. >>> >>> This fixes a bug where in the cas

Re: [PATCH 02/16] hw/block/nvme: add mapping helpers

2020-07-29 Thread Klaus Jensen
On Jul 29 14:51, Andrzej Jakowski wrote: > On 7/29/20 2:24 PM, Klaus Jensen wrote: > > On Jul 29 13:40, Andrzej Jakowski wrote: > >> On 7/20/20 4:37 AM, Klaus Jensen wrote: > >>> From: Klaus Jensen > >>> > >>> Add nvme_map_addr, nvme_map_addr_cmb and nvme_addr_to_cmb helpers and > >>> use them in

[PATCH v6 2/2] nvme: allow cmb and pmr to be enabled on same device

2020-07-29 Thread Andrzej Jakowski
So far it was not possible to have CMB and PMR emulated on the same device, because BAR2 was used exclusively either of PMR or CMB. This patch places CMB at BAR4 offset so it not conflicts with MSI-X vectors. Signed-off-by: Andrzej Jakowski --- hw/block/nvme.c | 124

[PATCH v6 1/2] nvme: indicate CMB support through controller capabilities register

2020-07-29 Thread Andrzej Jakowski
This patch sets CMBS bit in controller capabilities register when user configures NVMe driver with CMB support, so capabilites are correctly reported to guest OS. Signed-off-by: Andrzej Jakowski Reviewed-by: Klaus Jensen Reviewed-by: Maxim Levitsky --- hw/block/nvme.c | 1 + include/bloc

[PATCH v6] nvme: allow cmb and pmr emulation on same device

2020-07-29 Thread Andrzej Jakowski
Resending series recently posted on mailing list related to nvme device extension with couple of fixes after review. This patch series does following: - Fixes problem where CMBS bit was not set in controller capabilities register, so support for CMB was not correctly advertised to guest. Th

<    1   2   3   >