Re: [PATCH v4 next 3/6] iio: sca3000: make stop_all_interrupts() return void
From: Andy Shevchenko
Date: Wed Feb 04 2026 - 05:01:30 EST
On Wed, Feb 04, 2026 at 02:50:54PM +0530, Harshit Mogalapalli wrote:
> On 04/02/26 14:33, Andy Shevchenko wrote:
> > On Tue, Feb 03, 2026 at 10:11:58PM -0800, Harshit Mogalapalli wrote:
...
> > > ret = sca3000_read_data_short(st, SCA3000_REG_INT_MASK_ADDR, 1);
> > > if (ret)
> > > - goto error_ret;
> >
> > > -error_ret:
> > > + goto out_unlock;
> >
> > > +out_unlock:
> >
> > While this is correct change semantically, it's not needed as very soon
> > the other patch drops this for good, hence leave the label name unmodified.
>
> Agree, I was doubtful on which is the preferred approach as its not really a
> return anymore. But thanks for explaining.
The common sense says that we need to avoid ping-pong coding (*) in the series.
*It's when one patch in the series adds the code that's going to be deleted or
heavily modified just later in the very same series.
--
With Best Regards,
Andy Shevchenko