[PATCH v5 00/10] General clean up and bug fixes

Ethan Tidmore posted 10 patches 1 month, 3 weeks ago
drivers/iio/light/gp2ap020a00f.c | 303 ++++++++++++-------------------
1 file changed, 117 insertions(+), 186 deletions(-)
[PATCH v5 00/10] General clean up and bug fixes
Posted by Ethan Tidmore 1 month, 3 weeks ago
This series performs a general cleanup of the gp2ap020a00f IIO driver.

It integrates my original work switching to the guard() cleanup handler,
fixing a signedness warning from Smatch, an error swallow bug originally
spotted by Andy Shevchenko which I expanded to cover both buffer setup
functions and general cleanups written by Andy Shevchenko [1].

v5:
- Patch 1: Integrate some of Andy Shevchenko's changes.
- Patch 4: Split patch up as requested by Andy Shevchenko.
- Patch 5: Split this patch from the patch number 4, to keep bug fix
  separate from style fix.
v4:
 - Integrated Andy Shevchenko's 7-patch cleanup series.
 - Patch 1: Removed redundant 'err' variable and whitespace issues as
   suggested by Andy.
 - Patch 2: Added Reviewed-by tag from Andy Shevchenko.
 - Patch 5: Updated commit message to describe the pre-existing bug fix
   in gp2ap020a00f_buffer_predisable() where errors could be swallowed.
v3:
 - Addressed initial feedback and simplified locking logic.

[1] https://lore.kernel.org/all/20260217102318.1354103-1-andriy.shevchenko@linux.intel.com/

Andy Shevchenko (7):
  iio: light: gp2ap020a00f: Use correct types for 16-bit LE data
  iio: light: gp2ap020a00f: Return directly from the switch cases
  iio: light: gp2ap020a00f: Replace custom implementation of min()
  iio: light: gp2ap020a00f: Use temporary variable for struct device
  iio: light: gp2ap020a00f: Explicitly use string literal for driver
    name
  iio: light: gp2ap020a00f: Remove trailing comma in termination entry
  iio: light: gp2ap020a00f: Join some lines of code to be a single line

Ethan Tidmore (3):
  iio: light: gp2ap020a00f: simplify locking with guard()
  iio: light: gp2ap020a00f: correct return type to int
  iio: light: gp2ap020a00f: Fix possible error swallow

 drivers/iio/light/gp2ap020a00f.c | 303 ++++++++++++-------------------
 1 file changed, 117 insertions(+), 186 deletions(-)

-- 
2.53.0
Re: [PATCH v5 00/10] General clean up and bug fixes
Posted by Andy Shevchenko 1 month, 3 weeks ago
On Sun, Feb 22, 2026 at 09:40:10PM -0600, Ethan Tidmore wrote:
> This series performs a general cleanup of the gp2ap020a00f IIO driver.
> 
> It integrates my original work switching to the guard() cleanup handler,
> fixing a signedness warning from Smatch, an error swallow bug originally
> spotted by Andy Shevchenko which I expanded to cover both buffer setup
> functions and general cleanups written by Andy Shevchenko [1].

...

> v5:
> - Patch 1: Integrate some of Andy Shevchenko's changes.
> - Patch 4: Split patch up as requested by Andy Shevchenko.
> - Patch 5: Split this patch from the patch number 4, to keep bug fix
>   separate from style fix.

Jonathan, this version is good to go in my opinion except patch 6
("iio: light: gp2ap020a00f: Fix possible error swallow").

Ethan, do *not* send a new version until we decide what to do with patch 6,
and actually the rest may be applied by Jonathan if he is okay with them.

-- 
With Best Regards,
Andy Shevchenko
Re: [PATCH v5 00/10] General clean up and bug fixes
Posted by Andy Shevchenko 1 month, 3 weeks ago
On Mon, Feb 23, 2026 at 02:16:17PM +0200, Andy Shevchenko wrote:
> On Sun, Feb 22, 2026 at 09:40:10PM -0600, Ethan Tidmore wrote:
> > This series performs a general cleanup of the gp2ap020a00f IIO driver.
> > 
> > It integrates my original work switching to the guard() cleanup handler,
> > fixing a signedness warning from Smatch, an error swallow bug originally
> > spotted by Andy Shevchenko which I expanded to cover both buffer setup
> > functions and general cleanups written by Andy Shevchenko [1].

