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: <20201016115331.0dd4341e@linux-uq9g>
Date:   Fri, 16 Oct 2020 11:53:31 +0200
From:   Thomas Zimmermann <tzimmermann@...e.de>
To:     Xu Wang <vulab@...as.ac.cn>
Cc:     b.zolnierkie@...sung.com, pakki001@....edu, yuehaibing@...wei.com,
        linux-fbdev@...r.kernel.org, linux-omap@...r.kernel.org,
        linux-kernel@...r.kernel.org, dri-devel@...ts.freedesktop.org
Subject: Re: [PATCH] omapfb/dss: Remove redundant null check before
 clk_prepare_enable/clk_disable_unprepare

On Thu, 15 Oct 2020 10:08:27 +0200 Thomas Zimmermann <tzimmermann@...e.de>
wrote:

> On Wed, 14 Oct 2020 08:49:20 +0000 Xu Wang <vulab@...as.ac.cn> wrote:
> 
> > Because clk_prepare_enable() and clk_disable_unprepare() already checked
> > NULL clock parameter, so the additional checks are unnecessary, just
> > remove them.
> > 
> > Signed-off-by: Xu Wang <vulab@...as.ac.cn>
> 
> Reviewed-by: Thomas Zimmermann <tzimmermann@...e.de>
> 

Merged into drm-misc-next. Thanks!

> > ---
> >  drivers/video/fbdev/omap2/omapfb/dss/venc.c | 6 ++----
> >  1 file changed, 2 insertions(+), 4 deletions(-)
> > 
> > diff --git a/drivers/video/fbdev/omap2/omapfb/dss/venc.c
> > b/drivers/video/fbdev/omap2/omapfb/dss/venc.c index
> > 0b0ad20afd63..8895fb8493d8 100644 ---
> > a/drivers/video/fbdev/omap2/omapfb/dss/venc.c +++
> > b/drivers/video/fbdev/omap2/omapfb/dss/venc.c @@ -890,8 +890,7 @@ static
> > int venc_remove(struct platform_device *pdev) 
> >  static int venc_runtime_suspend(struct device *dev)
> >  {
> > -	if (venc.tv_dac_clk)
> > -		clk_disable_unprepare(venc.tv_dac_clk);
> > +	clk_disable_unprepare(venc.tv_dac_clk);
> >  
> >  	dispc_runtime_put();
> >  
> > @@ -906,8 +905,7 @@ static int venc_runtime_resume(struct device *dev)
> >  	if (r < 0)
> >  		return r;
> >  
> > -	if (venc.tv_dac_clk)
> > -		clk_prepare_enable(venc.tv_dac_clk);
> > +	clk_prepare_enable(venc.tv_dac_clk);
> >  
> >  	return 0;
> >  }
> 
> 
> 



-- 
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Maxfeldstr. 5, 90409 Nürnberg, Germany
(HRB 36809, AG Nürnberg)
Geschäftsführer: Felix Imendörffer

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