aboutsummaryrefslogtreecommitdiff
path: root/hw/virtio
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé <philmd@redhat.com>2021-08-26 19:26:56 +0200
committerMichael S. Tsirkin <mst@redhat.com>2021-09-04 17:34:05 -0400
commit7f51beddadbc7d879a4f0979c1cf330f7010161a (patch)
tree1f2d9b120b2d07af79dbeaf71759f148ad6e36f8 /hw/virtio
parentc2ea98c3172149a119d81bca9c9a99ccfa36ea37 (diff)
downloadqemu-7f51beddadbc7d879a4f0979c1cf330f7010161a.zip
qemu-7f51beddadbc7d879a4f0979c1cf330f7010161a.tar.gz
qemu-7f51beddadbc7d879a4f0979c1cf330f7010161a.tar.bz2
hw/virtio: Document virtio_queue_packed_empty_rcu is called within RCU
While virtio_queue_packed_empty_rcu() uses the '_rcu' suffix, it is not obvious it is called within rcu_read_lock(). All other functions from this file called with the RCU locked have a comment describing it. Document this one similarly for consistency. Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20210826172658.2116840-2-philmd@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Stefano Garzarella <sgarzare@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'hw/virtio')
-rw-r--r--hw/virtio/virtio.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/virtio/virtio.c b/hw/virtio/virtio.c
index 874377f..a5214bc 100644
--- a/hw/virtio/virtio.c
+++ b/hw/virtio/virtio.c
@@ -634,6 +634,7 @@ static int virtio_queue_split_empty(VirtQueue *vq)
return empty;
}
+/* Called within rcu_read_lock(). */
static int virtio_queue_packed_empty_rcu(VirtQueue *vq)
{
struct VRingPackedDesc desc;