linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pantelis Antoniou <panto@antoniou-consulting.com>
To: Tony Lindgren <tony@atomide.com>
Cc: Benoit Cousson <b-cousson@ti.com>,
	linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org,
	Matt Porter <mporter@ti.com>,
	Koen Kooi <koen@dominion.thruhere.net>,
	Shubhrajyoti D <shubhrajyoti@ti.com>
Subject: Re: [PATCH 2/3] OMAP i2c: pinctrl-ify i2c-omap.c
Date: Tue, 18 Sep 2012 22:37:22 +0300	[thread overview]
Message-ID: <34F7CFB5-4E48-4B74-99D3-3C1999A0B3B3@antoniou-consulting.com> (raw)
In-Reply-To: <20120918182358.GZ11762@atomide.com>

Hi Tony,

On Sep 18, 2012, at 9:23 PM, Tony Lindgren wrote:

> * Pantelis Antoniou <panto@antoniou-consulting.com> [120918 11:13]:
>> Add support for pinctrl mux settings in the OMAP I2C driver.
>> If no such pinctl bindings are found a warning message is printed.
>> 
>> Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
>> 
>> ---
>> drivers/i2c/busses/i2c-omap.c | 7 +++++++
>> 1 file changed, 7 insertions(+)
>> 
>> diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c
>> index b149e32..f722478 100644
>> --- a/drivers/i2c/busses/i2c-omap.c
>> +++ b/drivers/i2c/busses/i2c-omap.c
>> @@ -43,6 +43,8 @@
>> #include <linux/slab.h>
>> #include <linux/i2c-omap.h>
>> #include <linux/pm_runtime.h>
>> +#include <linux/pinctrl/consumer.h>
>> +#include <linux/err.h>
>> 
>> /* I2C controller revisions */
>> #define OMAP_I2C_OMAP1_REV_2		0x20
>> @@ -1057,6 +1059,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);
>> @@ -1197,6 +1200,10 @@ 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, "pins are not configured from the driver\n");
>> +
>> 	pm_runtime_mark_last_busy(dev->dev);
>> 	pm_runtime_put_autosuspend(dev->dev);
> 
> This must be just a warning here as otherwise things will break
> badly for drivers doing pinmuxing in bootloader only. Other than
> that:
> 

It is just a warning indeed. Not many boards do the pinctrl dance yet.

> Acked-by: Tony Lindgren <tony@atomide.com>

Regards

-- Pantelis

  reply	other threads:[~2012-09-18 19:37 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-19 16:07 [PATCH 0/3] Pinctrl-fy OMAP I2C driver Pantelis Antoniou
2012-09-19 16:07 ` [PATCH 1/3] pinctrl: pinctrl-single must be initialized early Pantelis Antoniou
2012-09-18 18:21   ` Tony Lindgren
2012-09-18 19:10     ` Pantelis Antoniou
2012-09-21  0:09       ` Tony Lindgren
2012-09-19 16:07 ` [PATCH 2/3] OMAP i2c: pinctrl-ify i2c-omap.c Pantelis Antoniou
2012-09-18 18:23   ` Tony Lindgren
2012-09-18 19:37     ` Pantelis Antoniou [this message]
2012-09-19  7:09   ` Shubhrajyoti
2012-09-19  8:34     ` Pantelis Antoniou
2012-09-20  6:34     ` [PATCH 0/2] Pinctrl-fy OMAP I2C driver (V2) Pantelis Antoniou
2012-09-20  6:34       ` [PATCH 1/2] pinctrl: pinctrl-single must be initialized early Pantelis Antoniou
2012-09-20  6:34       ` [PATCH 2/2] OMAP i2c: pinctrl-ify i2c-omap.c Pantelis Antoniou
2012-09-19 10:13         ` Shubhrajyoti Datta
2012-09-19 17:24         ` Tony Lindgren
2012-09-21  7:29   ` [PATCH 2/3] " Peter Ujfalusi
2012-09-21  7:34     ` Pantelis Antoniou
2012-09-19 16:07 ` [PATCH 3/3] i2c: OMAP fix driver initialization message Pantelis Antoniou
2012-09-18 18:24   ` Tony Lindgren
2012-09-18 19:24   ` a0919096
2012-09-19  9:57     ` 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=34F7CFB5-4E48-4B74-99D3-3C1999A0B3B3@antoniou-consulting.com \
    --to=panto@antoniou-consulting.com \
    --cc=b-cousson@ti.com \
    --cc=koen@dominion.thruhere.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=mporter@ti.com \
    --cc=shubhrajyoti@ti.com \
    --cc=tony@atomide.com \
    /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;
as well as URLs for NNTP newsgroup(s).