Re: [PATCH] vdpa/mlx5: Extract correct pointer from driver data

2021-02-15 Thread Leon Romanovsky
On Tue, Feb 16, 2021 at 08:42:26AM +0200, Eli Cohen wrote: > On Tue, Feb 16, 2021 at 08:35:51AM +0200, Leon Romanovsky wrote: > > On Tue, Feb 16, 2021 at 07:50:22AM +0200, Eli Cohen wrote: > > > struct mlx5_vdpa_net pointer was stored in drvdata. Extract it as well > > > in mlx5v_remove(). > > > >

Re: [PATCH] vdpa/mlx5: Extract correct pointer from driver data

2021-02-15 Thread Leon Romanovsky
On Tue, Feb 16, 2021 at 07:50:22AM +0200, Eli Cohen wrote: > struct mlx5_vdpa_net pointer was stored in drvdata. Extract it as well > in mlx5v_remove(). > > Fixes: 74c9729dd892 ("vdpa/mlx5: Connect mlx5_vdpa to auxiliary bus") > Signed-off-by: Eli Cohen > --- > drivers/vdpa/mlx5/net/mlx5_vnet.c |

Re: [External] Re: vsock virtio: questions about supporting DGRAM type

2021-02-15 Thread Jiang Wang .
On Mon, Feb 15, 2021 at 12:53 AM Arseny Krasnov wrote: > > > On 14.02.2021 02:46, Jiang Wang . wrote: > > On Fri, Feb 12, 2021 at 7:19 AM Arseny Krasnov > > wrote: > >> > >> On 12.02.2021 12:02, Stefano Garzarella wrote: > >>> Hi Jiang, > >>> > >>> CCing Arseny who is working on SOCK_SEQPACKET su

Re: [External] Re: vsock virtio: questions about supporting DGRAM type

