All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ben Dooks <ben.dooks@codethink.co.uk>
To: Wolfram Sang <wsa@the-dreams.de>
Cc: linux-kernel@lists.codethink.co.uk, linux-sh@vger.kernel.org,
	horms+renesas@verge.net.au, linux-i2c@vger.kernel.org
Subject: Re: [PATCH 4/4] i2c: rcar: use devm_clk_get to ensure clock is properly ref-counted
Date: Sun, 26 Jan 2014 15:33:05 +0000	[thread overview]
Message-ID: <52E52AB1.7070309@codethink.co.uk> (raw)
In-Reply-To: <20140124171254.GE2629@katana>

On 24/01/14 17:12, Wolfram Sang wrote:
> On Fri, Jan 17, 2014 at 06:11:38PM +0000, Ben Dooks wrote:
>> The current i2c-rcar driver does clk_get() without a corresponding
>> clk_put(). Add the clk to the driver private data and then get it
>> with the devm functions so that it is released when the driver is
>> unbound.
>>
>
>>
>> +	priv->clk = devm_clk_get(dev, NULL);
>> +	if (IS_ERR(priv->clk)) {
>> +		dev_err(dev, "cannot get clock\n");
>> +		return -ENOENT;
>> +	}
>
> Return the error here?

Yes, will change this to be PTR_ERR(priv->clk) and re-send

-- 
Ben Dooks				http://www.codethink.co.uk/
Senior Engineer				Codethink - Providing Genius

      reply	other threads:[~2014-01-26 15:33 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-17 18:11 Renesas i2c patches, R8A7790 support and Lager i2c enablemenet Ben Dooks
2014-01-17 18:11 ` [PATCH 3/4] i2c: rcar: do not print error if device nacks transfer Ben Dooks
2014-01-24 17:11   ` Wolfram Sang
2014-01-24 17:11     ` Wolfram Sang
2014-01-26 15:32     ` Ben Dooks
2014-01-26 15:57     ` Ben Dooks
2014-01-17 18:11 ` [PATCH 4/4] i2c: rcar: use devm_clk_get to ensure clock is properly ref-counted Ben Dooks
     [not found]   ` <1389982298-23143-5-git-send-email-ben.dooks-4yDnlxn2s6sWdaTGBSpHTA@public.gmane.org>
2014-01-24 17:12     ` Wolfram Sang
2014-01-24 17:12       ` Wolfram Sang
2014-01-26 15:33       ` Ben Dooks [this message]

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=52E52AB1.7070309@codethink.co.uk \
    --to=ben.dooks@codethink.co.uk \
    --cc=horms+renesas@verge.net.au \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@lists.codethink.co.uk \
    --cc=linux-sh@vger.kernel.org \
    --cc=wsa@the-dreams.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.