[PATCH] iio: stm32-dfsdm: Treat flags as booleans
Andy Shevchenko
andriy.shevchenko at intel.com
Sat Jun 13 06:39:16 PDT 2026
On Fri, Jun 12, 2026 at 04:51:50PM -0500, Rob Herring (Arm) wrote:
> The "st,adc-alt-channel" and "st,filter0-sync" properties are
> documented as boolean flags. The legacy parser read them as integer
> cells, unlike the child-node parser which already checks only for
> presence.
>
> Use presence and boolean helpers so both parsers follow the binding and
> the property type checker no longer reports the flags.
For the patch
Reviewed-by: Andy Shevchenko <andriy.shevchenko at intel.com>
However one interesting remark below.
...
> - ret = of_property_read_u32_index(indio_dev->dev.of_node,
> - "st,adc-alt-channel", chan_idx,
> - &df_ch->alt_si);
> + df_ch->alt_si = of_property_present(indio_dev->dev.of_node,
I believe it still has another (serious?) issue. We usually don't use indio_dev
for device properties. It's not a device that is described in DT.
It seems the only driver in IIO that does that. Note, I haven't conducted any
deeper research, it might be (however I'm quite in doubt) that this is correct
use and one device registers a few indio_dev:s.
> + "st,adc-alt-channel");
--
With Best Regards,
Andy Shevchenko
More information about the linux-arm-kernel
mailing list