[GIT PULL] virtio: features, fixes, cleanups

2025-01-27 Thread Michael S. Tsirkin
compliance virtio-mem now works with kdump on s390 Small cleanups all over the place. Signed-off-by: Michael S. Tsirkin Akihiko Odaki (1): vhost/net: Set num_buffers for virtio 1.0 David Hildenbrand (12): fs/proc/vmcore

Re: [PATCH v4 7/8] vhost: Add new UAPI to support change to task mode

2025-01-21 Thread Michael S. Tsirkin
On Wed, Jan 22, 2025 at 10:07:19AM +0800, Cindy Lu wrote: > Ping for review, Hi MST and Jason, do you have any comments on this? > Thanks > Cindy I see there are unaddressed comments by Jason and Stefano.

Re: [PATCH v4] vdpa: solidrun: Replace deprecated PCI functions

2025-01-20 Thread Michael S. Tsirkin
On Mon, Jan 20, 2025 at 10:13:03AM +0100, Philipp Stanner wrote: > On Thu, 2024-12-19 at 10:51 +0100, Stefano Garzarella wrote: > > On Thu, Dec 19, 2024 at 10:44:29AM +0100, Philipp Stanner wrote: > > > From: Philipp Stanner > > > > > > The PCI functions > > > > > > pcim_iomap_regions() > > >

Re: [PATCH] vhost/scsi: Fix improper cleanup in vhost_scsi_set_endpoint()

2025-01-14 Thread Michael S. Tsirkin
On Sun, Jan 12, 2025 at 03:19:44PM -0600, Mike Christie wrote: > On 1/12/25 11:35 AM, michael.chris...@oracle.com wrote: > > So I think to fix the issue, we would want to: > > > > 1. move the > > > > memcpy(vs_tpg, vs->vs_tpg, len); > > > > to the end of the function after we do the vhost_scsi_f

Re: [PATCH] virtio_ring: skip cpu sync when mapping fails

2025-01-10 Thread Michael S. Tsirkin
On Fri, Jan 10, 2025 at 11:32:46AM +0800, Jason Wang wrote: > On Wed, Jan 8, 2025 at 7:35 PM Michael S. Tsirkin wrote: > > > > On Mon, Nov 11, 2024 at 10:55:38AM +0800, Jason Wang wrote: > > > There's no need to sync DMA for CPU on mapping errors. So this patch &g

Re: [PATCH net 1/2] vsock/virtio: discard packets if the transport changes

2025-01-09 Thread Michael S. Tsirkin
On Thu, Jan 09, 2025 at 10:01:31AM +0100, Stefano Garzarella wrote: > On Wed, Jan 08, 2025 at 02:31:19PM -0500, Hyunwoo Kim wrote: > > On Wed, Jan 08, 2025 at 07:06:16PM +0100, Stefano Garzarella wrote: > > > If the socket has been de-assigned or assigned to another transport, > > > we must discard

Re: [PATCH net 2/2] vsock/bpf: return early if transport is not assigned

2025-01-09 Thread Michael S. Tsirkin
110b4 ("vsock: support sockmap") > Reported-by: Michal Luczaj > Closes: > https://lore.kernel.org/netdev/5ca20d4c-1017-49c2-9516-f6f75fd33...@rbox.co/ > Signed-off-by: Stefano Garzarella Acked-by: Michael S. Tsirkin > --- > net/vmw_vsock/vsock_bpf.c | 9 + >

Re: [PATCH v5 0/6] vhost: Add support of kthread API

2025-01-08 Thread Michael S. Tsirkin
On Mon, Dec 30, 2024 at 08:43:47PM +0800, Cindy Lu wrote: > In commit 6e890c5d5021 ("vhost: use vhost_tasks for worker threads"), > the vhost now uses vhost_task and operates as a child of the > owner thread. This aligns with containerization principles. > However, this change has caused c

Re: [PATCH v5 5/6] vhost: Add new UAPI to support change to task mode

2025-01-08 Thread Michael S. Tsirkin
On Thu, Jan 02, 2025 at 11:36:58AM +0800, Jason Wang wrote: > On Mon, Dec 30, 2024 at 8:45 PM Cindy Lu wrote: > > > > Add a new UAPI to enable setting the vhost device to task mode. > > The userspace application can use VHOST_SET_INHERIT_FROM_OWNER > > to configure the mode if necessary. > > This

Re: [PATCH v5 5/6] vhost: Add new UAPI to support change to task mode

2025-01-08 Thread Michael S. Tsirkin
On Mon, Dec 30, 2024 at 08:43:52PM +0800, Cindy Lu wrote: > Add a new UAPI to enable setting the vhost device to task mode. > The userspace application can use VHOST_SET_INHERIT_FROM_OWNER > to configure the mode if necessary. > This setting must be applied before VHOST_SET_OWNER, as the worker > w

Re: [PATCH v4 7/8] vhost: Add new UAPI to support change to task mode

2025-01-08 Thread Michael S. Tsirkin
On Wed, Dec 11, 2024 at 12:41:46AM +0800, Cindy Lu wrote: > Add a new UAPI to enable setting the vhost device to task mode. > The userspace application can use VHOST_SET_INHERIT_FROM_OWNER > to configure the mode if necessary. > This setting must be applied before VHOST_SET_OWNER, as the worker > w

Re: [PATCH v2] vdpa/vp_vdpa: implement kick_vq_with_data callback

2025-01-08 Thread Michael S. Tsirkin
On Tue, Dec 03, 2024 at 10:37:43AM +0800, Yuxue Liu yuxue@jaguarmicro.com wrote: > From: Yuxue Liu > > Implement the kick_vq_with_data vDPA callback. > On kick, we pass the next available data to the hardware by writing it in > the kick offset. > > Signed-off-by: Yuxue Liu Pls do not send

Re: [PATCH] virtio_ring: skip cpu sync when mapping fails

2025-01-08 Thread Michael S. Tsirkin
On Mon, Nov 11, 2024 at 10:55:38AM +0800, Jason Wang wrote: > There's no need to sync DMA for CPU on mapping errors. So this patch > skips the CPU sync in the error handling path of DMA mapping. > > Signed-off-by: Jason Wang So as I said, I do not get why we are optimizing error paths. The comm

