Skip to content

Make cb a required parameter of buffer-cb

Nuno Sá alsa-devel linux-iio 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest2 patches 4 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2ASoC: stm32: dfsdm: add stm32_adfsdm_dummy_cb() callbacksound/soc/stm/stm32_adfsdm.c+11 -11 reply
2/2iio: buffer: Return error if no callback is givendrivers/iio/buffer/industrialio-buffer-cb.c+5 -01 reply

Reviews trailers per patch

All 2 patches have a Reviewed-by or Acked-by.

PatchOlivier MoysanMark Brown
1/2A-b
2/2R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/2] Make cb a required parameter of buffer-cb

When going through the code of the buffer-cb interface and all it's users, I realized that the stm32_adfsdm driver is calling iio_channel_get_all_cb() with NULL for the cb. After going a bit trough the stm drivers, it looks like this is actually intentional. However, it is clear that we have a clear/direct route here for a NULL pointer dereference. This change makes cb a required parameter of the API.

The first patch makes the necessary changes to the stm32_adfsdm driver so that it does not break.

Nuno Sá (1):
iio: buffer: Return error if no callback is given

Olivier Moysan (1):
ASoC: stm32: dfsdm: add stm32_adfsdm_dummy_cb() callback

 drivers/iio/buffer/industrialio-buffer-cb.c |  5 +++++
 sound/soc/stm/stm32_adfsdm.c                | 12 +++++++++++-
 2 files changed, 16 insertions(+), 1 deletion(-)
Signature · 1 line
2.17.1