Re: [PATCH 2/2] virtio-net: reduce the CPU consumption of dim worker

2024-03-21 Thread Dan Carpenter
Hi Heng, kernel test robot noticed the following build warnings: https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Heng-Qi/virtio-net-fix-possible-dim-status-unrecoverable/20240321-194759 base: linus/master patch link

Re: [PATCH vhost v4 10/10] virtio_ring: virtqueue_set_dma_premapped support disable

2024-03-21 Thread Xuan Zhuo
On Fri, 22 Mar 2024 13:13:36 +0800, Jason Wang wrote: > On Thu, Mar 21, 2024 at 4:22 PM Xuan Zhuo wrote: > > > > On Thu, 21 Mar 2024 14:02:14 +0800, Jason Wang wrote: > > > On Tue, Mar 12, 2024 at 11:36 AM Xuan Zhuo > > > wrote: > > > > > > > > Now, the API virtqueue_set_dma_premapped just sup

Re: [PATCH vhost v4 03/10] virtio_ring: packed: structure the indirect desc table

2024-03-21 Thread Xuan Zhuo
On Fri, 22 Mar 2024 13:15:10 +0800, Jason Wang wrote: > On Thu, Mar 21, 2024 at 4:29 PM Xuan Zhuo wrote: > > > > On Thu, 21 Mar 2024 12:47:18 +0800, Jason Wang wrote: > > > On Tue, Mar 12, 2024 at 11:36 AM Xuan Zhuo > > > wrote: > > > > > > > > This commit structure the indirect desc table. >

Re: REGRESSION: RIP: 0010:skb_release_data+0xb8/0x1e0 in vhost/tun

2024-03-21 Thread Jason Wang
On Thu, Mar 21, 2024 at 5:44 PM Igor Raits wrote: > > Hello Jason & others, > > On Wed, Mar 20, 2024 at 10:33 AM Jason Wang wrote: > > > > On Tue, Mar 19, 2024 at 9:15 PM Igor Raits wrote: > > > > > > Hello Stefan, > > > > > > On Tue, Mar 19, 2024 at 2:12 PM Stefan Hajnoczi > > > wrote: > > >

Re: [PATCH vhost v4 03/10] virtio_ring: packed: structure the indirect desc table

2024-03-21 Thread Jason Wang
On Thu, Mar 21, 2024 at 4:29 PM Xuan Zhuo wrote: > > On Thu, 21 Mar 2024 12:47:18 +0800, Jason Wang wrote: > > On Tue, Mar 12, 2024 at 11:36 AM Xuan Zhuo > > wrote: > > > > > > This commit structure the indirect desc table. > > > Then we can get the desc num directly when doing unmap. > > > > >

Re: [PATCH 2/2] virtio-net: reduce the CPU consumption of dim worker

2024-03-21 Thread Jason Wang
On Thu, Mar 21, 2024 at 7:46 PM Heng Qi wrote: > > Currently, ctrlq processes commands in a synchronous manner, > which increases the delay of dim commands when configuring > multi-queue VMs, which in turn causes the CPU utilization to > increase and interferes with the performance of dim. > > The

Re: [PATCH 1/2] virtio-net: fix possible dim status unrecoverable

2024-03-21 Thread Jason Wang
On Thu, Mar 21, 2024 at 7:46 PM Heng Qi wrote: > > When the dim worker is scheduled, if it fails to acquire the lock, > dim may not be able to return to the working state later. > > For example, the following single queue scenario: > 1. The dim worker of rxq0 is scheduled, and the dim status is

Re: [PATCH vhost v4 02/10] virtio_ring: packed: remove double check of the unmap ops

2024-03-21 Thread Jason Wang
On Thu, Mar 21, 2024 at 4:21 PM Xuan Zhuo wrote: > > On Thu, 21 Mar 2024 13:57:06 +0800, Jason Wang wrote: > > On Tue, Mar 12, 2024 at 11:36 AM Xuan Zhuo > > wrote: > > > > > > In the functions vring_unmap_extra_packed and vring_unmap_desc_packed, > > > multiple checks are made whether unmap is

Re: [PATCH vhost v4 10/10] virtio_ring: virtqueue_set_dma_premapped support disable

2024-03-21 Thread Jason Wang
On Thu, Mar 21, 2024 at 4:22 PM Xuan Zhuo wrote: > > On Thu, 21 Mar 2024 14:02:14 +0800, Jason Wang wrote: > > On Tue, Mar 12, 2024 at 11:36 AM Xuan Zhuo > > wrote: > > > > > > Now, the API virtqueue_set_dma_premapped just support to > > > enable premapped mode. > > > > > > If we allow enabling

Re: [PATCH 2/2] virtio-net: reduce the CPU consumption of dim worker

2024-03-21 Thread kernel test robot
Hi Heng, kernel test robot noticed the following build warnings: [auto build test WARNING on linus/master] [also build test WARNING on next-20240321] [cannot apply to v6.8] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use