Re: [PATCH] vhost/net: Set num_buffers for virtio 1.0

2024-12-27 Thread Michael S. Tsirkin
On Fri, Dec 27, 2024 at 01:34:10PM +0900, Akihiko Odaki wrote: > On 2024/12/27 10:29, Jason Wang wrote: > > > > > > On Thu, Dec 26, 2024 at 7:54 PM Michael S. Tsirkin > <mailto:m...@redhat.com>> wrote: > > > > On Mon, Nov 11, 2024 at 09:27:45

Re: [PATCH] vhost/net: Set num_buffers for virtio 1.0

2024-12-26 Thread Michael S. Tsirkin
On Mon, Nov 11, 2024 at 09:27:45AM +0800, Jason Wang wrote: > On Wed, Nov 6, 2024 at 4:54 PM Michael S. Tsirkin wrote: > > > > On Sun, Sep 15, 2024 at 10:35:53AM +0900, Akihiko Odaki wrote: > > > The specification says the device MUST set num_buffers to 1 if > > &g

Re: [PATCH v2] virtio: fix reference leak in register_virtio_device()

2024-12-18 Thread Michael S. Tsirkin
On Wed, Dec 18, 2024 at 11:12:01AM +0800, Ma Ke wrote: > Once device_add(&dev->dev) failed, call put_device() to explicitly > release dev->dev. Or it could cause double free problem. > > As comment of device_add() says, 'if device_add() succeeds, you should > call device_del() when you want to get

Re: [PATCH v3 4/4] vdpa/octeon_ep: read vendor-specific PCI capability

2024-12-13 Thread Michael S. Tsirkin
On Fri, Dec 13, 2024 at 02:20:24PM +, Shijith Thotton wrote: > >>> > >>> Added support to read the vendor-specific PCI capability to identify the > >>> type of device being emulated. > >>> > >>> Reviewed-by: Dan Carpenter > >>> Signed-off-by: Shijith Thotton > >>> --- > >>> drivers/vdpa/octe

Re: [PATCH net v4 0/6] virtio_net: correct netdev_tx_reset_queue() invocation points

2024-12-11 Thread Michael S. Tsirkin
all > netdev_tx_reset_queue() when virtqueue_reset() has actually recycled > unused buffers. thanks Acked-by: Michael S. Tsirkin > This patch series consists of six commits: > [1/6]: Resolves (a) and (b). # also -stable 6.11.y > [2/6]: Minor

Re: [PATCH net-next v3 1/7] virtio_net: correct netdev_tx_reset_queue() invocation point

2024-12-05 Thread Michael S. Tsirkin
On Thu, Dec 05, 2024 at 10:16:35PM +0900, Koichiro Den wrote: > On Thu, Dec 05, 2024 at 09:43:38PM +0900, Koichiro Den wrote: > > On Thu, Dec 05, 2024 at 05:33:36AM -0500, Michael S. Tsirkin wrote: > > > On Wed, Dec 04, 2024 at 02:07:18PM +0900, Koichiro Den wrote: > > &

Re: [PATCH net-next v3 1/7] virtio_net: correct netdev_tx_reset_queue() invocation point

2024-12-05 Thread Michael S. Tsirkin
On Thu, Dec 05, 2024 at 10:16:35PM +0900, Koichiro Den wrote: > On Thu, Dec 05, 2024 at 09:43:38PM +0900, Koichiro Den wrote: > > On Thu, Dec 05, 2024 at 05:33:36AM -0500, Michael S. Tsirkin wrote: > > > On Wed, Dec 04, 2024 at 02:07:18PM +0900, Koichiro Den wrote: > > &

Re: [PATCH net-next v3 0/7] virtio_net: correct netdev_tx_reset_queue() invocation points

2024-12-05 Thread Michael S. Tsirkin
On Wed, Dec 04, 2024 at 02:07:17PM +0900, Koichiro Den wrote: > When virtnet_close is followed by virtnet_open, some TX completions can > possibly remain unconsumed, until they are finally processed during the > first NAPI poll after the netdev_tx_reset_queue(), resulting in a crash > [1]. Commit b

Re: [PATCH net-next v3 3/7] virtio_net: introduce virtnet_sq_free_unused_buf_done()

2024-12-05 Thread Michael S. Tsirkin
On Wed, Dec 04, 2024 at 02:07:20PM +0900, Koichiro Den wrote: > This will be used in the following commits, to ensure DQL reset occurs > iff. all unused buffers are actually recycled. > > Cc: # v6.11+ > Signed-off-by: Koichiro Den to avoid adding an unused function, squash with a patch that use

Re: [PATCH net-next v3 2/7] virtio_net: replace vq2rxq with vq2txq where appropriate

2024-12-05 Thread Michael S. Tsirkin
ffer") > Signed-off-by: Koichiro Den Acked-by: Michael S. Tsirkin > --- > drivers/net/virtio_net.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c > index 48ce8b3881b6..1b7a85e75e14 100644 >

Re: [PATCH net-next v3 1/7] virtio_net: correct netdev_tx_reset_queue() invocation point

2024-12-05 Thread Michael S. Tsirkin
On Wed, Dec 04, 2024 at 02:07:18PM +0900, Koichiro Den wrote: > When virtnet_close is followed by virtnet_open, some TX completions can > possibly remain unconsumed, until they are finally processed during the > first NAPI poll after the netdev_tx_reset_queue(), resulting in a crash > [1]. So it'

Re: drivers/virtio/virtio_ring.c:1162:11: error: 'struct vring_virtqueue' has no member named 'premapped'

2024-11-27 Thread Michael S. Tsirkin
On Wed, Nov 27, 2024 at 01:30:59PM +0530, Naresh Kamboju wrote: > The following build errors were noticed for arm64, arm, x86_64 and riscv. > > First seen on Sasha Linus-next 441d2975754ad94f3ce2e29f672824bc2dc5120c. > Good: 07e98e730a08081b6d0b5c3a173b0487c36ed27f > Bad: 441d2975754ad94f3ce2

