On Wed, May 01, 2024 at 05:38:15PM +0200, Peter-Jan Gootzen wrote:
> In this patch set we are adding multi-queue support in the virtio-fs
> driver to enhance performance.
> While multi-queue functionality has been in the virtio-fs specification
> since its inception, the current implementation in the Linux kernel
> creates multiple queues, but only enqueues requests on the first request
> queue.
> 
> The first commit in this patch set limits the number of request queues
> to the number of CPUs in the system, to reduce unnecessary resource
> consumption on the device-side.
> The second commit adds a multi queue mapping to the virtio-fs device
> driver that is created using MSI-X affinity mappings or, in case of no
> existing mappings, by evenly grouping the CPUs and dividing the queues
> over these groups.
> 
> Future work in this direction could include:
> - CPU hotplug support

It looks like this series is safe to merge as-is. Hotplugged CPUs
default to the first request queue. It's safe because mq_map[] is sized
to nr_cpu_ids (max number of possible CPUs) and mq_map[] is initialized
to 0 (first request queue). Hotplug can be added later.

> - In case of no MSI-X, using the created multi-queue mapping to set
>   interrupt affinities
> 
> See the commit message of the second patch for performance results.
> 
> Peter-Jan Gootzen (2):
>   virtio-fs: limit number of request queues
>   virtio-fs: add multi-queue support
> 
>  fs/fuse/virtio_fs.c | 73 ++++++++++++++++++++++++++++++++++++++++-----
>  1 file changed, 65 insertions(+), 8 deletions(-)

Reviewed-by: Stefan Hajnoczi <stefa...@redhat.com>

Attachment: signature.asc
Description: PGP signature

Reply via email to