[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20081024194415.GB6621@sirena.org.uk>
Date: Fri, 24 Oct 2008 20:44:16 +0100
From: Mark Brown <broonie@...ena.org.uk>
To: Jonathan Cameron <jic23@....ac.uk>
Cc: Liam Girdwood <lrg@...nel.org>,
Jonathan Cameron <Jonathan.Cameron@...il.com>,
LKML <linux-kernel@...r.kernel.org>,
eric miao <eric.y.miao@...il.com>
Subject: Re: Da903x regulator driver. Bug?
On Fri, Oct 24, 2008 at 07:53:37PM +0100, Jonathan Cameron wrote:
> >> is 2 layers down rather than one requiring quite a few changes
> >> to
> >> struct device *da9034_dev = rdev_get_dev(rdev)->parent->parent;
> >> from
> >> struct device *da9034_dev = rdev_get_dev(rdev)->parent;
> >> So either a change to the regulator framework is needed to
> >> allow mfd's or these extra ->parent lines need to go in in lots
> >> of places.
> >> Which do people prefer?
> > Could you fix in a similar method to the wm8350/wm8400.
> Based on a quick look, I think this involves carrying around
> an additional copy of the device pointer inside the driver data.
> If so that would indeed work.
Yes, I'm actively using these. I had been considering going back and
removing the extra layer of platform device from the code for WM8350 and
WM8400 since there is now less benefit to it but I would probably still
continue to use the driver_data to store the pointer to the wm8350 data
since I find that gives clear code.
The current situation was a minimal adaption to avoid churn in the core
API close to release - previously the regulator had been forced to be a
platform device but this was changed since we have to allocate a new
device when registering the regulator in order to have the class work in
sysfs.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists