lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:	Mon, 7 Feb 2011 16:22:55 +0800
From:	Jeremy Kerr <jeremy.kerr@...onical.com>
To:	Dima Zavin <dima@...roid.com>
Cc:	Ben Dooks <ben-linux@...ff.org>,
	Russell King <linux@....linux.org.uk>,
	Vincent Guittot <vincent.guittot@...aro.org>,
	Ben Herrenschmidt <benh@...nel.crashing.org>,
	Paul Mundt <lethal@...ux-sh.org>,
	Nicolas Pitre <nicolas.pitre@...aro.org>,
	Lorenzo Pieralisi <Lorenzo.Pieralisi@....com>,
	"Uwe Kleine-K├Ânig" 
	<u.kleine-koenig@...gutronix.de>,
	linux-arm-kernel@...ts.infradead.org,
	Saravana Kannan <skannan@...eaurora.org>,
	Sascha Hauer <s.hauer@...gutronix.de>,
	linux-sh@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [RFC,PATCH 1/3] Add a common struct clk

Hi Dima,

> > +int clk_prepare(struct clk *clk)
> > +{
> > +       int ret = 0;
> > +
> > +       if (!clk->ops->prepare)
> > +               return 0;
> > +
> > +       mutex_lock(&clk->prepare_lock);
> > +       if (clk->prepare_count == 0)
> > +               ret = clk->ops->prepare(clk);
> > +
> > +       if (!ret)
> > +               clk->prepare_count++;
> > +       mutex_unlock(&clk->prepare_lock);
> > +
> > +       return 0;
> 
> return ret;

Good catch, thanks.


Jeremy
--
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