[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20260110184728-mutt-send-email-mst@kernel.org>
Date: Sat, 10 Jan 2026 18:48:39 -0500
From: "Michael S. Tsirkin" <mst@...hat.com>
To: Eugenio Pérez <eperezma@...hat.com>
Cc: linux-kernel@...r.kernel.org, virtualization@...ts.linux.dev,
Maxime Coquelin <mcoqueli@...hat.com>,
Laurent Vivier <lvivier@...hat.com>, Cindy Lu <lulu@...hat.com>,
jasowang@...hat.com, Xuan Zhuo <xuanzhuo@...ux.alibaba.com>,
Stefano Garzarella <sgarzare@...hat.com>,
Yongji Xie <xieyongji@...edance.com>
Subject: Re: [PATCH v11 05/12] vdpa: document set_group_asid thread safety
On Fri, Jan 09, 2026 at 04:24:23PM +0100, Eugenio Pérez wrote:
> Document that the function races with the check of DRIVER_OK.
>
> Signed-off-by: Eugenio Pérez <eperezma@...hat.com>
> ---
> Requested at
> https://lore.kernel.org/lkml/CACGkMEvXdV4ukZE6xhLL0sSN70G=AWVQgpRnH98Fr4btzMkK9g@mail.gmail.com/
> ---
> include/linux/vdpa.h | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/include/linux/vdpa.h b/include/linux/vdpa.h
> index 4cf21d6e9cfd..cd1b1f1321b9 100644
> --- a/include/linux/vdpa.h
> +++ b/include/linux/vdpa.h
> @@ -312,7 +312,9 @@ struct vdpa_map_file {
> * @idx: virtqueue index
> * Returns the affinity mask
> * @set_group_asid: Set address space identifier for a
> - * virtqueue group (optional)
> + * virtqueue group (optional). It's not thread
> + * safe to call this function concurrently with
> + * set_status.
Let's be explicit about what to do.
"Caller must prevent this from being executed concurrently with
set_status"?
> * @vdev: vdpa device
> * @group: virtqueue group
> * @asid: address space id for this group
> --
> 2.52.0
Powered by blists - more mailing lists