From: "Cousson, Benoit" <b-cousson@ti.com>
To: Grant Likely <grant.likely@secretlab.ca>
Cc: "G, Manjunath Kondaiah" <manjugk@ti.com>,
"devicetree-discuss@lists.ozlabs.org"
<devicetree-discuss@lists.ozlabs.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
"linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>,
"ben-linux@fluff.org" <ben-linux@fluff.org>
Subject: Re: [PATCH 4/4] dt: i2c-omap: Convert i2c driver to use device tree
Date: Thu, 28 Jul 2011 19:34:31 +0200 [thread overview]
Message-ID: <4E319DA7.5050608@ti.com> (raw)
In-Reply-To: <CACxGe6vG9BKUDvthOKFtx3u=Vq0EfBaZakxVqx8AYfRe_ruNdg@mail.gmail.com>
Hi Grant,
On 7/14/2011 1:20 AM, Grant Likely wrote:
> On Thu, Jul 14, 2011 at 7:06 AM, G, Manjunath Kondaiah<manjugk@ti.com> wrote:
>>
>> The i2c-omap driver is converted for supporting both
>> dt and non dt builds and driver is modified to use dt
>> data partially.
[...]
>> /* NOTE: driver uses the static register mapping */
>> mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
>> if (!mem) {
>> @@ -1011,11 +1026,25 @@ omap_i2c_probe(struct platform_device *pdev)
>> if (pdata != NULL) {
>> speed = pdata->clkrate;
>> dev->set_mpu_wkup_lat = pdata->set_mpu_wkup_lat;
>> +#if defined(CONFIG_OF)
>> + } else if (pdev->dev.of_node) {
>> + u32 prop;
>> + if (!of_property_read_u32(pdev->dev.of_node, "clock-frequency",
>> +&prop))
>> + speed = prop/100;
>> + else
>> + speed = 100;
Do we have to modify every drivers in order to take advantage of the DT bus?
Cannot we init the already existing pdata during device creation and let
the driver untouched?
I think it is a pity to add all that #ifdefry in the driver to be able
to support two kinds of bus.
Cannot we have an intermediate phase that will deal only with the device
creation with DT?
That will allow us to clean the omap_device creation from hwmod we have
today spread everywhere in plat-omap and mach-omap2.
Regards
Benoit
next prev parent reply other threads:[~2011-07-28 17:34 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-13 22:06 [PATCH 0/4] dt: omap3: add device tree support G, Manjunath Kondaiah
2011-07-13 22:06 ` [PATCH 1/4] dt: omap3: add SoC file for handling i2c controllers G, Manjunath Kondaiah
2011-07-13 22:57 ` Grant Likely
2011-07-13 22:58 ` Grant Likely
2011-07-14 3:51 ` G, Manjunath Kondaiah
2011-07-14 3:34 ` G, Manjunath Kondaiah
2011-07-13 22:06 ` [PATCH 2/4] dt: OMAP3: Beagle board: set clock freq for i2c devices G, Manjunath Kondaiah
2011-07-13 23:04 ` Grant Likely
2011-07-13 22:06 ` [PATCH 3/4] dt: omap3: add generic board file for dt support G, Manjunath Kondaiah
2011-07-13 23:15 ` Grant Likely
2011-07-14 8:53 ` [PATCH] omap2+: Use Kconfig symbol in Makefile instead of obj-y Tony Lindgren
[not found] ` <CACxGe6sELS=C==16TZ2pfrxJDDyqjS_qOwJUfwzwMO8hqo8Xag-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-07-16 19:54 ` [PATCH 3/4] dt: omap3: add generic board file for dt support G, Manjunath Kondaiah
2011-07-16 20:07 ` G, Manjunath Kondaiah
2011-07-17 5:13 ` Grant Likely
2011-07-18 9:07 ` Tony Lindgren
2011-07-19 21:34 ` Grant Likely
2011-07-21 7:18 ` Tony Lindgren
2011-07-21 8:55 ` Rajendra Nayak
[not found] ` <4E27E967.7090501-l0cyMroinI0@public.gmane.org>
2011-07-21 9:09 ` Felipe Balbi
2011-07-21 9:33 ` Rajendra Nayak
[not found] ` <4E27F264.4040409-l0cyMroinI0@public.gmane.org>
2011-07-21 9:39 ` Felipe Balbi
2011-07-28 18:20 ` Cousson, Benoit
2011-07-18 10:15 ` G, Manjunath Kondaiah
2011-07-19 21:36 ` Grant Likely
2011-07-19 5:58 ` G, Manjunath Kondaiah
2011-07-19 21:37 ` Grant Likely
[not found] ` <20110719213737.GQ6848-e0URQFbLeQY2iJbIjFUEsiwD8/FfD2ys@public.gmane.org>
2011-07-21 10:24 ` G, Manjunath Kondaiah
2011-07-21 23:53 ` Kevin Hilman
2011-07-13 22:06 ` [PATCH 4/4] dt: i2c-omap: Convert i2c driver to use device tree G, Manjunath Kondaiah
2011-07-13 23:20 ` Grant Likely
2011-07-28 17:34 ` Cousson, Benoit [this message]
2011-07-28 21:32 ` Grant Likely
2011-08-03 12:56 ` Cousson, Benoit
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=4E319DA7.5050608@ti.com \
--to=b-cousson@ti.com \
--cc=ben-linux@fluff.org \
--cc=devicetree-discuss@lists.ozlabs.org \
--cc=grant.likely@secretlab.ca \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-omap@vger.kernel.org \
--cc=manjugk@ti.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).