Re: [PATCH] i2c: busses: Fix a reference count leak.

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

 



On Mon, Jun 15, 2020 at 06:31:28AM +0000, Aisheng Dong wrote:
> > From: Andy Duan <fugang.duan@xxxxxxx>
> > Sent: Monday, June 15, 2020 10:49 AM
> >
> > From: wu000273@xxxxxxx <wu000273@xxxxxxx> Sent: Sunday, June 14,
> > 2020 6:12 AM
> > > From: Qiushi Wu <wu000273@xxxxxxx>
> > >
> > > pm_runtime_get_sync() increments the runtime PM usage counter even
> > > when it returns an error code. Thus call pm_runtime_put_noidle() if
> > > pm_runtime_get_sync() fails.
> > >
> > > Fixes: 13d6eb20fc79 ("i2c: imx-lpi2c: add runtime pm support")
> > > Signed-off-by: Qiushi Wu <wu000273@xxxxxxx>
> > 
> > Again, which case can trigger the issue ?
> 
> It's just error handling improvement because pm_runtime_get_sync() will increase the
> reference count even it's failed.
> 
> I wonder if such de-reference can be better handled by pm runtime core code.
> Copy pm guys to comment.

I started a seperate thread:

https://lkml.org/lkml/2020/6/14/76

Still, on-going discussion if the proper fix is to remove the error
check.

Attachment: signature.asc
Description: PGP signature


[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