Re: [PATCH] i2c: busses: Fix error handling in synquacer_i2c_probe

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Mar 16, 2022 at 9:18 AM Miaoqian Lin <linmq006@xxxxxxxxx> wrote:
>
> Hi, Andy Shevchenko
>
> On Wed, Mar 16, 2022 at 09:04:06AM +0200, Andy Shevchenko wrote:
> >
> > > In the error handling path, the clk_prepare_enable() function
> > > call should be balanced by a corresponding 'clk_disable_unprepare()'
> > > call, as already done in the remove function.
> >
> >
> > It’s not good to mix devm approach with non-devm.
> >
> Thanks for your review. I'm sorry, I don't quite understand. Could you please explain more? What functions are your referring to? Thanks.

Your entire patch is broken. The error handling in ->probe() and
complete ->remove() now have asymmetrical ordering.

On top of that the CCF is NULL aware (and error pointer IIRC), so no
need to have additional checks.

-- 
With Best Regards,
Andy Shevchenko




[Index of Archives]     [Linux GPIO]     [Linux SPI]     [Linux Hardward Monitoring]     [LM Sensors]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux