[PATCH v4 6/9] iio: buffer-dma: annotate the queue lock helpers
Rupesh Majhi
zoone.rupert at gmail.com
Tue Oct 27 05:49:51 PDT 2026
iio_dma_buffer_lock_queue() and iio_dma_buffer_unlock_queue() take and
release the queue lock for the core. Annotate them with that lock so
context analysis checks them.
Signed-off-by: Rupesh Majhi <zoone.rupert at gmail.com>
---
Cc: Marco Elver <elver at google.com>
Cc: Bart Van Assche <bvanassche at acm.org>
drivers/iio/buffer/industrialio-buffer-dma.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/iio/buffer/industrialio-buffer-dma.c b/drivers/iio/buffer/industrialio-buffer-dma.c
index 1daac23087a7..b42b70e9b06d 100644
--- a/drivers/iio/buffer/industrialio-buffer-dma.c
+++ b/drivers/iio/buffer/industrialio-buffer-dma.c
@@ -763,6 +763,7 @@ struct device *iio_dma_buffer_get_dma_dev(struct iio_buffer *buffer)
EXPORT_SYMBOL_NS_GPL(iio_dma_buffer_get_dma_dev, "IIO_DMA_BUFFER");
void iio_dma_buffer_lock_queue(struct iio_buffer *buffer)
+ __acquires(&iio_buffer_to_queue(buffer)->lock)
{
struct iio_dma_buffer_queue *queue = iio_buffer_to_queue(buffer);
@@ -771,6 +772,7 @@ void iio_dma_buffer_lock_queue(struct iio_buffer *buffer)
EXPORT_SYMBOL_NS_GPL(iio_dma_buffer_lock_queue, "IIO_DMA_BUFFER");
void iio_dma_buffer_unlock_queue(struct iio_buffer *buffer)
+ __releases(&iio_buffer_to_queue(buffer)->lock)
{
struct iio_dma_buffer_queue *queue = iio_buffer_to_queue(buffer);
--
2.43.0
More information about the linux-arm-kernel
mailing list