Re: [PATCH v4 12/15] vdpa: block migration if device has unsupported features

2023-02-27 Thread Jason Wang
在 2023/2/24 23:54, Eugenio Pérez 写道: A vdpa net device must initialize with SVQ in order to be migratable at this moment, and initialization code verifies some conditions. If the device is not initialized with the x-svq parameter, it will not expose _F_LOG so the vhost subsystem will block VM

Re: [PATCH v4 12/15] vdpa: block migration if device has unsupported features

2023-02-27 Thread Jason Wang
On Mon, Feb 27, 2023 at 4:15 PM Jason Wang wrote: > > > 在 2023/2/24 23:54, Eugenio Pérez 写道: > > A vdpa net device must initialize with SVQ in order to be migratable at > > this moment, and initialization code verifies some conditions. If the > > device is not initialized with the x-svq

Re: [PATCH v4 10/15] vdpa: disable RAM block discard only for the first device

2023-02-27 Thread Jason Wang
在 2023/2/24 23:54, Eugenio Pérez 写道: Although it does not make a big difference, its more correct and simplifies the cleanup path in subsequent patches. Move ram_block_discard_disable(false) call to the top of vhost_vdpa_cleanup because: * We cannot use vhost_vdpa_first_dev after dev->opaque =

Re: [PATCH v11 05/10] drm/shmem-helper: Add memory shrinker