Re: [GIT PULL] virtio: features, fixes, cleanups

2024-11-27 Thread Michael S. Tsirkin
On Tue, Nov 26, 2024 at 04:31:51PM -0500, Michael S. Tsirkin wrote: > > I was hoping to get vhost threading compat fixes in but no luck. > A very quiet merge cycle - I guess it's a sign we got a lot merged > last time, and everyone is busy testing. Right, guys? You will get a me

[GIT PULL] virtio: features, fixes, cleanups

2024-11-26 Thread Michael S. Tsirkin
12 18:07:46 -0500) virtio: features, fixes, cleanups A small number of improvements all over the place. Signed-off-by: Michael S. Tsirkin Colin Ian Ki

Re: [PATCH vhost 2/2] vdpa/mlx5: Fix suboptimal range on iotlb iteration

2024-11-13 Thread Michael S. Tsirkin
On Wed, Nov 13, 2024 at 04:01:05PM +0100, Dragos Tatulea wrote: > > > On 13.11.24 15:49, Michael S. Tsirkin wrote: > > On Wed, Nov 13, 2024 at 03:33:35PM +0100, Dragos Tatulea wrote: > >> > >> > >> On 13.11.24 07:32, Michael S. Tsirkin wrote: >

Re: [PATCH vhost 2/2] vdpa/mlx5: Fix suboptimal range on iotlb iteration

2024-11-13 Thread Michael S. Tsirkin
On Wed, Nov 13, 2024 at 03:33:35PM +0100, Dragos Tatulea wrote: > > > On 13.11.24 07:32, Michael S. Tsirkin wrote: > > On Mon, Oct 21, 2024 at 04:40:40PM +0300, Dragos Tatulea wrote: > >> From: Si-Wei Liu > >> > >> The starting iova address to iterate i

Re: [PATCH vhost 0/2] vdpa/mlx5: Iova mapping related fixes

2024-11-12 Thread Michael S. Tsirkin
On Wed, Nov 13, 2024 at 09:45:22AM +0800, Jason Wang wrote: > On Mon, Nov 11, 2024 at 4:58 PM Dragos Tatulea wrote: > > > > > > > > On 21.10.24 15:40, Dragos Tatulea wrote: > > > Here are 2 fixes from Si-Wei: > > > - The first one is an important fix that has to be applied as far > > > back as p

Re: [PATCH vhost 2/2] vdpa/mlx5: Fix suboptimal range on iotlb iteration

2024-11-12 Thread Michael S. Tsirkin
On Mon, Oct 21, 2024 at 04:40:40PM +0300, Dragos Tatulea wrote: > From: Si-Wei Liu > > The starting iova address to iterate iotlb map entry within a range > was set to an irrelevant value when passing to the itree_next() > iterator, although luckily it doesn't affect the outcome of finding > out

Re: [PATCH] vdpa: vdpa_sim: vdpa_sim_net: fixed cofing style issues

2024-11-12 Thread Michael S. Tsirkin
On Thu, Nov 07, 2024 at 09:19:41PM +0200, Gediminas Repecka wrote: > Fixed coding style issues reported by checkpatch script > --- A lot is wrong with this submission, given it's supposed to fix checkpatch: - no signature - typo in subject - not using direct voice (Fix, not Fixed) pls fix and

[GIT PULL] virtio: bugfix

2024-11-12 Thread Michael S. Tsirkin
up to 29ce8b8a4fa74e841342c8b8f8941848a3c6f29f: vdpa/mlx5: Fix PA offset with unaligned starting iotlb map (2024-11-12 18:05:04 -0500) virtio: bugfix A last minute mlx5 bugfix Signed-off-by: Michael S. Tsirkin

Re: [PATCH] virtio_ring: skip cpu sync when mapping fails

2024-11-12 Thread Michael S. Tsirkin
On Mon, Nov 11, 2024 at 04:36:52PM +0800, Jason Wang wrote: > On Mon, Nov 11, 2024 at 3:30 PM Michael S. Tsirkin wrote: > > > > On Mon, Nov 11, 2024 at 10:55:38AM +0800, Jason Wang wrote: > > > There's no need to sync DMA for CPU on mapping errors. So this patch &g

[GIT PULL] virtio: bugfixes

2024-11-11 Thread Michael S. Tsirkin
83e445e64f48bdae3f25013e788fcf592f142576: vdpa/mlx5: Fix error path during device add (2024-11-07 16:51:16 -0500) virtio: bugfixes Several small bugfixes all over the place. Signed-off-by: Michael S. Tsirkin

Re: [PATCH] virtio_ring: skip cpu sync when mapping fails

2024-11-10 Thread Michael S. Tsirkin
On Mon, Nov 11, 2024 at 10:55:38AM +0800, Jason Wang wrote: > There's no need to sync DMA for CPU on mapping errors. So this patch > skips the CPU sync in the error handling path of DMA mapping. > > Signed-off-by: Jason Wang DMA sync is idempotent. Extra work for slow path. Why do we bother? >

Re: [PATCH v3 1/2] vdpa/mlx5: Set speed and duplex of vDPA devices to UNKNOWN

2024-11-08 Thread Michael S. Tsirkin
On Fri, Nov 08, 2024 at 10:31:58AM +0100, Dragos Tatulea wrote: > > > On 07.11.24 22:50, Michael S. Tsirkin wrote: > > On Wed, Sep 04, 2024 at 10:11:14AM -0500, Carlos Bilbao wrote: > >> From: Carlos Bilbao > >> > >> Initialize the speed and dup

Re: [PATCH v3 1/2] vdpa/mlx5: Set speed and duplex of vDPA devices to UNKNOWN

2024-11-07 Thread Michael S. Tsirkin
On Wed, Sep 04, 2024 at 10:11:14AM -0500, Carlos Bilbao wrote: > From: Carlos Bilbao > > Initialize the speed and duplex fields in virtio_net_config to UNKNOWN. > This is needed because mlx5_vdpa vDPA devices currently do not support the > VIRTIO_NET_F_SPEED_DUPLEX feature which reports speed and

