Re: [PATCH v6 2/4] iio: light: add support for veml6031x00 ALS series

Jonathan Cameron <[email protected]>
Newsgroups org.kernel.vger.linux-devicetree,org.kernel.vger.linux-iio,org.kernel.vger.linux-kernel
Message-ID <20260813022715.19d15cbf@jic23-huawei>
On Thu, 13 Aug 2026 02:04:29 +0100
Jonathan Cameron <[email protected]> wrote:

> On Wed, 12 Aug 2026 22:27:41 +0200
> Javier Carrasco <[email protected]> wrote:
> 
> > These sensors provide two light channels (ALS and IR), I2C communication
> > and a multiplexed interrupt line to signal data ready and configurable
> > threshold alarms.
> > 
> > This first implementation provides basic functionality (measurement
> > configuration, raw reads and ID validation) and defines the different
> > register regions in preparation for extended features in the subsequent
> > patches of the series.
> > 
> > Signed-off-by: Javier Carrasco <[email protected]>  
> Hi Javier,
> 
> A few minor things inline
> 
> Thanks,
> 
> Jonathan
> 
> > diff --git a/drivers/iio/light/veml6031x00.c b/drivers/iio/light/veml6031x00.c
> > new file mode 100644
> > index 000000000000..021bf726c60b
> > --- /dev/null
> > +++ b/drivers/iio/light/veml6031x00.c  
> 
> > +
> > +static const struct iio_chan_spec veml6031x00_channels[] = {
> > +	{
> > +		.type = IIO_LIGHT,
> > +		.address = VEML6031X00_REG_ALS_L,
> > +		.info_mask_separate = BIT(IIO_CHAN_INFO_RAW) |
> > +				      BIT(IIO_CHAN_INFO_INT_TIME) |
> > +				      BIT(IIO_CHAN_INFO_SCALE),
> > +		.info_mask_separate_available = BIT(IIO_CHAN_INFO_INT_TIME) |
> > +						BIT(IIO_CHAN_INFO_SCALE),
> > +	},
> > +	{
> > +		.type = IIO_INTENSITY,
> > +		.address = VEML6031X00_REG_IR_L,
> > +		.modified = 1,
> > +		.channel2 = IIO_MOD_LIGHT_IR,
> > +		.info_mask_separate = BIT(IIO_CHAN_INFO_RAW),
> > +	}  
> 
> Trailing comma.  Maybe we'll add more after this and they will fit on one line.
> Yeah it's a stretch but generally always add comma unless it is a specific
> terminating entry.

Ah. Not such a stretch. I'd forgotten timestamp channels.  This creates
unnecessary noise in the very next patch!
> 
> > +};  
>
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.