[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20260111155658.64aa9577@jic23-huawei>
Date: Sun, 11 Jan 2026 15:56:58 +0000
From: Jonathan Cameron <jic23@...nel.org>
To: Janani Sunil <jan.sun97@...il.com>
Cc: Marcelo Schmitt <marcelo.schmitt1@...il.com>, Janani Sunil
<janani.sunil@...log.com>, Lars-Peter Clausen <lars@...afoo.de>, Michael
Hennerich <Michael.Hennerich@...log.com>, Alexandru Ardelean
<alexandru.ardelean@...log.com>, Rob Herring <robh@...nel.org>, Krzysztof
Kozlowski <krzk+dt@...nel.org>, Conor Dooley <conor+dt@...nel.org>,
Jonathan Corbet <corbet@....net>, linux-iio@...r.kernel.org,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-doc@...r.kernel.org
Subject: Re: [PATCH v2 2/2] iio: dac: Add MAX22007 DAC driver support
> >> + st->iio_chans[i++] = (struct iio_chan_spec) {
> >> + .output = 1,
> >> + .indexed = 1,
> >> + .info_mask_separate = BIT(IIO_CHAN_INFO_RAW) |
> >> + BIT(IIO_CHAN_INFO_SCALE),
> >> + .ext_info = max22007_ext_info,
> >> + .channel = reg,
> >> + .type = chan_type,
> >> + };
> > IMHO, this would look cleaner with a channel template. See ad7124, ad4130,
> > ad4170 for examples.
>
> A channel template approach was followed initially and this approach was taken up based on the latest suggestions from the reviewers, since the template is not being reused elsewhere.
FWIW I prefer this option when it is only used in one place.
Jonathan
Powered by blists - more mailing lists