Re: [PATCH 01/04] Driver Core: Add platform device arch data

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2009/5/29 Rafael J. Wysocki <rjw@xxxxxxx>:
> On Wednesday 27 May 2009, Magnus Damm wrote:
>> From: Magnus Damm <damm@xxxxxxxxxx>
>>
>> Allow architecture specific data in struct platform_device.
>> Platform device data is needed by the runtime pm code. A similar
>> struct already exists for struct device.
>>
>> The architecture specific asm/device.h file needs to provide
>> struct pdev_archdata if CONFIG_HAVE_PLATFORM_DEVICE_DATA is set.
>>
>> Signed-off-by: Magnus Damm <damm@xxxxxxxxxx>
>> ---
>>
>>  Optionally we can make use of struct device archdata instead,
>>  but since the runtime device pm is limited to platform devices
>>  it makes sense to make this data platform device specific imo.
>>
>>  arch/Kconfig                    |    3 +++
>>  include/linux/platform_device.h |    5 +++++
>>  2 files changed, 8 insertions(+)
>>
>> --- 0001/arch/Kconfig
>> +++ work/arch/Kconfig 2009-05-15 14:51:35.000000000 +0900
>> @@ -112,3 +112,6 @@ config HAVE_DMA_API_DEBUG
>>
>>  config HAVE_DEFAULT_NO_SPIN_MUTEXES
>>       bool
>> +
>> +config HAVE_PLATFORM_DEVICE_ARCHDATA
>
> Hmm.  Do we really need yet another CONFIG_ option for that?

I don't think we need a total of 3 different config options for the
platform device pm stuff, but I do think it makes sense to handle the
platform archdata separately. Not sure which is the best way though,
the #ifdefery is not very pretty. Maybe the best solution is just to
drop the Kconfig stuff and add empty structures to all architecture
versions of asm/device.h.

Any suggestions?

Thanks!

/ magnus
_______________________________________________
linux-pm mailing list
linux-pm@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/linux-pm


[Index of Archives]     [Linux ACPI]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [CPU Freq]     [Kernel Newbies]     [Fedora Kernel]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux