Re: [PATCH v3 05/12] iio: dac: ad5686: add support for missing power supplies
From: Joshua Crofts
Date: Tue Jun 16 2026 - 05:38:40 EST
On Tue, 16 Jun 2026 09:21:11 +0100
Rodrigo Alencar via B4 Relay <devnull+rodrigo.alencar.analog.com@xxxxxxxxxx> wrote:
> st->use_internal_vref = ret == -ENODEV;
> st->vref_mv = st->use_internal_vref ? st->chip_info->int_vref_mv : ret / 1000;
I'd use a macro from <linux/units.h> instead of just doing / 1000.
> + if (!st->vref_mv)
> + return dev_err_probe(dev, -EINVAL,
> + "invalid or not provided vref voltage\n");
> +
> + fsleep(5); /* power-up time */
I'd recommend using a macro to define the sleep time, removing
the need for a comment.
> /* Initialize masks to all ones */
> st->pwr_down_mask = ~0;
>
Otherwise LGTM!
--
Kind regards
CJD