2021-02-15 Thread Jiang Wang .
On Mon, Feb 15, 2021 at 12:31 AM Stefano Garzarella wrote: > > On Sat, Feb 13, 2021 at 03:26:18PM -0800, Jiang Wang . wrote: > >On Fri, Feb 12, 2021 at 1:02 AM Stefano Garzarella > >wrote: > >> > >> Hi Jiang, > >> > >> CCing Arseny who is working on SOCK_SEQPACKET support for virtio-vsock > >> [

Re: [PATCH] virtio/s390: implement virtio-ccw revision 2 correctly

2021-02-15 Thread Halil Pasic
On Mon, 15 Feb 2021 12:47:02 +0100 Cornelia Huck wrote: > On Fri, 12 Feb 2021 18:04:11 +0100 > Cornelia Huck wrote: > > > CCW_CMD_READ_STATUS was introduced with revision 2 of virtio-ccw, > > and drivers should only rely on it being implemented when they > > negotiated at least that revision wi

Re: [PATCH 0/6] drm: Move vmap out of commit tail for SHMEM-based drivers

2021-02-15 Thread Thomas Zimmermann
Hi Am 05.02.21 um 10:05 schrieb Gerd Hoffmann: Hi, I smoke-tested the code by running fbdev, Xorg and weston with the converted mgag200 driver. Looks sane to me. Survived cirrus smoke test too. Reviewers are hard to find. Since you reviewed the shadow-plane conversion for cirrus; may I

Re: [PATCH for 5.10] vdpa_sim: fix param validation in vdpasim_get_config()

2021-02-15 Thread Greg KH
On Mon, Feb 15, 2021 at 04:03:21PM +0100, Stefano Garzarella wrote: > On Mon, Feb 15, 2021 at 03:32:19PM +0100, Greg KH wrote: > > On Thu, Feb 11, 2021 at 05:25:19PM +0100, Stefano Garzarella wrote: > > > Commit 65b709586e222fa6ffd4166ac7fdb5d5dad113ee upstream. > > > > No, this really is not that

Re: [PATCH for 5.10] vdpa_sim: fix param validation in vdpasim_get_config()

2021-02-15 Thread Stefano Garzarella
On Mon, Feb 15, 2021 at 03:32:19PM +0100, Greg KH wrote: On Thu, Feb 11, 2021 at 05:25:19PM +0100, Stefano Garzarella wrote: Commit 65b709586e222fa6ffd4166ac7fdb5d5dad113ee upstream. No, this really is not that commit, so please do not say it is. Oops, sorry. Before this patch, if 'offse

Re: [PATCH for 5.10] vdpa_sim: fix param validation in vdpasim_get_config()

2021-02-15 Thread Greg KH
On Thu, Feb 11, 2021 at 05:25:19PM +0100, Stefano Garzarella wrote: > Commit 65b709586e222fa6ffd4166ac7fdb5d5dad113ee upstream. No, this really is not that commit, so please do not say it is. > Before this patch, if 'offset + len' was equal to > sizeof(struct virtio_net_config), the entire buffer

RE: [PATCH] vdpa: Fix memory leak in error unwinding path

2021-02-15 Thread Parav Pandit
> From: Stefano Garzarella > Sent: Monday, February 15, 2021 5:16 PM > > On Sat, Feb 13, 2021 at 08:39:19PM +0200, Parav Pandit wrote: > >When device get command fails to find the device or mdev, it skips to > >free the skb during error unwinding path. > >Fix it by freeing in error unwind path

[PATCH] vhost vdpa: setup vq irq only when set status includes VIRTIO_CONFIG_S_DRIVER_OK

2021-02-15 Thread Gautam Dawar
When qemu with vhost-vdpa netdevice is run for the first time, it works well. But after the VM is powered off, the next qemu run causes kernel panic due to a NULL pointer dereference in irq_bypass_register_producer(). When the VM is powered off, vhost_dev_stop() is invoked which in turn calls vhos

[PATCH v1 2/2] virtio-mem: support VIRTIO_MEM_F_UNPLUGGED_INACCESSIBLE

2021-02-15 Thread David Hildenbrand
The spec currently states that while unplugged memory should not be read, the device has to allow for reading unplugged memory inside the usable region. The primary motivation for this default handling was that in some corner cases in Linux, unplugged memory inside added Linux memory blocks (and ex

[PATCH v1 0/2] virito-mem: one fix and VIRTIO_MEM_F_UNPLUGGED_INACCESSIBLE

2021-02-15 Thread David Hildenbrand
One minor fix and introduction of / support for VIRTIO_MEM_F_UNPLUGGED_INACCESSIBLE. Looking into supporting file-based memory backends (shmem, hugetlbfs, ...) for virtio-mem in QEMU cleanly, I realized that we have to indicate that unplugged memory is completely inaccessible. Otherwise, Linux mig

[PATCH v1 1/2] virtio-mem: don't read big block size in SBM

2021-02-15 Thread David Hildenbrand
We are reading the a BBM (Big Block Mode) value while in SBM (Sub Block Mode) while initializing. Fortunately, vm->bbm.bb_size maps to some counter in the vm->sbm.mb_count array, which is 0 at that point in time. No harm done; still, this was unintended and is not future-proof. Fixes: 4ba50cd3355

Re: [PATCH] virtio/s390: implement virtio-ccw revision 2 correctly

2021-02-15 Thread Cornelia Huck
On Fri, 12 Feb 2021 18:04:11 +0100 Cornelia Huck wrote: > CCW_CMD_READ_STATUS was introduced with revision 2 of virtio-ccw, > and drivers should only rely on it being implemented when they > negotiated at least that revision with the device. > > However, virtio_ccw_get_status() issued READ_STATU

Re: [PATCH] vdpa: Fix memory leak in error unwinding path

2021-02-15 Thread Stefano Garzarella
On Sat, Feb 13, 2021 at 08:39:19PM +0200, Parav Pandit wrote: When device get command fails to find the device or mdev, it skips to free the skb during error unwinding path. Fix it by freeing in error unwind path. Fixes: a12a2f694ce8 ("vdpa: Enable user to query vdpa device info") Signed-off-by:

Re: [PATCH] vdpa_sim: Skip typecasting from void*

2021-02-15 Thread Stefano Garzarella
On Sat, Feb 13, 2021 at 08:39:51PM +0200, Parav Pandit wrote: Typecasting from void* to virtio_net_config* is not needed. Remove it. Signed-off-by: Parav Pandit --- drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/vdpa/vdpa_sim/vd

Re: [External] Re: vsock virtio: questions about supporting DGRAM type

2021-02-15 Thread Stefano Garzarella
On Sat, Feb 13, 2021 at 03:26:18PM -0800, Jiang Wang . wrote: On Fri, Feb 12, 2021 at 1:02 AM Stefano Garzarella wrote: Hi Jiang, CCing Arseny who is working on SOCK_SEQPACKET support for virtio-vsock [1]. On Thu, Feb 11, 2021 at 10:04:34PM -0800, Jiang Wang . wrote: >Hi guys, > >I am workin