From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: Robin Getz <rgetz@blackfin.uclinux.org>
Cc: Mike Frysinger <vapier@gentoo.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
Liam Girdwood <lrg@slimlogic.co.uk>,
"uclinux-dist-devel@blackfin.uclinux.org"
<uclinux-dist-devel@blackfin.uclinux.org>,
"Zhang, Sonic" <Sonic.Zhang@analog.com>
Subject: Re: [PATCH 1/2] regulator: new driver for the AD5398 and AD5821
Date: Thu, 3 Jun 2010 20:08:59 +0100 [thread overview]
Message-ID: <20100603190858.GK2762@rakim.wolfsonmicro.main> (raw)
In-Reply-To: <201006031459.53275.rgetz@blackfin.uclinux.org>
On Thu, Jun 03, 2010 at 02:59:53PM -0400, Robin Getz wrote:
> On Tue 1 Jun 2010 10:37, Mark Brown pondered:
> > Why are the current bits and offset being suppied as platform data? I
> > would *very* strongly expect that the location of the control in the
> > register will be fixed by the device type and should therefore be
> > figured out by the driver. Having the machine specifying this seems
> > redundant and error prone.
> Since the parts are general purpose (their not PMU, but people use them to
> build their own PCB defined power management system) - so it depends on the
> PCB implementation...
Please look more closely at what's actually being done by the code here.
This is controlling the location of the bitfields in the register map.
It would be exceptionally unusal for the PCB design and layout to affect
the register map of the device at all - this will be fixed in silicon no
matter how the system is wired up. Even without a regulator framework
there would be no need to specify where the bitfields in the register
map are located via platform data.
As far as system specific integration goes the regulator driver should
only be worrying about the properties of the chip, other parts of the
regulator API handle the board-specific setup.
> http://www.analog.com/ad5398
> http://www.analog.com/ad5821
> are both I2C D/A Converter, with 120mA sink capability
This is not at all unusual for drivers/regulator except in that it's a
current regulator and voltage regulators are very much more common.
prev parent reply other threads:[~2010-06-03 19:09 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-01 13:33 [PATCH 1/2] regulator: new driver for the AD5398 and AD5821 Mike Frysinger
2010-06-01 13:33 ` [PATCH 2/2] regulator: new driver for the AD12{2,3,4,5}, AD150, and AD5022 parts Mike Frysinger
2010-06-01 14:25 ` Mark Brown
2010-06-02 4:52 ` Sonic Zhang
2010-06-01 14:37 ` [PATCH 1/2] regulator: new driver for the AD5398 and AD5821 Mark Brown
2010-06-02 8:29 ` Sonic Zhang
2010-06-03 18:59 ` Robin Getz
2010-06-03 19:08 ` Mark Brown [this message]
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=20100603190858.GK2762@rakim.wolfsonmicro.main \
--to=broonie@opensource.wolfsonmicro.com \
--cc=Sonic.Zhang@analog.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lrg@slimlogic.co.uk \
--cc=rgetz@blackfin.uclinux.org \
--cc=uclinux-dist-devel@blackfin.uclinux.org \
--cc=vapier@gentoo.org \
/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