From: Russell King - ARM Linux <linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org>
To: Barry Song <Barry.Song-kQvG35nSl+M@public.gmane.org>
Cc: ben-i2c-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org,
linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
Xiangzhen Ye <Xiangzhen.Ye-kQvG35nSl+M@public.gmane.org>,
w.sang-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org,
workgroup.linux-kQvG35nSl+M@public.gmane.org,
Zhiwu Song <Zhiwu.Song-kQvG35nSl+M@public.gmane.org>,
omaplinuxkernel-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
Barry Song <Baohua.Song-kQvG35nSl+M@public.gmane.org>,
jamie-wmLquQDDieKakBO8gow8eQ@public.gmane.org,
Yuping Luo <Yuping.Luo-kQvG35nSl+M@public.gmane.org>,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Subject: Re: [PATCH v4] I2C: add CSR SiRFprimaII on-chip I2C controllers driver
Date: Tue, 20 Dec 2011 20:07:50 +0000 [thread overview]
Message-ID: <20111220200750.GA2577@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <1323852927-13521-1-git-send-email-Barry.Song-kQvG35nSl+M@public.gmane.org>
On Wed, Dec 14, 2011 at 04:55:27PM +0800, Barry Song wrote:
> +static int __devinit i2c_sirfsoc_probe(struct platform_device *pdev)
> +{
> + struct clk *clk;
> +
> + clk = clk_get(&pdev->dev, NULL);
> + err = clk_prepare(clk);
> + err = clk_enable(clk);
...
> + clk_disable(clk);
> +
> + dev_info(&pdev->dev, " I2C adapter ready to operate\n");
> +
> + return 0;
> +}
> +
> +static int __devexit i2c_sirfsoc_remove(struct platform_device *pdev)
> +{
> + clk_disable(siic->clk);
> + clk_unprepare(siic->clk);
> + clk_put(siic->clk);
This doesn't look right - look at the state which you leave the clk in
upon successful probe, and now look at what you do when you do a remove.
It seems that you disable an already disabled clock to me.
next prev parent reply other threads:[~2011-12-20 20:07 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-14 8:55 [PATCH v4] I2C: add CSR SiRFprimaII on-chip I2C controllers driver Barry Song
[not found] ` <1323852927-13521-1-git-send-email-Barry.Song-kQvG35nSl+M@public.gmane.org>
2011-12-20 13:11 ` Barry Song
2011-12-20 20:07 ` Russell King - ARM Linux [this message]
[not found] ` <20111220200750.GA2577-l+eeeJia6m9vn6HldHNs0ANdhmdF6hFW@public.gmane.org>
2011-12-21 3:29 ` Barry Song
[not found] ` <CAGsJ_4y8vwrK=UD8a10gf2aN=O3hs_R_jYBKeFYf0v+gk0hiuQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-12-21 3:34 ` Richard Zhao
[not found] ` <20111221033444.GH15863-iWYTGMXpHj9ITqJhDdzsOjpauB2SiJktrE5yTffgRl4@public.gmane.org>
2011-12-21 3:47 ` Shawn Guo
[not found] ` <20111221034753.GC5983-rvtDTF3kK1ictlrPMvKcciBecyulp+rMXqFh9Ls21Oc@public.gmane.org>
2011-12-22 12:08 ` Barry Song
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20111220200750.GA2577@n2100.arm.linux.org.uk \
--to=linux-lfz/pmaqli7xmaaqvzeohq@public.gmane.org \
--cc=Baohua.Song-kQvG35nSl+M@public.gmane.org \
--cc=Barry.Song-kQvG35nSl+M@public.gmane.org \
--cc=Xiangzhen.Ye-kQvG35nSl+M@public.gmane.org \
--cc=Yuping.Luo-kQvG35nSl+M@public.gmane.org \
--cc=Zhiwu.Song-kQvG35nSl+M@public.gmane.org \
--cc=ben-i2c-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org \
--cc=jamie-wmLquQDDieKakBO8gow8eQ@public.gmane.org \
--cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
--cc=linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=omaplinuxkernel-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=w.sang-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org \
--cc=workgroup.linux-kQvG35nSl+M@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox