devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Grant Likely <grant.likely@secretlab.ca>
To: "Cousson, Benoit" <b-cousson@ti.com>
Cc: "G, Manjunath Kondaiah" <manjugk@ti.com>,
	"devicetree-discuss@lists.ozlabs.org"
	<devicetree-discuss@lists.ozlabs.org>,
	"linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>
Subject: Re: [RFC/PATCH 10/14] dt: Add pd_size to AUXDATA structure
Date: Wed, 10 Aug 2011 07:16:30 -0600	[thread overview]
Message-ID: <CACxGe6tq43M6x-pQS4CHTsjiNORLgMzWXL7Hn0GzTFMNCrRzAA@mail.gmail.com> (raw)
In-Reply-To: <4E42723D.1010501@ti.com>

On Wed, Aug 10, 2011 at 5:57 AM, Cousson, Benoit <b-cousson@ti.com> wrote:
> On 8/9/2011 4:10 PM, G, Manjunath Kondaiah wrote:
>>
>> Add pd_size in the AUXDATA structure so that device drivers which require
>> platform_data size can pass along with AUXDATA.
>
> It is really needed by device driver? Or is it because omap_device_build is
> using platform_device_add_data that is doing a copy of the pdata and thus
> require the size?

Yes, I have the same question.  What is the reason for needing the
platform data size?

g.

>
>> Signed-off-by: G, Manjunath Kondaiah<manjugk@ti.com>
>> ---
>>  drivers/of/platform.c       |    2 ++
>>  include/linux/of_platform.h |    5 +++++
>>  2 files changed, 7 insertions(+), 0 deletions(-)
>>
>> diff --git a/drivers/of/platform.c b/drivers/of/platform.c
>> index ebbbf42..4b27286 100644
>> --- a/drivers/of/platform.c
>> +++ b/drivers/of/platform.c
>> @@ -565,6 +565,7 @@ static int of_platform_bus_create(struct device_node
>> *bus,
>>        struct platform_device *dev;
>>        const char *bus_id = NULL;
>>        void *platform_data = NULL;
>> +       int pd_size;
>
> Maybe platform_data_size will be a little bit more consistent?
>
> Regards,
> Benoit
>
>>        int id = -1;
>>        int rc = 0;
>>
>> @@ -588,6 +589,7 @@ static int of_platform_bus_create(struct device_node
>> *bus,
>>                bus_id = auxdata->name;
>>                id = auxdata->id;
>>                platform_data = auxdata->platform_data;
>> +               pd_size = auxdata->pd_size;
>>        }
>>
>>        if (of_device_is_compatible(bus, "arm,primecell")) {
>> diff --git a/include/linux/of_platform.h b/include/linux/of_platform.h
>> index 252246c..a3be980 100644
>> --- a/include/linux/of_platform.h
>> +++ b/include/linux/of_platform.h
>> @@ -47,6 +47,7 @@ struct of_dev_auxdata {
>>        char *name;
>>        int id;
>>        void *platform_data;
>> +       int pd_size;
>>  };
>>
>>  /* Macro to simplify populating a lookup table */
>> @@ -58,6 +59,10 @@ struct of_dev_auxdata {
>>        { .compatible = _compat, .phys_addr = _phys, .name = _name, \
>>          .id = _id, .platform_data = _pdata }
>>
>> +#define OF_DEV_AUXDATA_ID_PDSIZE(_compat,_phys,_name,_id,_pdata,_pd_size)
>> \
>> +       { .compatible = _compat, .phys_addr = _phys, .name = _name, \
>> +         .id = _id, .platform_data = _pdata, .pd_size = _pd_size }
>> +
>>  /**
>>   * of_platform_driver - Legacy of-aware driver for platform devices.
>>   *
>
>
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
>



-- 
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2011-08-10 13:16 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-09 14:10 [RFC/PATCH 00/14] dt: omap hwmod-dt binding and omap3 i2c1 dt support G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 01/14] OMAP: omap_device: replace _find_by_pdev() with to_omap_device() G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 02/14] OMAP: omap_device: replace debug/warning/error prints with dev_* macros G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 03/14] OMAP3: beagle: don't touch omap_device internals G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 04/14] OMAP: McBSP: use existing macros for converting between devices G, Manjunath Kondaiah
2011-08-10  7:07   ` Jarkko Nikula
2011-08-10 10:15     ` Cousson, Benoit
2011-08-10 16:05       ` G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 05/14] OMAP: omap_device: remove internal functions from omap_device.h G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 06/14] OMAP: omap_device: when building return platform_device instead of omap_device G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 07/14] ARM: platform_device: pdev_archdata: add omap_device pointer G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 08/14] omap2+: Use Kconfig symbol in Makefile instead of obj-y G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 09/14] dt: omap: prepare hwmod to support dt G, Manjunath Kondaiah
2011-08-10 11:51   ` Cousson, Benoit
2011-08-10 16:28     ` G, Manjunath Kondaiah
2011-08-10 17:11       ` Cousson, Benoit
2011-08-10 18:03         ` G, Manjunath Kondaiah
     [not found]           ` <CAC63_iSX0cjauOj=CcTABqgSWAgYRE_G7Qio5y2BrpeRnkhEWQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2011-08-10 18:06             ` Cousson, Benoit
2011-08-16 15:02       ` G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 10/14] dt: Add pd_size to AUXDATA structure G, Manjunath Kondaiah
     [not found]   ` <1312897232-4792-11-git-send-email-manjugk-l0cyMroinI0@public.gmane.org>
2011-08-10 11:57     ` Cousson, Benoit
2011-08-10 13:16       ` Grant Likely [this message]
2011-08-10 16:02         ` G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 11/14] dt: omap3: add soc file for handling i2c controllers G, Manjunath Kondaiah
2011-08-10 12:36   ` Cousson, Benoit
2011-08-10 16:57     ` G, Manjunath Kondaiah
2011-08-10 17:45       ` Cousson, Benoit
2011-08-16  6:32         ` G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 12/14] dt: omap3: beagle board: set clock freq for i2c devices G, Manjunath Kondaiah
2011-08-10 12:42   ` Cousson, Benoit
2011-08-10 16:45     ` G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 13/14] dt: omap3: add generic board file for dt support G, Manjunath Kondaiah
2011-08-09 14:10 ` [RFC/PATCH 14/14] dt: omap3: enable dt support for i2c1 controller G, Manjunath Kondaiah
2011-08-10 12:57   ` Cousson, Benoit
2011-08-16 18:44     ` G, Manjunath Kondaiah
2011-08-10  5:26 ` [RFC/PATCH 00/14] dt: omap hwmod-dt binding and omap3 i2c1 dt support Rajendra Nayak
2011-08-10  5:30   ` G, Manjunath Kondaiah
2011-08-10  5:39     ` Rajendra Nayak
2011-08-10  6:28       ` G, Manjunath Kondaiah

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=CACxGe6tq43M6x-pQS4CHTsjiNORLgMzWXL7Hn0GzTFMNCrRzAA@mail.gmail.com \
    --to=grant.likely@secretlab.ca \
    --cc=b-cousson@ti.com \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --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).