lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Mon, 30 May 2022 12:28:59 +0200
From:   Pavel Machek <pavel@...x.de>
To:     Dmitry Torokhov <dmitry.torokhov@...il.com>
Cc:     Pavel Machek <pavel@...x.de>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        linux-kernel@...r.kernel.org, stable@...r.kernel.org,
        Zheng Yongjun <zhengyongjun3@...wei.com>,
        Sasha Levin <sashal@...nel.org>
Subject: Re: [PATCH 4.14 04/33] Input: stmfts - fix reference leak in
 stmfts_input_open

Hi!

> > > From: Zheng Yongjun <zhengyongjun3@...wei.com>
> > > 
> > > [ Upstream commit 26623eea0da3476446909af96c980768df07bbd9 ]
> > > 
> > > pm_runtime_get_sync() will increment pm usage counter even it
> > > failed. Forgetting to call pm_runtime_put_noidle will result
> > > in reference leak in stmfts_input_open, so we should fix it.
> > 
> > This is wrong, AFAICT.
> 
> Yes, I think you are right. How about below?

Looks good to me.

> Input: stmfts - do not leave device disabled in stmfts_input_open
> 
> From: Dmitry Torokhov <dmitry.torokhov@...il.com>
> 
> The commit 26623eea0da3 attempted to deal with potential leak of runtime
> PM counter when opening the touchscreen device, however it ended up
> erroneously dropping the counter in the case of successfully enabling the
> device.
> 
> Let's address this by using pm_runtime_resume_and_get() and then executing
> pm_runtime_put_sync() only when we fail to send "sense on" command to the
> device.
> 
> Fixes: 26623eea0da3 ("Input: stmfts - fix reference leak in stmfts_input_open")

Reviewed-by: Pavel Machek <pavel@...x.de>

Thank you,
								Pavel
-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany

Download attachment "signature.asc" of type "application/pgp-signature" (196 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