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]
Message-ID: <CAN4iqtTXfTqtQCpTg7hKAhRexOK6KnKJeys52t5BVn+7R-2gOA@mail.gmail.com>
Date: Tue, 17 Dec 2024 22:09:44 -0500
From: Mingwei Zheng <zmw12306@...il.com>
To: Greg KH <gregkh@...uxfoundation.org>
Cc: u.kleine-koenig@...libre.com, aaro.koskinen@....fi, balbi@...com, 
	linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org, 
	Jiasheng Jiang <jiashengjiangcool@...il.com>
Subject: Re: [PATCH] USB: phy: tahvo: Add check for clk_enable()

Hi Greg,

On Mon, Dec 16, 2024 at 2:56 AM Greg KH <gregkh@...uxfoundation.org> wrote:
>
> On Sun, Dec 15, 2024 at 04:00:06PM -0500, Mingwei Zheng wrote:
> > Add check for the return value of clk_enable() to catch the potential
> > error.
> >
> > Fixes: 9ba96ae5074c ("usb: omap1: Tahvo USB transceiver driver")
> > Signed-off-by: Mingwei Zheng <zmw12306@...il.com>
> > Signed-off-by: Jiasheng Jiang <jiashengjiangcool@...il.com>
> > ---
> >  drivers/usb/phy/phy-tahvo.c | 7 +++++--
> >  1 file changed, 5 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/usb/phy/phy-tahvo.c b/drivers/usb/phy/phy-tahvo.c
> > index ae7bf3ff89ee..0b8801318cd2 100644
> > --- a/drivers/usb/phy/phy-tahvo.c
> > +++ b/drivers/usb/phy/phy-tahvo.c
> > @@ -342,8 +342,11 @@ static int tahvo_usb_probe(struct platform_device *pdev)
> >       mutex_init(&tu->serialize);
> >
> >       tu->ick = devm_clk_get(&pdev->dev, "usb_l4_ick");
> > -     if (!IS_ERR(tu->ick))
> > -             clk_enable(tu->ick);
> > +     if (!IS_ERR(tu->ick)) {
> > +             ret = clk_enable(tu->ick);
> > +             if (ret)
> > +                     return ret;
> > +     }
>
> Same questions, why the signed-off-by order and how was this found and
> tested?
>
> thanks,
>
> greg k-h

We wrote the patch together so I listed both of our names.

We used a static analysis tool to find this. Additionally, we
validated the patch's correctness
using the built-in tests provided during the compilation process.

Please kindly let me know if you have any questions or suggestions. Thank you!


Best,
Mingwei

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