[dpdk-dev] [PATCH 1/4] vdpa/mlx5: move virtual doorbell alloc to probe

Maxime Coquelin maxime.coquelin at redhat.com
Wed Apr 15 11:44:24 CEST 2020



On 3/24/20 3:24 PM, Asaf Penso wrote:
> From: Matan Azrad <matan at mellanox.com>
> 
> The configure and close operations may be called a lot of time by vhost
> library according to the virtio connections in the guest.
> 
> VAR is the device memory space for the virtio queues doorbells.
> Each VAR page can be shared for more than one queue while its owner must
> synchronize the writes to it.
> 
> The mlx5 driver allocates single VAR page for all its queues.
> 
> Therefore, it is better to allocate it in probe device level instead of
> creating and destroying it per new connection.
> 
> Signed-off-by: Matan Azrad <matan at mellanox.com>
> Acked-by: Viacheslav Ovsiienko <viacheslavo at mellanox.com>
> ---
>  drivers/vdpa/mlx5/mlx5_vdpa.c       | 14 +++++++++++++-
>  drivers/vdpa/mlx5/mlx5_vdpa_virtq.c |  9 ---------
>  2 files changed, 13 insertions(+), 10 deletions(-)

Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>

Thanks,
Maxime



More information about the dev mailing list