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] [thread-next>] [day] [month] [year] [list]
Message-ID: <aKgHkAWW0puXbZkv@bhairav-test.ee.iitb.ac.in>
Date: Fri, 22 Aug 2025 11:30:48 +0530
From: Akhilesh Patil <akhilesh@...iitb.ac.in>
To: Mikko Perttunen <mperttunen@...dia.com>
Cc: thierry.reding@...il.com, airlied@...il.com, simona@...ll.ch,
	dri-devel@...ts.freedesktop.org, linux-tegra@...r.kernel.org,
	linux-kernel@...r.kernel.org, akhileshpatilvnit@...il.com,
	skhan@...uxfoundation.org
Subject: Re: [PATCH] gpu: host1x: use dev_err_probe() in probe path

On Fri, Aug 22, 2025 at 12:18:38PM +0900, Mikko Perttunen wrote:
> On Monday, July 28, 2025 9:15 AM Akhilesh Patil wrote:
> > Use dev_err_probe() helper as recommended by core driver model in
> > drivers/base/core.c to handle deferred probe error. Improve code
> > consistency and debuggability using standard helper.
> > 
> > Signed-off-by: Akhilesh Patil <akhilesh@...iitb.ac.in>
> > ---
> >  drivers/gpu/host1x/dev.c | 6 +-----
> >  1 file changed, 1 insertion(+), 5 deletions(-)
> > 
> > diff --git a/drivers/gpu/host1x/dev.c b/drivers/gpu/host1x/dev.c
> > index 1f93e5e276c0..e6f3cbeb9ae5 100644
> > --- a/drivers/gpu/host1x/dev.c
> > +++ b/drivers/gpu/host1x/dev.c
> > @@ -587,11 +587,7 @@ static int host1x_probe(struct platform_device *pdev)
> >  	host->clk = devm_clk_get(&pdev->dev, NULL);
> >  	if (IS_ERR(host->clk)) {
> >  		err = PTR_ERR(host->clk);
> > -
> > -		if (err != -EPROBE_DEFER)
> > -			dev_err(&pdev->dev, "failed to get clock: %d\n", 
> err);
> > -
> > -		return err;
> > +		return dev_err_probe(&pdev->dev, err, "failed to get clock: 
> %d\n", err);
> 
> AIUI, dev_err_probe already prints err, so we don't need to repeat it in the 
> message. With that, PTR_ERR(host->clk) can also be inlined into the 
> dev_err_probe call.
ACK. Thanks for the review.
Posted v2 addressing this with 6.17-rc2 rebased build tested.

Regards,
Akhilesh
> 
> Cheers,
> Mikko
> 
> >  	}
> > 
> >  	err = host1x_get_resets(host);
> 
> 
> 
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