Re: [PATCH] virtio-pci: Add MSI support

2024-11-06 Thread Michael S. Tsirkin
On Fri, Jul 12, 2024 at 07:59:14PM +0530, Manivannan Sadhasivam wrote: > Virtio spec has so far only supported MSI-X and INTX for receiving the > interrupts from the virtio device on PCI transport. But this becomes a > limiting factor for devices supporting only MSI (plus INTX emulation) as > they

Re: [PATCH net 0/4] virtio_net: Make RSS interact properly with queue number

2024-11-06 Thread Michael S. Tsirkin
hen queue_pairs changes _with_ user rss configuration, keep rss as user > configured > > Patch 1 and 2 fix possible out of bound errors for indir_table and key. > Patch 3 and 4 add RSS update in probe() and set_queues(). > > Please review, thanks. Looks reasonable. Acked-by: M

Re: [PATCH v2] vhost/vsock: specify module version

2024-11-06 Thread Michael S. Tsirkin
On Wed, Oct 02, 2024 at 07:16:02AM -0700, Jakub Kicinski wrote: > On Mon, 30 Sep 2024 19:03:52 +0200 Aleksandr Mikhalitsyn wrote: > > > At this point my question is, should we solve the problem higher and > > > show all the modules in /sys/modules, either way? > > > > Probably, yes. We can ask L

Re: [PATCH] vhost/net: Set num_buffers for virtio 1.0

2024-11-06 Thread Michael S. Tsirkin
On Sun, Sep 15, 2024 at 10:35:53AM +0900, Akihiko Odaki wrote: > The specification says the device MUST set num_buffers to 1 if > VIRTIO_NET_F_MRG_RXBUF has not been negotiated. > > Fixes: 41e3e42108bc ("vhost/net: enable virtio 1.0") > Signed-off-by: Akihiko Odaki True, this is out of spec. But

Re: [PATCH v3 7/9] vhost: Add new UAPI to support change to task mode

2024-11-05 Thread Michael S. Tsirkin
On Tue, Nov 05, 2024 at 03:25:26PM +0800, Cindy Lu wrote: > Add a new UAPI to enable setting the vhost device to task mode. > The userspace application can use VHOST_SET_INHERIT_FROM_OWNER > to configure the mode if necessary. > This setting must be applied before VHOST_SET_OWNER, as the worker > w

Re: [PATCH v3 7/9] vhost: Add new UAPI to support change to task mode

2024-11-05 Thread Michael S. Tsirkin
On Tue, Nov 05, 2024 at 03:25:26PM +0800, Cindy Lu wrote: > index b95dd84eef2d..1e192038633d 100644 > --- a/include/uapi/linux/vhost.h > +++ b/include/uapi/linux/vhost.h > @@ -235,4 +235,6 @@ > */ > #define VHOST_VDPA_GET_VRING_SIZE_IOWR(VHOST_VIRTIO, 0x82, \ >

[PATCH] virtio_net: fix integer overflow in stats

2024-10-16 Thread Michael S. Tsirkin
is read into a u64: u64 offset, bitmap; bitmap = ctx->bitmap[queue_type]; so to fix, it is enough to make bitmap an array of u64. Fixes: 941168f8b40e5 ("virtio_net: support device stats") Reported-by: "Colin King (gmail)" Signed-off-by: Michael S. Tsirkin --- drive

Re: [PATCH v2 7/7] vhost: Add new UAPI to support change to task mode

2024-10-15 Thread Michael S. Tsirkin
On Mon, Oct 14, 2024 at 03:56:33PM -0500, Mike Christie wrote: > On 10/3/24 8:58 PM, Cindy Lu wrote: > > Add a new UAPI to support setting the vhost device to > > use task mode. The user space application needs to use > > VHOST_SET_INHERIT_FROM_OWNER to set the mode. > > This setting must be set be

[GIT PULL] virtio: bugfixes

2024-10-07 Thread Michael S. Tsirkin
notably, fixes the vsock allocation with GFP_KERNEL in atomic context, which has been triggering warnings for lots of testers. Signed-off-by: Michael S. Tsirkin Haoran Zhang (1): vhost/scsi: null-ptr-dereference in

Re: [PATCH] vsock/virtio: use GFP_ATOMIC under RCU read lock

2024-10-07 Thread Michael S. Tsirkin
On Mon, Oct 07, 2024 at 08:39:20AM -0700, Jakub Kicinski wrote: > On Wed, 2 Oct 2024 09:41:42 -0400 Michael S. Tsirkin wrote: > > virtio_transport_send_pkt in now called on transport fast path, > > under RCU read lock. In that case, we have a bug: virtio_add_sgs > > is called

[PATCH] vsock/virtio: use GFP_ATOMIC under RCU read lock

2024-10-02 Thread Michael S. Tsirkin
/hfcr2aget2zojmqpr4uhlzvnep4vgskblx5b6xf2ddosbsrke7@nt34bxgp7j2x Fixes: efcd71af38be ("vsock/virtio: avoid queuing packets when intermediate queue is empty") Reported-by: Christian Brauner Cc: Stefano Garzarella Cc: Luigi Leonardi Signed-off-by: Michael S. Tsirkin --- Lightly tested. Christian, cou

Re: Re: [PATCH] virtio: Make vring_new_virtqueue support for packed vring

2024-10-01 Thread Michael S. Tsirkin
On Tue, Oct 01, 2024 at 05:30:51PM +0800, Wenyu Huang wrote: > It used for testing in tools/virtio/vringh_test.c. > If vring_new_virtqueue supports packed vring, we can add support for > packed vring to vringh and test it. Pls say this in the commit log.

Re: [PATCH v2] vhost/vsock: specify module version

2024-09-30 Thread Michael S. Tsirkin
On Mon, Sep 30, 2024 at 02:28:30PM +0200, Aleksandr Mikhalitsyn wrote: > On Sun, Sep 29, 2024 at 9:03 PM Michael S. Tsirkin wrote: > > > > On Sun, Sep 29, 2024 at 08:21:03PM +0200, Alexander Mikhalitsyn wrote: > > > Add an explicit MODULE_VERSION("0.0.1")

