Re: [PATCH v4 4/4] iio: proximity: rfd77402: Add interrupt handling support

From: Andy Shevchenko

Date: Tue Jan 06 2026 - 15:47:23 EST


On Tue, Jan 06, 2026 at 05:39:29AM +0530, Shrikant wrote:

...

> > > #include <linux/module.h>
> > > #include <linux/i2c.h>
> > > #include <linux/delay.h>
> > > +#include <linux/interrupt.h>
> > > +#include <linux/completion.h>
> > > #include <linux/iopoll.h>
> >
> > Same comment as per previous patch. Do not add even more misordering, please.
> Will it be okay if I re-order the includes as below ?
> #include <linux/completion.h>
> #include <linux/delay.h>
> #include <linux/i2c.h>
> #include <linux/interrupt.h>
> #include <linux/iopoll.h>
> #include <linux/module.h>

Just try to squeeze the new inclusions in the longest chain of the sorted ones
(yes, some original ones may be left untouched and hence unordered).

> #include <linux/iio/iio.h>

...

> > > +/**
> > > + * struct rfd77402_data - device-specific data for the RFD77402 sensor
> > > + * @client: I2C client handle
> > > + * @lock: mutex to serialize sensor reads
> > > + * @completion: completion used for interrupt-driven measurements
> > > + * @irq_en: indicates whether interrupt mode is enabled
> > > + */
> > > struct rfd77402_data {
> > > struct i2c_client *client;
> > > - /* Serialize reads from the sensor */
> > > struct mutex lock;
> > > + struct completion completion;
> > > + bool irq_en;
> > > };
> >
> > The kernel-doc conversion can be a separate patch, but I'm not insisting.
> I can split this into a separate patch within the same series.
> Please let me know if you would prefer it to be handled differently.

It's up to maintainers.

--
With Best Regards,
Andy Shevchenko