...

> > v5:
> > - Patch 1: Integrate some of Andy Shevchenko's changes.
> > - Patch 4: Split patch up as requested by Andy Shevchenko.
> > - Patch 5: Split this patch from the patch number 4, to keep bug fix
> >   separate from style fix.
> 
> Jonathan, this version is good to go in my opinion except patch 6
> ("iio: light: gp2ap020a00f: Fix possible error swallow").
> 
> Ethan, do *not* send a new version until we decide what to do with patch 6,
> and actually the rest may be applied by Jonathan if he is okay with them.

It's patch 5, sorry for the confusion.

-- 
With Best Regards,
Andy Shevchenko
Re: [PATCH v5 00/10] General clean up and bug fixes
Posted by Jonathan Cameron 1 month, 3 weeks ago
On Mon, 23 Feb 2026 14:17:14 +0200
Andy Shevchenko <andriy.shevchenko@intel.com> wrote:

> On Mon, Feb 23, 2026 at 02:16:17PM +0200, Andy Shevchenko wrote:
> > On Sun, Feb 22, 2026 at 09:40:10PM -0600, Ethan Tidmore wrote:  
> > > This series performs a general cleanup of the gp2ap020a00f IIO driver.
> > > 
> > > It integrates my original work switching to the guard() cleanup handler,
> > > fixing a signedness warning from Smatch, an error swallow bug originally
> > > spotted by Andy Shevchenko which I expanded to cover both buffer setup
> > > functions and general cleanups written by Andy Shevchenko [1].  
> 
> ...
> 
> > > v5:
> > > - Patch 1: Integrate some of Andy Shevchenko's changes.
> > > - Patch 4: Split patch up as requested by Andy Shevchenko.
> > > - Patch 5: Split this patch from the patch number 4, to keep bug fix
> > >   separate from style fix.  
> > 
> > Jonathan, this version is good to go in my opinion except patch 6
> > ("iio: light: gp2ap020a00f: Fix possible error swallow").
> > 
> > Ethan, do *not* send a new version until we decide what to do with patch 6,
> > and actually the rest may be applied by Jonathan if he is okay with them.  
> 
> It's patch 5, sorry for the confusion.

I tweaked it and applied the series to the testing branch of iio.git

thanks!

Jonathan

>
Re: [PATCH v5 00/10] General clean up and bug fixes
Posted by Andy Shevchenko 1 month, 3 weeks ago
On Mon, Feb 23, 2026 at 09:18:10PM +0000, Jonathan Cameron wrote:
> On Mon, 23 Feb 2026 14:17:14 +0200
> Andy Shevchenko <andriy.shevchenko@intel.com> wrote:
> > On Mon, Feb 23, 2026 at 02:16:17PM +0200, Andy Shevchenko wrote:
> > > On Sun, Feb 22, 2026 at 09:40:10PM -0600, Ethan Tidmore wrote:  

...

> > > > v5:
> > > > - Patch 1: Integrate some of Andy Shevchenko's changes.
> > > > - Patch 4: Split patch up as requested by Andy Shevchenko.
> > > > - Patch 5: Split this patch from the patch number 4, to keep bug fix
> > > >   separate from style fix.  
> > > 
> > > Jonathan, this version is good to go in my opinion except patch 6
> > > ("iio: light: gp2ap020a00f: Fix possible error swallow").
> > > 
> > > Ethan, do *not* send a new version until we decide what to do with patch 6,
> > > and actually the rest may be applied by Jonathan if he is okay with them.  
> > 
> > It's patch 5, sorry for the confusion.
> 
> I tweaked it and applied the series to the testing branch of iio.git

Ah, thank you!

-- 
With Best Regards,
Andy Shevchenko