Re: [PATCH v2] vhost/vsock: specify module version

2024-09-29 Thread Michael S. Tsirkin
On Sun, Sep 29, 2024 at 08:21:03PM +0200, Alexander Mikhalitsyn wrote: > Add an explicit MODULE_VERSION("0.0.1") specification for the vhost_vsock > module. > > It is useful because it allows userspace to check if vhost_vsock is there > when it is > configured as a built-in. > > This is what we

Re: [PATCH] vhost/vsock: specify module version

2024-09-29 Thread Michael S. Tsirkin
On Sun, Sep 29, 2024 at 07:35:35PM +0200, Aleksandr Mikhalitsyn wrote: > On Sun, Sep 29, 2024 at 6:56 PM Michael S. Tsirkin wrote: > > > > On Thu, Sep 26, 2024 at 06:16:40PM +0200, Alexander Mikhalitsyn wrote: > > > Add an explicit MODULE_VERSION("0.0.1") spe

Re: [PATCH] vhost/vsock: specify module version

2024-09-29 Thread Michael S. Tsirkin
On Sun, Sep 29, 2024 at 07:35:35PM +0200, Aleksandr Mikhalitsyn wrote: > On Sun, Sep 29, 2024 at 6:56 PM Michael S. Tsirkin wrote: > > > > On Thu, Sep 26, 2024 at 06:16:40PM +0200, Alexander Mikhalitsyn wrote: > > > Add an explicit MODULE_VERSION("0.0.1") spe

Re: [PATCH] vhost/vsock: specify module version

2024-09-29 Thread Michael S. Tsirkin
On Thu, Sep 26, 2024 at 06:16:40PM +0200, Alexander Mikhalitsyn wrote: > Add an explicit MODULE_VERSION("0.0.1") specification > for a vhost_vsock module. It is useful because it allows > userspace to check if vhost_vsock is there when it is > configured as a built-in. > > Without this change, the

Re: [GIT PULL] virtio: features, fixes, cleanups

2024-09-25 Thread Michael S. Tsirkin
On Wed, Sep 25, 2024 at 09:38:49AM +0200, Stefano Garzarella wrote: > On Tue, Sep 24, 2024 at 04:50:46PM GMT, Michael S. Tsirkin wrote: > > The following changes since commit 431c1646e1f86b949fa3685efc50b660a364c2b6: > > > > Linux 6.11-rc6 (2024-09-01 19:46:02 +1200) >

[GIT PULL v2] virtio: features, fixes, cleanups

2024-09-25 Thread Michael S. Tsirkin
virtio/vsock performance has been improved Fixes, cleanups all over the place. Signed-off-by: Michael S. Tsirkin Cindy Lu (3): vdpa: support set mac address from vdpa tool vdpa_sim_net: Add the support of set mac address

Re: [GIT PULL] virtio: features, fixes, cleanups

2024-09-25 Thread Michael S. Tsirkin
On Tue, Sep 24, 2024 at 04:50:46PM -0400, Michael S. Tsirkin wrote: > The following changes since commit 431c1646e1f86b949fa3685efc50b660a364c2b6: > > Linux 6.11-rc6 (2024-09-01 19:46:02 +1200) > > are available in the Git repository at: > > https://git.kernel.org/pub

Re: [PATCH] virtio: Make vring_new_virtqueue support for packed vring

2024-09-24 Thread Michael S. Tsirkin
On Sat, Sep 21, 2024 at 04:21:41AM +0800, Wenyu Huang wrote: > From: Wenyu Huang > > It's also available for packed ring now. > > Signed-off-by: Wenyu Huang More specifically, what are you trying to address here? Which configuration did not work but does now? > --- > drivers/virtio/virtio_r

[GIT PULL] virtio: features, fixes, cleanups

2024-09-24 Thread Michael S. Tsirkin
vdpa supports setting mac address vdpa/mlx5 suspend/resume as well as MKEY ops are now faster virtio_fs supports new sysfs entries for queue info virtio/vsock performance has been improved Fixes, cleanups all over the place. Signed-off-by: Michael S. Tsirkin

Re: [PATCH v3] virtio_net: Fix mismatched buf address when unmapping for small packets

2024-09-18 Thread Michael S. Tsirkin
On Wed, Sep 18, 2024 at 09:20:05PM +0800, Wenbo Li wrote: > Currently, the virtio-net driver will perform a pre-dma-mapping for > small or mergeable RX buffer. But for small packets, a mismatched address > without VIRTNET_RX_PAD and xdp_headroom is used for unmapping. > > That will result in unsyn

[PATCH] virtio_console: fix misc probe bugs

2024-09-16 Thread Michael S. Tsirkin
find_port_by_vq which attempts to take ports_lock which also has not been initialized. To fix, init all locks and work before creating vqs. Fixes: 17634ba25544 ("virtio: console: Add a new MULTIPORT feature, support for generic ports") Signed-off-by: Michael S. Tsirkin --- dr

[PATCH v2] virtio_ring: tag event_triggered as racy for KCSAN

2024-09-12 Thread Michael S. Tsirkin
should probably look at ways to make this more straight-forwardly correct. Cc: Marco Elver Reported-by: syzbot+8a02104389c2e0ef5...@syzkaller.appspotmail.com Signed-off-by: Michael S. Tsirkin --- drivers/virtio/virtio_ring.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a

Re: [syzbot] [virt?] KCSAN: data-race in virtqueue_disable_cb / vring_interrupt (4)

2024-09-12 Thread Michael S. Tsirkin
On Thu, Sep 12, 2024 at 04:46:28PM +0200, Marco Elver wrote: > On Thu, 12 Sept 2024 at 16:34, Michael S. Tsirkin wrote: > > > > On Thu, Sep 12, 2024 at 03:48:32PM +0200, Marco Elver wrote: > > > On Thu, 12 Sept 2024 at 13:03, Michael S. Tsirkin wrote: > > > >

