public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Felipe Balbi <balbi@ti.com>
To: Pantelis Antoniou <panto@antoniou-consulting.com>
Cc: Tony Lindgren <tony@atomide.com>,
	"Ben Dooks (embedded platforms)" <ben-linux@fluff.org>,
	"Wolfram Sang (embedded platforms)" <w.sang@pengutronix.de>,
	<linux-omap@vger.kernel.org>, <linux-i2c@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>,
	Koen Kooi <koen@dominion.thruhere.net>,
	Matt Porter <mporter@ti.com>, Russ Dill <Russ.Dill@ti.com>
Subject: Re: [PATCH] i2c: pinctrl-ify i2c-omap.c
Date: Tue, 30 Oct 2012 20:53:03 +0200	[thread overview]
Message-ID: <20121030185303.GD4804@arwen.pp.htv.fi> (raw)
In-Reply-To: <1351698930-3797-1-git-send-email-panto@antoniou-consulting.com>

[-- Attachment #1: Type: text/plain, Size: 1645 bytes --]

Hi,

On Wed, Oct 31, 2012 at 05:55:30PM +0200, Pantelis Antoniou wrote:
> Enable pinctrl for i2c-omap.
> 
> Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
> ---
>  drivers/i2c/busses/i2c-omap.c | 10 ++++++++++
>  1 file changed, 10 insertions(+)
> 
> diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
> index db31eae..4c38aa0 100644
> --- a/drivers/i2c/busses/i2c-omap.c
> +++ b/drivers/i2c/busses/i2c-omap.c
> @@ -44,6 +44,8 @@
>  #include <linux/i2c-omap.h>
>  #include <linux/pm_runtime.h>
>  #include <linux/pm_qos.h>
> +#include <linux/pinctrl/consumer.h>
> +#include <linux/err.h>
>  
>  /* I2C controller revisions */
>  #define OMAP_I2C_OMAP1_REV_2		0x20
> @@ -1064,6 +1066,7 @@ omap_i2c_probe(struct platform_device *pdev)
>  	const struct of_device_id *match;
>  	int irq;
>  	int r;
> +	struct pinctrl *pinctrl;
>  
>  	/* NOTE: driver uses the static register mapping */
>  	mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> @@ -1202,6 +1205,13 @@ omap_i2c_probe(struct platform_device *pdev)
>  
>  	of_i2c_register_devices(adap);
>  
> +	pinctrl = devm_pinctrl_get_select_default(&pdev->dev);
> +	if (IS_ERR(pinctrl))
> +		dev_warn(dev->dev, "unable to select pin group\n");

if we continue anyway, should this be dev_warn() ? Would you consider
dev_dbg() instead ?

> +	dev_info(dev->dev, "bus %d rev%d.%d.%d at %d kHz\n", adap->nr,
> +		 dev->dtrev, dev->rev >> 4, dev->rev & 0xf, dev->speed);

this dev_info() doesn't look like it's part of $subject. Care to, at
least, add a reasoning for adding this to commit log ?

-- 
balbi

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  parent reply	other threads:[~2012-10-30 18:59 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-31 15:55 [PATCH] i2c: pinctrl-ify i2c-omap.c Pantelis Antoniou
2012-10-30 18:17 ` Tony Lindgren
2012-10-30 18:53 ` Felipe Balbi [this message]
2012-10-30 18:59   ` Pantelis Antoniou
2012-10-30 19:13   ` Porter, Matt
2012-10-30 20:14 ` Sebastien Guiriec
2012-10-30 20:18   ` Pantelis Antoniou

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=20121030185303.GD4804@arwen.pp.htv.fi \
    --to=balbi@ti.com \
    --cc=Russ.Dill@ti.com \
    --cc=ben-linux@fluff.org \
    --cc=koen@dominion.thruhere.net \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=mporter@ti.com \
    --cc=panto@antoniou-consulting.com \
    --cc=tony@atomide.com \
    --cc=w.sang@pengutronix.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox