Re: [PATCH 1/2] vdpa: support per virtqueue max queue size

2021-07-06 Thread Jason Wang
在 2021/7/7 下午12:04, Yongji Xie 写道: static long vhost_vdpa_get_vring_num(struct vhost_vdpa *v, u16 __user *argp) { - struct vdpa_device *vdpa = v->vdpa; - const struct vdpa_config_ops *ops = vdpa->config; u16 num; - num = ops->get_vq_num_max(vdpa); + /* +

Re: [PATCH linux-next v3 2/6] vdpa: Introduce query of device config layout

2021-07-06 Thread Jason Wang
在 2021/7/7 上午1:07, Parav Pandit 写道: From: Jason Wang Sent: Monday, July 5, 2021 10:05 AM 在 2021/7/2 下午2:04, Parav Pandit 写道: From: Jason Wang Sent: Thursday, July 1, 2021 1:13 PM Actually it depends on what attributes is required for building the config. We can simply reuse the

Re: [PATCH v2 4/4] bus: Make remove callback return void

2021-07-06 Thread Bjorn Andersson
On Tue 06 Jul 13:43 CDT 2021, Uwe Kleine-K?nig wrote: > Hello Bjorn, > > On Tue, Jul 06, 2021 at 01:08:18PM -0500, Bjorn Andersson wrote: > > On Tue 06 Jul 10:48 CDT 2021, Uwe Kleine-K?nig wrote: > > > diff --git a/drivers/rpmsg/rpmsg_core.c b/drivers/rpmsg/rpmsg_core.c > > > index

Re: [PATCH v2 4/4] bus: Make remove callback return void

2021-07-06 Thread Dan Williams
On Tue, Jul 6, 2021 at 8:51 AM Uwe Kleine-König wrote: > > The driver core ignores the return value of this callback because there > is only little it can do when a device disappears. > > This is the final bit of a long lasting cleanup quest where several > buses were converted to also return

Re: [PATCH v2 4/4] bus: Make remove callback return void

2021-07-06 Thread Bjorn Andersson
On Tue 06 Jul 10:48 CDT 2021, Uwe Kleine-K?nig wrote: > The driver core ignores the return value of this callback because there > is only little it can do when a device disappears. > > This is the final bit of a long lasting cleanup quest where several > buses were converted to also return void

RE: [PATCH linux-next v3 2/6] vdpa: Introduce query of device config layout

2021-07-06 Thread Parav Pandit
> From: Jason Wang > Sent: Monday, July 5, 2021 10:05 AM > > 在 2021/7/2 下午2:04, Parav Pandit 写道: > > > >> From: Jason Wang > >> Sent: Thursday, July 1, 2021 1:13 PM > >> > >> > >> Actually it depends on what attributes is required for building the config. > >> > >> We can simply reuse the

Re: [PATCH v2 4/4] bus: Make remove callback return void

2021-07-06 Thread Rafael J. Wysocki
On Tue, Jul 6, 2021 at 5:53 PM Uwe Kleine-König wrote: > > The driver core ignores the return value of this callback because there > is only little it can do when a device disappears. > > This is the final bit of a long lasting cleanup quest where several > buses were converted to also return

Re: [PATCH v2 4/4] bus: Make remove callback return void

2021-07-06 Thread Cornelia Huck
On Tue, Jul 06 2021, Uwe Kleine-König wrote: > The driver core ignores the return value of this callback because there > is only little it can do when a device disappears. > > This is the final bit of a long lasting cleanup quest where several > buses were converted to also return void from

Re: [PATCH 1/2] vdpa: support per virtqueue max queue size

2021-07-06 Thread Stefan Hajnoczi
On Mon, Jul 05, 2021 at 03:19:09PM +0800, Jason Wang wrote: > Virtio spec allows the device to specify the per virtqueue max queue > size. vDPA needs to adapt to this flexibility. E.g Qemu advertise a > small control virtqueue for virtio-net. > > So this patch adds a index parameter to

Re: [PATCH] bus: Make remove callback return void

2021-07-06 Thread Lee Jones
On Tue, 06 Jul 2021, Uwe Kleine-König wrote: > The driver core ignores the return value of this callback because there > is only little it can do when a device disappears. > > This is the final bit of a long lasting cleanup quest where several > buses were converted to also return void from

[PATCH AUTOSEL 4.4 09/31] drm/virtio: Fix double free on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit cec7f1774605a5ef47c134af62afe7c75c30b0ee ] The virtio_gpu_init() will free vgdev and vgdev->vbufs on failure. But such failure will be caught by virtio_gpu_probe() and then virtio_gpu_release() will be called to do some cleanup which will free vgdev and

[PATCH AUTOSEL 4.4 08/31] drm/virtio: Fixes a potential NULL pointer dereference on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit 17f46f488a5d82c5568e6e786cd760bba1c2ee09 ] The dev->dev_private might not be allocated if virtio_gpu_pci_quirk() or virtio_gpu_init() failed. In this case, we should avoid the cleanup in virtio_gpu_release(). Signed-off-by: Xie Yongji Link:

[PATCH AUTOSEL 4.9 09/35] drm/virtio: Fix double free on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit cec7f1774605a5ef47c134af62afe7c75c30b0ee ] The virtio_gpu_init() will free vgdev and vgdev->vbufs on failure. But such failure will be caught by virtio_gpu_probe() and then virtio_gpu_release() will be called to do some cleanup which will free vgdev and

[PATCH AUTOSEL 4.9 08/35] drm/virtio: Fixes a potential NULL pointer dereference on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit 17f46f488a5d82c5568e6e786cd760bba1c2ee09 ] The dev->dev_private might not be allocated if virtio_gpu_pci_quirk() or virtio_gpu_init() failed. In this case, we should avoid the cleanup in virtio_gpu_release(). Signed-off-by: Xie Yongji Link:

[PATCH AUTOSEL 4.14 21/45] virtio_net: Remove BUG() to avoid machine dead

2021-07-06 Thread Sasha Levin
From: Xianting Tian [ Upstream commit 85eb1389458d134bdb75dad502cc026c3753a619 ] We should not directly BUG() when there is hdr error, it is better to output a print when such error happens. Currently, the caller of xmit_skb() already did it. Signed-off-by: Xianting Tian Reviewed-by: Leon

[PATCH AUTOSEL 4.14 13/45] drm/virtio: Fix double free on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit cec7f1774605a5ef47c134af62afe7c75c30b0ee ] The virtio_gpu_init() will free vgdev and vgdev->vbufs on failure. But such failure will be caught by virtio_gpu_probe() and then virtio_gpu_release() will be called to do some cleanup which will free vgdev and

[PATCH AUTOSEL 4.14 12/45] drm/virtio: Fixes a potential NULL pointer dereference on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit 17f46f488a5d82c5568e6e786cd760bba1c2ee09 ] The dev->dev_private might not be allocated if virtio_gpu_pci_quirk() or virtio_gpu_init() failed. In this case, we should avoid the cleanup in virtio_gpu_release(). Signed-off-by: Xie Yongji Link:

[PATCH AUTOSEL 4.19 24/55] virtio_net: Remove BUG() to avoid machine dead

2021-07-06 Thread Sasha Levin
From: Xianting Tian [ Upstream commit 85eb1389458d134bdb75dad502cc026c3753a619 ] We should not directly BUG() when there is hdr error, it is better to output a print when such error happens. Currently, the caller of xmit_skb() already did it. Signed-off-by: Xianting Tian Reviewed-by: Leon

[PATCH AUTOSEL 4.19 14/55] drm/virtio: Fix double free on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit cec7f1774605a5ef47c134af62afe7c75c30b0ee ] The virtio_gpu_init() will free vgdev and vgdev->vbufs on failure. But such failure will be caught by virtio_gpu_probe() and then virtio_gpu_release() will be called to do some cleanup which will free vgdev and

[PATCH AUTOSEL 4.19 13/55] drm/virtio: Fixes a potential NULL pointer dereference on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit 17f46f488a5d82c5568e6e786cd760bba1c2ee09 ] The dev->dev_private might not be allocated if virtio_gpu_pci_quirk() or virtio_gpu_init() failed. In this case, we should avoid the cleanup in virtio_gpu_release(). Signed-off-by: Xie Yongji Link:

[PATCH AUTOSEL 5.4 30/74] virtio_net: Remove BUG() to avoid machine dead

2021-07-06 Thread Sasha Levin
From: Xianting Tian [ Upstream commit 85eb1389458d134bdb75dad502cc026c3753a619 ] We should not directly BUG() when there is hdr error, it is better to output a print when such error happens. Currently, the caller of xmit_skb() already did it. Signed-off-by: Xianting Tian Reviewed-by: Leon

[PATCH AUTOSEL 5.4 16/74] drm/virtio: Fix double free on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit cec7f1774605a5ef47c134af62afe7c75c30b0ee ] The virtio_gpu_init() will free vgdev and vgdev->vbufs on failure. But such failure will be caught by virtio_gpu_probe() and then virtio_gpu_release() will be called to do some cleanup which will free vgdev and

[PATCH AUTOSEL 5.4 15/74] drm/virtio: Fixes a potential NULL pointer dereference on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit 17f46f488a5d82c5568e6e786cd760bba1c2ee09 ] The dev->dev_private might not be allocated if virtio_gpu_pci_quirk() or virtio_gpu_init() failed. In this case, we should avoid the cleanup in virtio_gpu_release(). Signed-off-by: Xie Yongji Link:

[PATCH AUTOSEL 5.10 061/137] virtio_net: Remove BUG() to avoid machine dead

2021-07-06 Thread Sasha Levin
From: Xianting Tian [ Upstream commit 85eb1389458d134bdb75dad502cc026c3753a619 ] We should not directly BUG() when there is hdr error, it is better to output a print when such error happens. Currently, the caller of xmit_skb() already did it. Signed-off-by: Xianting Tian Reviewed-by: Leon

[PATCH AUTOSEL 5.10 046/137] virtio-net: Add validation for used length

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit ad993a95c508417acdeb15244109e009e50d8758 ] This adds validation for used length (might come from an untrusted device) to avoid data corruption or loss. Signed-off-by: Xie Yongji Acked-by: Jason Wang Link:

[PATCH AUTOSEL 5.10 022/137] drm/virtio: Fix double free on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit cec7f1774605a5ef47c134af62afe7c75c30b0ee ] The virtio_gpu_init() will free vgdev and vgdev->vbufs on failure. But such failure will be caught by virtio_gpu_probe() and then virtio_gpu_release() will be called to do some cleanup which will free vgdev and

[PATCH AUTOSEL 5.10 021/137] drm/virtio: Fixes a potential NULL pointer dereference on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit 17f46f488a5d82c5568e6e786cd760bba1c2ee09 ] The dev->dev_private might not be allocated if virtio_gpu_pci_quirk() or virtio_gpu_init() failed. In this case, we should avoid the cleanup in virtio_gpu_release(). Signed-off-by: Xie Yongji Link:

[PATCH AUTOSEL 5.12 069/160] virtio_net: Remove BUG() to avoid machine dead

2021-07-06 Thread Sasha Levin
From: Xianting Tian [ Upstream commit 85eb1389458d134bdb75dad502cc026c3753a619 ] We should not directly BUG() when there is hdr error, it is better to output a print when such error happens. Currently, the caller of xmit_skb() already did it. Signed-off-by: Xianting Tian Reviewed-by: Leon

[PATCH AUTOSEL 5.12 051/160] virtio-net: Add validation for used length

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit ad993a95c508417acdeb15244109e009e50d8758 ] This adds validation for used length (might come from an untrusted device) to avoid data corruption or loss. Signed-off-by: Xie Yongji Acked-by: Jason Wang Link:

[PATCH AUTOSEL 5.12 024/160] drm/virtio: Fixes a potential NULL pointer dereference on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit 17f46f488a5d82c5568e6e786cd760bba1c2ee09 ] The dev->dev_private might not be allocated if virtio_gpu_pci_quirk() or virtio_gpu_init() failed. In this case, we should avoid the cleanup in virtio_gpu_release(). Signed-off-by: Xie Yongji Link:

[PATCH AUTOSEL 5.12 025/160] drm/virtio: Fix double free on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit cec7f1774605a5ef47c134af62afe7c75c30b0ee ] The virtio_gpu_init() will free vgdev and vgdev->vbufs on failure. But such failure will be caught by virtio_gpu_probe() and then virtio_gpu_release() will be called to do some cleanup which will free vgdev and

Re: [PATCH] bus: Make remove callback return void

2021-07-06 Thread Cornelia Huck
On Tue, Jul 06 2021, Cornelia Huck wrote: > On Tue, Jul 06 2021, Uwe Kleine-König wrote: > >> The driver core ignores the return value of this callback because there >> is only little it can do when a device disappears. >> >> This is the final bit of a long lasting cleanup quest where several

[PATCH AUTOSEL 5.13 082/189] virtio_net: Remove BUG() to avoid machine dead

2021-07-06 Thread Sasha Levin
From: Xianting Tian [ Upstream commit 85eb1389458d134bdb75dad502cc026c3753a619 ] We should not directly BUG() when there is hdr error, it is better to output a print when such error happens. Currently, the caller of xmit_skb() already did it. Signed-off-by: Xianting Tian Reviewed-by: Leon

[PATCH AUTOSEL 5.13 062/189] virtio-net: Add validation for used length

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit ad993a95c508417acdeb15244109e009e50d8758 ] This adds validation for used length (might come from an untrusted device) to avoid data corruption or loss. Signed-off-by: Xie Yongji Acked-by: Jason Wang Link:

[PATCH AUTOSEL 5.13 031/189] drm/virtio: Fix double free on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit cec7f1774605a5ef47c134af62afe7c75c30b0ee ] The virtio_gpu_init() will free vgdev and vgdev->vbufs on failure. But such failure will be caught by virtio_gpu_probe() and then virtio_gpu_release() will be called to do some cleanup which will free vgdev and

[PATCH AUTOSEL 5.13 030/189] drm/virtio: Fixes a potential NULL pointer dereference on probe failure

2021-07-06 Thread Sasha Levin
From: Xie Yongji [ Upstream commit 17f46f488a5d82c5568e6e786cd760bba1c2ee09 ] The dev->dev_private might not be allocated if virtio_gpu_pci_quirk() or virtio_gpu_init() failed. In this case, we should avoid the cleanup in virtio_gpu_release(). Signed-off-by: Xie Yongji Link:

Re: [PATCH] bus: Make remove callback return void

2021-07-06 Thread Cornelia Huck
On Tue, Jul 06 2021, Uwe Kleine-König wrote: > The driver core ignores the return value of this callback because there > is only little it can do when a device disappears. > > This is the final bit of a long lasting cleanup quest where several > buses were converted to also return void from

Re: [PATCH] bus: Make remove callback return void

2021-07-06 Thread Juergen Gross via Virtualization
On 06.07.21 11:50, Uwe Kleine-König wrote: The driver core ignores the return value of this callback because there is only little it can do when a device disappears. This is the final bit of a long lasting cleanup quest where several buses were converted to also return void from their remove

Re: [PATCH] bus: Make remove callback return void

2021-07-06 Thread Alexandre Belloni
On 06/07/2021 11:50:37+0200, Uwe Kleine-König wrote: > The driver core ignores the return value of this callback because there > is only little it can do when a device disappears. > > This is the final bit of a long lasting cleanup quest where several > buses were converted to also return void

Re: [PATCH v8 10/10] Documentation: Add documentation for VDUSE

2021-07-06 Thread Stefan Hajnoczi
On Tue, Jul 06, 2021 at 11:04:18AM +0800, Yongji Xie wrote: > On Mon, Jul 5, 2021 at 8:50 PM Stefan Hajnoczi wrote: > > > > On Mon, Jul 05, 2021 at 11:36:15AM +0800, Jason Wang wrote: > > > > > > 在 2021/7/4 下午5:49, Yongji Xie 写道: > > > > > > OK, I get you now. Since the VIRTIO specification says

Re: [PATCH] bus: Make remove callback return void

2021-07-06 Thread Mark Brown
On Tue, Jul 06, 2021 at 11:50:37AM +0200, Uwe Kleine-König wrote: > The driver core ignores the return value of this callback because there > is only little it can do when a device disappears. Acked-by: Mark Brown signature.asc Description: PGP signature

Re: [PATCH v8 10/10] Documentation: Add documentation for VDUSE

2021-07-06 Thread Stefan Hajnoczi
On Tue, Jul 06, 2021 at 10:34:33AM +0800, Jason Wang wrote: > > 在 2021/7/5 下午8:49, Stefan Hajnoczi 写道: > > On Mon, Jul 05, 2021 at 11:36:15AM +0800, Jason Wang wrote: > > > 在 2021/7/4 下午5:49, Yongji Xie 写道: > > > > > > OK, I get you now. Since the VIRTIO specification says "Device > > > > > >

Re: [PATCH] bus: Make remove callback return void

2021-07-06 Thread Russell King (Oracle)
On Tue, Jul 06, 2021 at 11:50:37AM +0200, Uwe Kleine-König wrote: > The driver core ignores the return value of this callback because there > is only little it can do when a device disappears. > > This is the final bit of a long lasting cleanup quest where several > buses were converted to also

Re: [PATCH V2 5/6] virtio: add one field into virtio_device for recording if device uses managed irq

2021-07-06 Thread Ming Lei
On Tue, Jul 06, 2021 at 07:42:03AM +0200, Christoph Hellwig wrote: > On Fri, Jul 02, 2021 at 11:05:54PM +0800, Ming Lei wrote: > > blk-mq needs to know if the device uses managed irq, so add one field > > to virtio_device for recording if device uses managed irq. > > > > If the driver use managed

[PATCH] drm/qxl: Convert to Linux IRQ interfaces

2021-07-06 Thread Thomas Zimmermann
Drop the DRM IRQ midlayer in favor of Linux IRQ interfaces. DRM's IRQ helpers are mostly useful for UMS drivers. Modern KMS drivers don't benefit from using it. Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/qxl/qxl_drv.c | 1 - drivers/gpu/drm/qxl/qxl_drv.h | 1 -