Re: [syzbot] [virt?] KCSAN: data-race in virtqueue_disable_cb / vring_interrupt (4)

2024-09-12 Thread Michael S. Tsirkin
On Thu, Sep 12, 2024 at 03:48:32PM +0200, Marco Elver wrote: > On Thu, 12 Sept 2024 at 13:03, Michael S. Tsirkin wrote: > > > > On Thu, Sep 12, 2024 at 01:11:21AM -0700, syzbot wrote: > > > Hello, > > > > > > syzbot found the following issue on: >

[PATCH] virtio_ring: tag event_triggered as racy for KCSAN

2024-09-12 Thread Michael S. Tsirkin
. Cc: Marco Elver Reported-by: syzbot+8a02104389c2e0ef5...@syzkaller.appspotmail.com Signed-off-by: Michael S. Tsirkin --- drivers/virtio/virtio_ring.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/virtio/virtio_ring.c b/drivers/virtio/virtio_ring.c index be7309b

Re: [syzbot] [virt?] KCSAN: data-race in virtqueue_disable_cb / vring_interrupt (4)

2024-09-12 Thread Michael S. Tsirkin
On Thu, Sep 12, 2024 at 03:48:32PM +0200, Marco Elver wrote: > On Thu, 12 Sept 2024 at 13:03, Michael S. Tsirkin wrote: > > > > On Thu, Sep 12, 2024 at 01:11:21AM -0700, syzbot wrote: > > > Hello, > > > > > > syzbot found the following issue on: >

Re: [syzbot] [virt?] KCSAN: data-race in virtqueue_disable_cb / vring_interrupt (4)

2024-09-12 Thread Michael S. Tsirkin
On Thu, Sep 12, 2024 at 01:11:21AM -0700, syzbot wrote: > Hello, > > syzbot found the following issue on: > > HEAD commit:7c6a3a65ace7 minmax: reduce min/max macro expansion in ato.. > git tree: upstream > console output: https://syzkaller.appspot.com/x/log.txt?x=1608e49f98 > kernel

Re: [RESEND PATCH v1 0/7]vhost: Add support of kthread API

2024-09-11 Thread Michael S. Tsirkin
On Wed, Sep 11, 2024 at 11:20:30AM -0500, Mike Christie wrote: > If people are ok with something similar as in this patchset where > we have both vhost_tasks and kthreads, then I can send something. It would be better, as you say, to modify the vhost_task code so it can emulate the kthread behavi

Re: [RESEND PATCH v1 0/7]vhost: Add support of kthread API

2024-09-11 Thread Michael S. Tsirkin
On Wed, Sep 11, 2024 at 11:45:33AM +0800, Jason Wang wrote: > On Tue, Sep 10, 2024 at 4:43 PM Michael S. Tsirkin wrote: > > > > On Tue, Sep 10, 2024 at 04:37:52PM +0800, Jason Wang wrote: > > > On Tue, Sep 10, 2024 at 3:42 PM Michael S. Tsirkin > > > wrote: >

Re: [PATCH v1 0/5] virtio-mem: s390x support

2024-09-10 Thread Michael S. Tsirkin
lkml.kernel.org/r/20240910175809.2135596-1-da...@redhat.com > [2] https://gitlab.com/davidhildenbrand/s390x-os-virt-spec > [3] https://virtio-mem.gitlab.io/user-guide/user-guide-linux.html > > Cc: Heiko Carstens > Cc: Vasily Gorbik > Cc: Alexander Gordeev > Cc: Christian B

Re: [PATCH v1 3/5] virtio-mem: s390x support

2024-09-10 Thread Michael S. Tsirkin
27;t currently dump virtio-mem memory. The virtio-mem > driver has a special kdump mode, from where we can detect memory ranges > to dump. Based on this, support for dumping virtio-mem memory can be > added in the future fairly easily. > > Signed-off-by: David Hildenbrand Acked-by

Re: [RESEND PATCH v1 0/7]vhost: Add support of kthread API

2024-09-10 Thread Michael S. Tsirkin
On Tue, Sep 10, 2024 at 04:37:52PM +0800, Jason Wang wrote: > On Tue, Sep 10, 2024 at 3:42 PM Michael S. Tsirkin wrote: > > > > On Mon, Sep 09, 2024 at 10:00:38AM +0800, Cindy Lu wrote: > > > In commit 6e890c5d5021 ("vhost: use vhost_tasks for worker threads"), &

Re: [RESEND PATCH v1 0/7]vhost: Add support of kthread API

2024-09-10 Thread Michael S. Tsirkin
On Mon, Sep 09, 2024 at 10:00:38AM +0800, Cindy Lu wrote: > In commit 6e890c5d5021 ("vhost: use vhost_tasks for worker threads"), > vhost removed the support for the kthread API. However, there are > still situations where there is a request to use kthread. > In this PATCH, the support of kthread i

Re: [PATCH v3 0/2] Properly initialize speed/duplex and remove vDPA config updates

2024-09-09 Thread Michael S. Tsirkin
On Wed, Sep 04, 2024 at 10:11:13AM -0500, Carlos Bilbao wrote: > From: Carlos Bilbao > > Initialize speed and duplex for virtio_net_config to UNKNOWN (mlx5_vdpa > vDPA devices currently do not support VIRTIO_NET_F_SPEED_DUPLEX). Remove > ioctl VHOST_VDPA_SET_CONFIG and its related logic as it is

Re: [PATCH RFC 1/3] Revert "virtio_net: rx remove premapped failover code"

2024-09-08 Thread Michael S. Tsirkin
t; > For the series then: > > Tested-by: Darren Kenny > > Thanks, > > Darren. > > On Wednesday, 2024-08-14 at 02:59:20 -04, Michael S. Tsirkin wrote: > > This reverts commit defd28aa5acb0fd7c15adc6bc40a8ac277d04dea. > > > > leads to crashes with no

Re: [RFC PATCH v2 5/7] Revert "virtio_net: rx remove premapped failover code"

