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: <87k34loxp2.fsf@dell.be.48ers.dk>
Date:	Tue, 30 Sep 2014 18:55:05 +0200
From:	Peter Korsgaard <peter@...sgaard.com>
To:	Boris Brezillon <boris.brezillon@...e-electrons.com>
Cc:	Nicolas Ferre <nicolas.ferre@...el.com>,
	Jean-Christophe Plagniol-Villard <plagnioj@...osoft.com>,
	Alexandre Belloni <alexandre.belloni@...e-electrons.com>,
	Andrew Victor <linux@...im.org.za>,
	Peter Korsgaard <jacmet@...site.dk>,
	Matt Mackall <mpm@...enic.com>,
	Herbert Xu <herbert@...dor.apana.org.au>,
	linux-arm-kernel@...ts.infradead.org,
	Rob Herring <robh+dt@...nel.org>,
	Pawel Moll <pawel.moll@....com>,
	Mark Rutland <mark.rutland@....com>,
	Ian Campbell <ijc+devicetree@...lion.org.uk>,
	Kumar Gala <galak@...eaurora.org>, devicetree@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/6] hwrng: atmel: use clk_prepapre_enable/_disable_unprepare

>>>>> "Boris" == Boris Brezillon <boris.brezillon@...e-electrons.com> writes:

 > Use clk_prepapre_enable/_disable_unprepare instead of clk_enable/disable
 > to work properly with the CCF.

s/prepapre/prepare/

Other than that, looks fine to me.

Acked-by: Peter Korsgaard <peter@...sgaard.com>

 > Signed-off-by: Boris Brezillon <boris.brezillon@...e-electrons.com>
 > ---
 >  drivers/char/hw_random/atmel-rng.c | 8 ++++----
 >  1 file changed, 4 insertions(+), 4 deletions(-)

 > diff --git a/drivers/char/hw_random/atmel-rng.c b/drivers/char/hw_random/atmel-rng.c
 > index 851bc7e..644ec48 100644
 > --- a/drivers/char/hw_random/atmel-rng.c
 > +++ b/drivers/char/hw_random/atmel-rng.c
 > @@ -67,7 +67,7 @@ static int atmel_trng_probe(struct platform_device *pdev)
 >  	if (IS_ERR(trng->clk))
 >  		return PTR_ERR(trng->clk);
 
 > -	ret = clk_enable(trng->clk);
 > +	ret = clk_prepare_enable(trng->clk);
 >  	if (ret)
 >  		return ret;
 
 > @@ -95,7 +95,7 @@ static int atmel_trng_remove(struct platform_device *pdev)
 >  	hwrng_unregister(&trng->rng);
 
 >  	writel(TRNG_KEY, trng->base + TRNG_CR);
 > -	clk_disable(trng->clk);
 > +	clk_disable_unprepare(trng->clk);
 
 >  	return 0;
 >  }
 > @@ -105,7 +105,7 @@ static int atmel_trng_suspend(struct device *dev)
 >  {
 >  	struct atmel_trng *trng = dev_get_drvdata(dev);
 
 > -	clk_disable(trng->clk);
 > +	clk_disable_unprepare(trng->clk);
 
 >  	return 0;
 >  }
 > @@ -114,7 +114,7 @@ static int atmel_trng_resume(struct device *dev)
 >  {
 >  	struct atmel_trng *trng = dev_get_drvdata(dev);
 
 > -	return clk_enable(trng->clk);
 > +	return clk_prepare_enable(trng->clk);
 >  }
 
 >  static const struct dev_pm_ops atmel_trng_pm_ops = {
 > -- 
 > 1.9.1



-- 
Bye, Peter Korsgaard
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