Re: [PATCH net-next v5 0/9] virtio-net: support device stats

2024-03-21 Thread Simon Horman
On Thu, Mar 21, 2024 at 11:54:34AM +0800, Xuan Zhuo wrote: > On Wed, 20 Mar 2024 20:38:01 -0700, Jakub Kicinski wrote: > > On Wed, 20 Mar 2024 16:04:21 +0800 Xuan Zhuo wrote: > > > I have a question regarding the workflow for feature discussions. If we > > > consistently engage in discussions abou

Re: [PATCH 0/2] virtio-net: a fix and some updates for virtio dim

2024-03-21 Thread Jiri Pirko
Thu, Mar 21, 2024 at 12:45:55PM CET, hen...@linux.alibaba.com wrote: >Patch 1 fixes an existing bug. Belongs to the net branch. Send separately with "net" indication in the patch brackets: https://www.kernel.org/doc/html/next/process/maintainer-netdev.html?highlight=network#tl-dr >Patch 2 attemp

[PATCH 2/2] virtio-net: reduce the CPU consumption of dim worker

2024-03-21 Thread Heng Qi
Currently, ctrlq processes commands in a synchronous manner, which increases the delay of dim commands when configuring multi-queue VMs, which in turn causes the CPU utilization to increase and interferes with the performance of dim. Therefore we asynchronously process ctlq's dim commands. Signed

[PATCH 1/2] virtio-net: fix possible dim status unrecoverable

2024-03-21 Thread Heng Qi
When the dim worker is scheduled, if it fails to acquire the lock, dim may not be able to return to the working state later. For example, the following single queue scenario: 1. The dim worker of rxq0 is scheduled, and the dim status is changed to DIM_APPLY_NEW_PROFILE; 2. The ethtool com

[PATCH 0/2] virtio-net: a fix and some updates for virtio dim

2024-03-21 Thread Heng Qi
Patch 1 fixes an existing bug. Belongs to the net branch. Patch 2 attempts to modify the sending of dim cmds to an asynchronous way. Heng Qi (2): virtio-net: fix possible dim status unrecoverable virtio-net: reduce the CPU consumption of dim worker drivers/net/virtio_net.c | 273

Re: REGRESSION: RIP: 0010:skb_release_data+0xb8/0x1e0 in vhost/tun

2024-03-21 Thread Igor Raits
Hello Jason & others, On Wed, Mar 20, 2024 at 10:33 AM Jason Wang wrote: > > On Tue, Mar 19, 2024 at 9:15 PM Igor Raits wrote: > > > > Hello Stefan, > > > > On Tue, Mar 19, 2024 at 2:12 PM Stefan Hajnoczi wrote: > > > > > > On Tue, Mar 19, 2024 at 10:00:08AM +0100, Igor Raits wrote: > > > > Hel

Re: [PATCH vhost v4 00/10] virtio: drivers maintain dma info for premapped vq

2024-03-21 Thread Xuan Zhuo
On Thu, 21 Mar 2024 12:45:08 +0800, Jason Wang wrote: > On Tue, Mar 12, 2024 at 11:36 AM Xuan Zhuo wrote: > > > > As discussed: > > > > http://lore.kernel.org/all/cacgkmevq0no8qgc46u4mgsmtud44fd_cflcpavmj3rhyqrz...@mail.gmail.com > > > > If the virtio is premapped mode, the driver should manage t

Re: [PATCH vhost v4 03/10] virtio_ring: packed: structure the indirect desc table

2024-03-21 Thread Xuan Zhuo
On Thu, 21 Mar 2024 12:47:18 +0800, Jason Wang wrote: > On Tue, Mar 12, 2024 at 11:36 AM Xuan Zhuo wrote: > > > > This commit structure the indirect desc table. > > Then we can get the desc num directly when doing unmap. > > > > And save the dma info to the struct, then the indirect > > will not

Re: [PATCH vhost v4 10/10] virtio_ring: virtqueue_set_dma_premapped support disable

2024-03-21 Thread Xuan Zhuo
On Thu, 21 Mar 2024 14:02:14 +0800, Jason Wang wrote: > On Tue, Mar 12, 2024 at 11:36 AM Xuan Zhuo wrote: > > > > Now, the API virtqueue_set_dma_premapped just support to > > enable premapped mode. > > > > If we allow enabling the premapped dynamically, we should > > make this API to support disa

Re: [PATCH vhost v4 02/10] virtio_ring: packed: remove double check of the unmap ops

2024-03-21 Thread Xuan Zhuo
On Thu, 21 Mar 2024 13:57:06 +0800, Jason Wang wrote: > On Tue, Mar 12, 2024 at 11:36 AM Xuan Zhuo wrote: > > > > In the functions vring_unmap_extra_packed and vring_unmap_desc_packed, > > multiple checks are made whether unmap is performed and whether it is > > INDIRECT. > > > > These two functi