2024-09-06 Thread Michael S. Tsirkin
On Fri, Sep 06, 2024 at 06:02:50PM +0800, Xuan Zhuo wrote: > On Fri, 6 Sep 2024 05:52:36 -0400, "Michael S. Tsirkin" > wrote: > > This reverts commit defd28aa5acb0fd7c15adc6bc40a8ac277d04dea. > > > > leads to crashes with no ACCESS_PLATFORM when > > sy

[RFC PATCH v2 7/7] Revert "virtio_ring: enable premapped mode whatever use_dma_api"

2024-09-06 Thread Michael S. Tsirkin
This reverts commit f9dac92ba9081062a6477ee015bd3b8c5914efc4. leads to crashes with no ACCESS_PLATFORM when sysctl net.core.high_order_alloc_disable=1 Cc: Xuan Zhuo Reported-by: Si-Wei Liu Signed-off-by: Michael S. Tsirkin --- drivers/virtio/virtio_ring.c | 7 ++- 1 file changed, 6

[RFC PATCH v2 6/7] Revert "virtio_net: big mode skip the unmap check"

2024-09-06 Thread Michael S. Tsirkin
This reverts commit a377ae542d8d0a20a3173da3bbba72e045bea7a9. leads to crashes with no ACCESS_PLATFORM when sysctl net.core.high_order_alloc_disable=1 Cc: Xuan Zhuo Reported-by: Si-Wei Liu Signed-off-by: Michael S. Tsirkin --- drivers/net/virtio_net.c | 4 ++-- 1 file changed, 2 insertions

[RFC PATCH v2 5/7] Revert "virtio_net: rx remove premapped failover code"

2024-09-06 Thread Michael S. Tsirkin
This reverts commit defd28aa5acb0fd7c15adc6bc40a8ac277d04dea. leads to crashes with no ACCESS_PLATFORM when sysctl net.core.high_order_alloc_disable=1 Cc: Xuan Zhuo Reported-by: Si-Wei Liu Signed-off-by: Michael S. Tsirkin --- drivers/net/virtio_net.c | 89

[RFC PATCH v2 4/7] Revert "virtio_net: xsk: bind/unbind xsk for rx"

2024-09-06 Thread Michael S. Tsirkin
This reverts commit 09d2b3182c8e3a215a9b2a1834f81dd07305989f. leads to crashes with no ACCESS_PLATFORM when sysctl net.core.high_order_alloc_disable=1 Cc: Xuan Zhuo Reported-by: Si-Wei Liu Signed-off-by: Michael S. Tsirkin --- drivers/net/virtio_net.c | 134

[RFC PATCH v2 3/7] Revert "virtio_net: xsk: rx: support fill with xsk buffer"

2024-09-06 Thread Michael S. Tsirkin
This reverts commit e9f3962441c0a4d6f16c656e6c8aa02a3ccdd568. leads to crashes with no ACCESS_PLATFORM when sysctl net.core.high_order_alloc_disable=1 Cc: Xuan Zhuo Reported-by: Si-Wei Liu Signed-off-by: Michael S. Tsirkin --- drivers/net/virtio_net.c | 70

[RFC PATCH v2 2/7] Revert "virtio_net: xsk: rx: support recv small mode"

2024-09-06 Thread Michael S. Tsirkin
This reverts commit a4e7ba7027012f009f22a68bcfde670f9298d3a4. leads to crashes with no ACCESS_PLATFORM when sysctl net.core.high_order_alloc_disable=1 Cc: Xuan Zhuo Reported-by: Si-Wei Liu Signed-off-by: Michael S. Tsirkin --- drivers/net/virtio_net.c | 198

[RFC PATCH v2 1/7] Revert "virtio_net: xsk: rx: support recv merge mode"

2024-09-06 Thread Michael S. Tsirkin
This reverts commit 99c861b44eb1fb9dfe8776854116a6a9064c19bb. leads to crashes with no ACCESS_PLATFORM when sysctl net.core.high_order_alloc_disable=1 Cc: Xuan Zhuo Reported-by: Si-Wei Liu Signed-off-by: Michael S. Tsirkin --- drivers/net/virtio_net.c | 144

[RFC PATCH v2 0/7] Revert "virtio_net: rx enable premapped mode by default"

2024-09-06 Thread Michael S. Tsirkin
). And virtnet_rq_unmap() seems to only work with high order pages. Suggest reverting for now, unfortunately this implies reverting the xsk enhancements. Try again next merge window. Michael S. Tsirkin (7): Revert "virtio_net: xsk: rx: support recv merge mode" Revert "virti

Re: [External] Re: [PATCH v2] virtio_net: Fix mismatched buf address when unmapping for small packets

2024-09-04 Thread Michael S. Tsirkin
On Wed, Sep 04, 2024 at 03:30:02PM +0800, Xuan Zhuo wrote: > On Wed, 4 Sep 2024 15:21:28 +0800, =?utf-8?b?5paH5Y2a5p2O?= > wrote: > > When SWIOTLB is enabled, a DMA map will allocate a bounce buffer for real > > DMA operations, > > and when unmapping, SWIOTLB copies the content in the bounce buff

Re: [PATCH net-next v4 0/2] vsock: avoid queuing on intermediate queue if possible

2024-08-29 Thread Michael S. Tsirkin
On Thu, Aug 29, 2024 at 02:33:11PM +0200, Stefano Garzarella wrote: > On Thu, Aug 29, 2024 at 08:19:31AM GMT, Michael S. Tsirkin wrote: > > On Thu, Aug 29, 2024 at 01:00:37PM +0200, Luigi Leonardi wrote: > > > Hi All, > > > > > > It has been a while since t

Re: [PATCH net-next v4 0/2] vsock: avoid queuing on intermediate queue if possible

2024-08-29 Thread Michael S. Tsirkin
On Thu, Aug 29, 2024 at 01:00:37PM +0200, Luigi Leonardi wrote: > Hi All, > > It has been a while since the last email and this patch has not been merged > yet. > This is just a gentle ping :) > > Thanks, > Luigi ok I can queue it for next. Next time pls remember to CC all maintainers. Thanks!

