Re: [PATCH vhost v8 6/6] virtio_ring: simplify the parameters of the funcs related to vring_create/new_virtqueue()

2024-04-24 Thread Xuan Zhuo
On Wed, 24 Apr 2024 11:22:55 +0800, Xuan Zhuo wrote: > On Mon, 22 Apr 2024 22:26:23 +0800, kernel test robot > wrote: > > > > > > Hello, > > > > kernel test robot noticed "BUG:kernel_reboot-without-warning_in_boot_stage" > > on: > > > > commit: fce2775b7bb39424d5ed656612a1d83fd265b670 ("[PATCH

[PATCH vhost v9 0/6] refactor the params of find_vqs()

2024-04-24 Thread Xuan Zhuo
This pathset is splited from the http://lore.kernel.org/all/20240229072044.77388-1-xuanz...@linux.alibaba.com That may needs some cycles to discuss. But that notifies too many people. But just the four commits need to notify so many people. And four commits are independent. So I split that

[PATCH vhost v9 1/6] virtio_balloon: remove the dependence where names[] is null

2024-04-24 Thread Xuan Zhuo
Currently, the init_vqs function within the virtio_balloon driver relies on the condition that certain names array entries are null in order to skip the initialization of some virtual queues (vqs). This behavior is unique to this part of the codebase. In an upcoming commit, we plan to eliminate thi

[PATCH vhost v9 2/6] virtio: remove support for names array entries being null.

2024-04-24 Thread Xuan Zhuo
commit 6457f126c888 ("virtio: support reserved vqs") introduced this support. Multiqueue virtio-net use 2N as ctrl vq finally, so the logic doesn't apply. And not one uses this. On the other side, that makes some trouble for us to refactor the find_vqs() params. So I remove this support. Signed-

[PATCH vhost v9 4/6] virtio: vring_create_virtqueue: pass struct instead of multi parameters

2024-04-24 Thread Xuan Zhuo
Now, we pass multi parameters to vring_create_virtqueue. These parameters may from transport or from driver. vring_create_virtqueue is called by many places. Every time, we try to add a new parameter, that is difficult. If parameters from the driver, that should directly be passed to vring. Then

[PATCH vhost v9 5/6] virtio: vring_new_virtqueue(): pass struct instead of multi parameters

2024-04-24 Thread Xuan Zhuo
Now, we pass multi parameters to vring_new_virtqueue. These parameters may from transport or from driver. vring_new_virtqueue is called by many places. Every time, we try to add a new parameter, that is difficult. If parameters from the driver, that should directly be passed to vring. Then the vr

[PATCH vhost v9 6/6] virtio_ring: simplify the parameters of the funcs related to vring_create/new_virtqueue()

2024-04-24 Thread Xuan Zhuo
As the refactor of find_vqs()/vring_new_virtqueue()/vring_create_virtqueue the struct cfg/tp_cfg are passed to vring. This patch refactors the vring by these structures. This can simplify the code. Signed-off-by: Xuan Zhuo Reviewed-by: Ilpo Järvinen Acked-by: Jason Wang --- drivers/virtio/vir

[PATCH vhost v9 3/6] virtio: find_vqs: pass struct instead of multi parameters

2024-04-24 Thread Xuan Zhuo
Now, we pass multi parameters to find_vqs. These parameters may work for transport or work for vring. And find_vqs has multi implements in many places: arch/um/drivers/virtio_uml.c drivers/platform/mellanox/mlxbf-tmfifo.c drivers/remoteproc/remoteproc_virtio.c drivers/s390/virtio/virtio_ccw.c