[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150324164922.GM28604@pengutronix.de>
Date: Tue, 24 Mar 2015 17:49:22 +0100
From: Markus Pargmann <mpa@...gutronix.de>
To: Mark Brown <broonie@...nel.org>
Cc: Liam Girdwood <lgirdwood@...il.com>,
Wolfram Sang <wsa@...-dreams.de>, kernel@...gutronix.de,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] regulator: max8660: Remove boot_on handling
On Tue, Mar 24, 2015 at 09:22:27AM -0700, Mark Brown wrote:
> On Tue, Mar 24, 2015 at 01:08:02PM +0100, Markus Pargmann wrote:
>
> > boot_on is handled by the regulator core. It will call enable() on the
> > regulators that are specified to be boot_on. So we don't require any
> > additional handling in this driver
>
> > switch (pdata->subdevs[i].id) {
> > case MAX8660_V3:
> > - if (boot_on)
> > - max8660->shadow_regs[MAX8660_OVER1] |= 1;
> > - break;
> > -
>
> So, this is updating the register default value rather than writing to
> the device. That suggests that the purpose is to either avoid needless
> write outs to the device or something, or at the very least it's not a
> completely direct reimplementation of the core functionality. It is
> certainly underdocumented at the minute (and the driver probably wants
> to be converted to regmap) but this makes me a bit cautious about
> obvious cleanups missing something.
Sorry, this patch is wrong. I just realized that this chip is write-only
and has different regulators that share the same registers. So it is
impossible to selectively enable some regulators without accidentaly
disabling others that may be enabled. So the code is necessary.
Thanks,
Markus
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
Download attachment "signature.asc" of type "application/pgp-signature" (820 bytes)
Powered by blists - more mailing lists