Lines Matching +full:adc +full:- +full:chan
1 // SPDX-License-Identifier: GPL-2.0-only
3 * Helpers for parsing common ADC information from a firmware node.
15 #include <linux/iio/adc-helpers.h>
19 * devm_iio_adc_device_alloc_chaninfo_se - allocate and fill iio_chan_spec for ADC
21 * Scan the device node for single-ended ADC channel information. Channel ID is
26 * @dev: Pointer to the ADC device.
35 * failure. Specifically, -ENOENT if no channel nodes were found.
42 struct iio_chan_spec *chan_array, *chan; in devm_iio_adc_device_alloc_chaninfo_se() local
50 return -ENOENT; in devm_iio_adc_device_alloc_chaninfo_se()
55 return -ENOMEM; in devm_iio_adc_device_alloc_chaninfo_se()
57 chan = &chan_array[0]; in devm_iio_adc_device_alloc_chaninfo_se()
67 return -ERANGE; in devm_iio_adc_device_alloc_chaninfo_se()
69 *chan = *template; in devm_iio_adc_device_alloc_chaninfo_se()
70 chan->channel = ch; in devm_iio_adc_device_alloc_chaninfo_se()
71 chan++; in devm_iio_adc_device_alloc_chaninfo_se()
82 MODULE_DESCRIPTION("IIO ADC fwnode parsing helpers");