lkml.org 
[lkml]   [2012]   [Mar]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Regulator supplies when using Device Tree
On 3/29/2012 4:11 AM, Mark Brown wrote:
> On Wed, Mar 28, 2012 at 05:06:48PM -0700, Michael Bohan wrote:
>
>> Are you aware of any other examples of submitted drivers with Device
>> Tree support that implement regulator devices that optionally have
>> an upstream supply? I looked at your tree recently and couldn't see
>> any such cases.
>
> No, pretty much any drivers which optionally have an upstream supply
> would be buggy and should therefore run into trouble during review.

Can you please elaborate on why this is a bad design? We have always
used this model in the past, and the regulator framework is happy to
support it.

We have identical hardware blocks that can be positioned to take a
supply or not. So are you proposing we copy / paste our driver so that
in one case rdesc->supply_name is NULL and the other case a valid supply
name? I'm guessing you aren't implying this, but what alternatives do
you suggest to support such a model?

In the thread mentioned by Rajendra, part of the motivation for putting
the supply_name in the driver struct was 'no code changes in the
individual drivers'. But that's exactly what we have here.

http://www.spinics.net/lists/linux-omap/msg58673.html

I was hoping that we could continue to treat regulator supplies as
normal supplies, but somehow allow the framework to determine whether a
regulator supply exists or not in the Device Tree configuration so the
driver doesn't have to.

Thanks,
Mike

--
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.


\
 
 \ /
  Last update: 2012-03-30 03:21    [W:0.054 / U:0.292 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site