2023-02-27 Thread kernel test robot
Hi Dmitry, I love your patch! Yet something to improve: [auto build test ERROR on drm-misc/drm-misc-next] [cannot apply to drm/drm-next drm-intel/for-linux-next drm-intel/for-linux-next-fixes drm-tip/drm-tip linus/master v6.2 next-20230227] [If your patch is applied to the wrong git tree

Re: [PATCH v4 09/15] vdpa: add vdpa net migration state notifier

2023-02-27 Thread Jason Wang
在 2023/2/24 23:54, Eugenio Pérez 写道: This allows net to restart the device backend to configure SVQ on it. Ideally, these changes should not be net specific. However, the vdpa net backend is the one with enough knowledge to configure everything because of some reasons: * Queues might need to

Re: [PATCH v4 11/15] vdpa net: block migration if the device has CVQ

2023-02-27 Thread Jason Wang
在 2023/2/24 23:54, Eugenio Pérez 写道: Devices with CVQ needs to migrate state beyond vq state. Leaving this to future series. Signed-off-by: Eugenio Pérez --- v3: Migration blocker is registered in vhost_dev. --- include/hw/virtio/vhost-vdpa.h | 1 + hw/virtio/vhost-vdpa.c | 1 +

Re: [PATCH v4 00/15] Dynamically switch to vhost shadow virtqueues at vdpa net migration

2023-02-27 Thread Alvaro Karsz
> > It's possible to migrate vdpa net devices if they are shadowed from the > start. But to always shadow the dataplane is to effectively break its host > passthrough, so its not efficient in vDPA scenarios. > > This series enables dynamically switching to shadow mode only at > migration time.

Re: [PATCH v11 05/10] drm/shmem-helper: Add memory shrinker

2023-02-27 Thread kernel test robot
Hi Dmitry, I love your patch! Perhaps something to improve: [auto build test WARNING on drm-misc/drm-misc-next] [cannot apply to drm/drm-next drm-intel/for-linux-next drm-intel/for-linux-next-fixes drm-tip/drm-tip linus/master v6.2 next-20230227] [If your patch is applied to the wrong git tree

Re: [PATCH v10 00/11] Add generic memory shrinker to VirtIO-GPU and Panfrost DRM drivers

2023-02-27 Thread Jani Nikula
On Mon, 27 Feb 2023, Dmitry Osipenko wrote: > On 2/17/23 16:41, Dmitry Osipenko wrote: >> On 2/17/23 16:28, Thomas Zimmermann wrote: >>> Hi, >>> >>> I looked through the series. Most of the patches should have an r-b or >>> a-b at this point. I can't say much about patch 2 and had questions >>>

Re: [PATCH] vhost: use struct_size and size_add to compute flex array sizes

2023-02-27 Thread Michael S. Tsirkin
On Mon, Feb 27, 2023 at 01:41:27PM -0800, Jacob Keller wrote: > The vhost_get_avail_size and vhost_get_used_size functions compute the size > of structures with flexible array members with an additional 2 bytes if the > VIRTIO_RING_F_EVENT_IDX feature flag is set. Convert these functions to use >

Re: [PATCH v4 2/2] vdpasim: support doorbell mapping

2023-02-27 Thread kernel test robot
in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Longpeng-Mike/vdpa-support-specify-the-pgprot-of-vq-notification-area/20230227-172516 patch link: https://lore.kernel.org/r/20230227091857.2406-3-longpeng2%40huawei.com

[PATCH] vhost: use struct_size and size_add to compute flex array sizes

2023-02-27 Thread Jacob Keller
The vhost_get_avail_size and vhost_get_used_size functions compute the size of structures with flexible array members with an additional 2 bytes if the VIRTIO_RING_F_EVENT_IDX feature flag is set. Convert these functions to use struct_size() and size_add() instead of coding the calculation by

Re: [PATCH] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Gerd Hoffmann
On Mon, Feb 27, 2023 at 07:40:11AM -0800, Rob Clark wrote: > On Sun, Feb 26, 2023 at 10:38 PM Gerd Hoffmann wrote: > > > > On Fri, Feb 24, 2023 at 10:02:24AM -0800, Rob Clark wrote: > > > From: Rob Clark > > > > > > Add a build option to disable modesetting support. This is useful in > > >

[RFC][PATCH] splice: Prevent gifting of multipage folios

2023-02-27 Thread David Howells
Don't let parts of multipage folios be gifted by (vm)splice into a pipe as the other end may only be expecting single-page gifts (fuse and virtio console for example). replace_page_cache_folio(), for example, will do the wrong thing if it tries to replace a single paged folio with a

Re: [RFC][PATCH] splice: Prevent gifting of multipage folios

2023-02-27 Thread Matthew Wilcox
On Mon, Feb 27, 2023 at 02:23:32PM +, David Howells wrote: > > Don't let parts of multipage folios be gifted by (vm)splice into a pipe as > the other end may only be expecting single-page gifts (fuse and virtio > console for example). > > replace_page_cache_folio(), for example, will do

Re: [RFC][PATCH] splice: Prevent gifting of multipage folios

2023-02-27 Thread David Howells
Matthew Wilcox wrote: > What should the Fixes: here be? This was already possible with THPs > (both anon and tmpfs backed) long before I introduced folios. Good question. How do I tell when THPs were introduced? It looks like they might predate git, looking at free_compound_page()'s comment.

[PATCH v3] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Rob Clark
From: Rob Clark Add a build option to disable modesetting support. This is useful in cases where the guest only needs to use the GPU in a headless mode, or (such as in the CrOS usage) window surfaces are proxied to a host compositor. v2: Use more if (IS_ENABLED(...)) v3: Also permit the host

Re: [RESEND v2 PATCH] init/do_mounts.c: add virtiofs root fs support

2023-02-27 Thread Vivek Goyal
On Mon, Feb 27, 2023 at 10:53:45AM -0500, Stefan Hajnoczi wrote: > On Fri, Feb 24, 2023 at 03:37:51PM +0100, David Heidelberg wrote: > > From: Stefan Hajnoczi > > > > Make it possible to boot directly from a virtiofs file system with tag > > 'myfs' using the following kernel parameters: > > > >

Re: [PATCH v3] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Rob Clark
On Mon, Feb 27, 2023 at 9:57 AM Dmitry Osipenko wrote: > > On 2/27/23 20:38, Rob Clark wrote: > ... > > + if (IS_ENABLED(CONFIG_DRM_VIRTIO_GPU_KMS)) { > > + /* get display info */ > > + virtio_cread_le(vgdev->vdev, struct virtio_gpu_config, > > +

Re: [PATCH v2] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Rob Clark
On Mon, Feb 27, 2023 at 8:16 AM Daniel Vetter wrote: > > On Mon, Feb 27, 2023 at 08:01:13AM -0800, Rob Clark wrote: > > From: Rob Clark > > > > Add a build option to disable modesetting support. This is useful in > > cases where the guest only needs to use the GPU in a headless mode, or > >

Re: [PATCH] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Rob Clark
On Sun, Feb 26, 2023 at 10:38 PM Gerd Hoffmann wrote: > > On Fri, Feb 24, 2023 at 10:02:24AM -0800, Rob Clark wrote: > > From: Rob Clark > > > > Add a build option to disable modesetting support. This is useful in > > cases where the guest only needs to use the GPU in a headless mode, or > >

Re: [PATCH v4 2/2] vdpasim: support doorbell mapping

2023-02-27 Thread kernel test robot
Hi Longpeng(Mike), Thank you for the patch! Yet something to improve: [auto build test ERROR on v6.2] [also build test ERROR on next-20230227] [cannot apply to mst-vhost/linux-next linus/master] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we

[RFC][PATCH v2] splice: Prevent gifting of multipage folios

2023-02-27 Thread David Howells
Don't let parts of compound pages/multipage folios be gifted by (vm)splice into a pipe as the other end may only be expecting single-page gifts (fuse and virtio console for example). replace_page_cache_folio(), for example, will do the wrong thing if it tries to replace a single paged folio

[PATCH v2] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Rob Clark
From: Rob Clark Add a build option to disable modesetting support. This is useful in cases where the guest only needs to use the GPU in a headless mode, or (such as in the CrOS usage) window surfaces are proxied to a host compositor. v2: Use more if (IS_ENABLED(...)) Signed-off-by: Rob Clark

Re: [PATCH] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Ville Syrjälä
On Mon, Feb 27, 2023 at 07:40:11AM -0800, Rob Clark wrote: > On Sun, Feb 26, 2023 at 10:38 PM Gerd Hoffmann wrote: > > > > On Fri, Feb 24, 2023 at 10:02:24AM -0800, Rob Clark wrote: > > > From: Rob Clark > > > > > > Add a build option to disable modesetting support. This is useful in > > >

Re: [RFC][PATCH v2] splice: Prevent gifting of multipage folios

2023-02-27 Thread Matthew Wilcox
On Mon, Feb 27, 2023 at 03:51:03PM +, David Howells wrote: > > Don't let parts of compound pages/multipage folios be gifted by (vm)splice > into a pipe as the other end may only be expecting single-page gifts (fuse > and virtio console for example). > > replace_page_cache_folio(), for

Re: [RESEND v2 PATCH] init/do_mounts.c: add virtiofs root fs support

2023-02-27 Thread Stefan Hajnoczi
On Fri, Feb 24, 2023 at 03:37:51PM +0100, David Heidelberg wrote: > From: Stefan Hajnoczi > > Make it possible to boot directly from a virtiofs file system with tag > 'myfs' using the following kernel parameters: > > rootfstype=virtiofs root=myfs rw > > Booting directly from virtiofs makes

Re: [PATCH v4 2/2] vdpasim: support doorbell mapping

2023-02-27 Thread kernel test robot
in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Longpeng-Mike/vdpa-support-specify-the-pgprot-of-vq-notification-area/20230227-172516 patch link: https://lore.kernel.org/r/20230227091857.2406-3-longpeng2%40huawei.com

Re: [PATCH v2] drm/virtio: Add option to disable KMS support

2023-02-27 Thread Daniel Vetter
On Mon, Feb 27, 2023 at 08:01:13AM -0800, Rob Clark wrote: > From: Rob Clark > > Add a build option to disable modesetting support. This is useful in > cases where the guest only needs to use the GPU in a headless mode, or > (such as in the CrOS usage) window surfaces are proxied to a host >