Re: [PATCH v7 2/2] iio: adc: add MAX40080 current-sense amplifier driver

Andy Shevchenko <[email protected]>
Newsgroups org.kernel.vger.linux-iio,org.kernel.vger.linux-devicetree,org.kernel.vger.linux-kernel
Organization Intel Finland Oy - BIC 0357606-4 - c/o Alberga Business Park, 6 krs, Bertel Jungin Aukio 5, 02600 Espoo
Message-ID <[email protected]>
On Tue, Aug 18, 2026 at 05:19:53PM +0100, Jonathan Cameron wrote:

...

> > > +static const struct iio_chan_spec max40080_channels[] = {
> > > +	{
> > > +		.type = IIO_CURRENT,
> > > +		.indexed = 1,  
> > 
> > > +		.channel = 0,  
> > 
> > No need
> 
> True, but I'd keep it because it is paired with indexed and looking
> for both together is common.

No objections then!

> > > +		.info_mask_separate = BIT(IIO_CHAN_INFO_RAW) |
> > > +				      BIT(IIO_CHAN_INFO_SCALE),
> > > +		.info_mask_separate_available = BIT(IIO_CHAN_INFO_SCALE),
> > > +		.info_mask_shared_by_all = BIT(IIO_CHAN_INFO_OVERSAMPLING_RATIO),
> > > +		.info_mask_shared_by_all_available =
> > > +			BIT(IIO_CHAN_INFO_OVERSAMPLING_RATIO),
> > > +	},
> > > +	{
> > > +		.type = IIO_VOLTAGE,
> > > +		.indexed = 1,  
> > 
> > > +		.channel = 0,  
> > 
> > Same, it's default.
> > 
> > > +		.info_mask_separate = BIT(IIO_CHAN_INFO_RAW) |
> > > +				      BIT(IIO_CHAN_INFO_SCALE),
> > > +		.info_mask_shared_by_all = BIT(IIO_CHAN_INFO_OVERSAMPLING_RATIO),
> > > +		.info_mask_shared_by_all_available =
> > > +			BIT(IIO_CHAN_INFO_OVERSAMPLING_RATIO),
> > > +	},
> > > +};  

-- 
With Best Regards,
Andy Shevchenko
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.