[PATCH v4 7/9] vhost: annotate IOTLB lock

Maxime Coquelin maxime.coquelin at redhat.com
Tue Jan 31 18:05:04 CET 2023



On 1/19/23 19:46, David Marchand wrote:
> The starting point for this is __vhost_iova_to_vva() which requires the
> lock to be taken. Annotate all the code leading to a call to it.
> 
> vdpa and vhost_crypto code are annotated but they end up not taking
> a IOTLB lock and have been marked with a FIXME at the top level.
> 
> Signed-off-by: David Marchand <david.marchand at redhat.com>
> ---
> Changes since RFC v3:
> - rebased,
> - moved unconditionnal lock acquire in separate patch,
> - fixed annotations,
> 
> ---
>   lib/vhost/iotlb.h        |  4 ++++
>   lib/vhost/vdpa.c         |  1 +
>   lib/vhost/vhost.c        |  8 +++-----
>   lib/vhost/vhost.h        | 22 ++++++++++++++++------
>   lib/vhost/vhost_crypto.c |  8 ++++++++
>   lib/vhost/virtio_net.c   | 40 ++++++++++++++++++++++++++++++++++++++++
>   6 files changed, 72 insertions(+), 11 deletions(-)
> 

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

Thanks,
Maxime



More information about the dev mailing list