Messages in this thread | | | Date | Fri, 15 Jul 2022 07:53:03 +0300 | Subject | Re: [PATCH v8 2/2] iio: adc: ad4130: add AD4130 driver | From | Cosmin Tanislav <> |
| |
On 7/15/22 07:49, Cosmin Tanislav wrote: > AD4130-8 is an ultra-low power, high precision, measurement solution for > low bandwidth battery operated applications. > > The fully integrated AFE (Analog Front-End) includes a multiplexer for up > to 16 single-ended or 8 differential inputs, PGA (Programmable Gain > Amplifier), 24-bit Sigma-Delta ADC, on-chip reference and oscillator, > selectable filter options, smart sequencer, sensor biasing and excitation > options, diagnostics, and a FIFO buffer. > > Signed-off-by: Cosmin Tanislav <cosmin.tanislav@analog.com> > Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> > ... > +static int ad4130_gpio_init_valid_mask(struct gpio_chip *gc, > + unsigned long *valid_mask, > + unsigned int ngpios) > +{ > + struct ad4130_state *st = gpiochip_get_data(gc); > + unsigned int i; > + > + /* > + * Output-only GPIO functionality is available on pins AIN2 through > + * AIN5. If these pins are used for anything else, do not expose them. > + */ > + for (i = 0; i < ngpios; i++) { > + unsigned int pin = i + AD4130_AIN2_P1; > + bool valid = st->pins_fn[pin] == AD4130_PIN_FN_NONE; > + > + __assign_bit(i, valid_mask, valid); > + } > + > +
I missed an extra blank line here. Maybe you could fix it while picking the patchset up, Jonathan?
> + return 0; > +} > + > ...
| |