Re: [PATCH] vdpa: Set speed and duplex of mlx5_vnet to UNKNOWN

2024-08-29 Thread Michael S. Tsirkin
On Wed, Aug 28, 2024 at 01:16:25PM -0500, Carlos Bilbao wrote: > From: Carlos Bilbao > > mlx5_vdpa vDPA devices currently don't support reporting or setting the > speed and duplex and hence should be UNKNOWN instead of zero. > > Signed-off-by: Carlos Bilbao As Jason points out, commit log and

Re: [PATCH] vdpa: Set speed and duplex of mlx5_vnet to UNKNOWN

2024-08-28 Thread Michael S. Tsirkin
On Thu, Aug 29, 2024 at 12:49:24PM +0800, Jason Wang wrote: > On Thu, Aug 29, 2024 at 2:16 AM Carlos Bilbao > wrote: > > > > From: Carlos Bilbao > > > > mlx5_vdpa vDPA devices currently don't support reporting or setting the > > speed and duplex and hence should be UNKNOWN instead of zero. > > >

Re: [RFC] vDPA: Trying to make sense of config data

2024-08-27 Thread Michael S. Tsirkin
On Fri, Aug 23, 2024 at 09:51:24AM -0500, Carlos Bilbao wrote: > Hello again,  > > Answering my own question: > > https://elixir.bootlin.com/linux/v6.10.2/source/include/uapi/linux/virtio_net.h#L92 > > Thanks, Carlos Right. kernel.org would be the official source for that header. Or if you want

Re: [syzbot] [kvm?] [net?] [virt?] INFO: task hung in __vhost_worker_flush

2024-08-16 Thread Michael S. Tsirkin
On Fri, Aug 16, 2024 at 11:10:32AM -0700, Sean Christopherson wrote: > On Fri, Aug 16, 2024, syzbot wrote: > > > On Wed, May 29, 2024, syzbot wrote: > > >> Hello, > > >> > > >> syzbot found the following issue on: > > >> > > >> HEAD commit:9b62e02e6336 Merge tag > > >> 'mm-hotfixes-stable-20

Re: [PATCH RFC 0/3] Revert "virtio_net: rx enable premapped mode by default"

2024-08-15 Thread Michael S. Tsirkin
On Thu, Aug 15, 2024 at 11:23:19AM -0400, Michael S. Tsirkin wrote: > On Thu, Aug 15, 2024 at 09:14:27AM +0200, Linux regression tracking (Thorsten > Leemhuis) wrote: > > [side note: the message I have been replying to at least when downloaded > > from lore has two messag

Re: [PATCH RFC 0/3] Revert "virtio_net: rx enable premapped mode by default"

2024-08-15 Thread Michael S. Tsirkin
On Thu, Aug 15, 2024 at 09:14:27AM +0200, Linux regression tracking (Thorsten Leemhuis) wrote: > [side note: the message I have been replying to at least when downloaded > from lore has two message-ids, one of them identical two a older > message, which is why this looks odd in the lore archives:

Re: [RFC PATCH] vhost_vdpa: assign irq bypass producer token correctly

2024-08-14 Thread Michael S. Tsirkin
On Thu, Aug 08, 2024 at 04:20:44PM +0800, Jason Wang wrote: > We used to call irq_bypass_unregister_producer() in > vhost_vdpa_setup_vq_irq() which is problematic as we don't know if the > token pointer is still valid or not. > > Actually, we use the eventfd_ctx as the token so the life cycle of t

[PATCH RFC 3/3] Revert "virtio_ring: enable premapped mode whatever use_dma_api"

2024-08-14 Thread Michael S. Tsirkin
This reverts commit f9dac92ba9081062a6477ee015bd3b8c5914efc4. leads to crashes with no ACCESS_PLATFORM when sysctl net.core.high_order_alloc_disable=1 Reported-by: Si-Wei Liu Message-ID: <8b20cc28-45a9-4643-8e87-ba164a540...@oracle.com> Signed-off-by: Michael S. Tsirkin --- drivers/

[PATCH RFC 2/3] Revert "virtio_net: big mode skip the unmap check"

2024-08-14 Thread Michael S. Tsirkin
This reverts commit a377ae542d8d0a20a3173da3bbba72e045bea7a9. leads to crashes with no ACCESS_PLATFORM when sysctl net.core.high_order_alloc_disable=1 Reported-by: Si-Wei Liu Message-ID: <8b20cc28-45a9-4643-8e87-ba164a540...@oracle.com> Signed-off-by: Michael S. Tsirkin --- drive

[PATCH RFC 1/3] Revert "virtio_net: rx remove premapped failover code"

2024-08-14 Thread Michael S. Tsirkin
This reverts commit defd28aa5acb0fd7c15adc6bc40a8ac277d04dea. leads to crashes with no ACCESS_PLATFORM when sysctl net.core.high_order_alloc_disable=1 Reported-by: Si-Wei Liu Message-ID: <8b20cc28-45a9-4643-8e87-ba164a540...@oracle.com> Signed-off-by: Michael S. Tsirkin --- drive

[PATCH RFC 0/3] Revert "virtio_net: rx enable premapped mode by default"

2024-08-13 Thread Michael S. Tsirkin
). And virtnet_rq_unmap() seems to only work with high order pages. Suggest reverting for now. Michael S. Tsirkin (3): Revert "virtio_net: rx remove premapped failover code" Revert "virtio_net: big mode skip the unmap check" Revert "virtio_ring: enable premapped mode

Re: [PATCH] virtio: Remove virtio devices on device_shutdown()

2024-08-08 Thread Michael S. Tsirkin
On Thu, Aug 08, 2024 at 04:15:25PM +0300, Kirill A. Shutemov wrote: > On Thu, Aug 08, 2024 at 08:10:34AM -0400, Michael S. Tsirkin wrote: > > On Thu, Aug 08, 2024 at 10:51:41AM +0300, Kirill A. Shutemov wrote: > > > Hongyu reported a hang on kexec in a VM. QEMU repor

  1   2   3   4   5   6   7   8   9   10   >