diff options
| author | David Lechner <dlechner@baylibre.com> | 2025-09-16 16:02:57 -0500 |
|---|---|---|
| committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2025-10-13 08:37:24 +0100 |
| commit | 592ae0ccecfac9af8f67444cab11cbb11770f571 (patch) | |
| tree | 1185e3869b2021cb4597965dfb7ecebe02c78f59 /drivers/iio/buffer | |
| parent | 748ed9fc8596015e7e136877465919b89c7d08d6 (diff) | |
iio: buffer: document that buffer callback must be context safe
Document that the callback registered with iio_channel_get_all_cb()
must be safe to call from any context since it is called from by
iio_push_to_buffer() which can be called in any context.
Signed-off-by: David Lechner <dlechner@baylibre.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio/buffer')
| -rw-r--r-- | drivers/iio/buffer/industrialio-buffer-cb.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/iio/buffer/industrialio-buffer-cb.c b/drivers/iio/buffer/industrialio-buffer-cb.c index 3e27385069ed..f4ebff968493 100644 --- a/drivers/iio/buffer/industrialio-buffer-cb.c +++ b/drivers/iio/buffer/industrialio-buffer-cb.c @@ -13,6 +13,7 @@ struct iio_cb_buffer { struct iio_buffer buffer; + /* Must be safe to call from any context (e.g. must not sleep). */ int (*cb)(const void *data, void *private); void *private; struct iio_channel *channels; |
