[U-Boot] [PATCH v4 3/3] omap_hsmmc: Board-specific TWL4030 MMC power initializations

Paul Kocialkowski contact at paulk.fr
Tue Nov 11 12:57:45 CET 2014


Le lundi 10 novembre 2014 à 13:46 -0500, Tom Rini a écrit :
> On Sat, Nov 08, 2014 at 10:29:24PM +0100, Paul Kocialkowski wrote:
> > Le samedi 08 novembre 2014 à 20:55 +0100, Paul Kocialkowski a écrit :
> > > Boards using the TWL4030 regulator may not all use the LDOs the same way
> > > (e.g. MMC2 power can be controlled by another LDO than VMMC2).
> > > This delegates TWL4030 MMC power initializations to board-specific functions,
> > > that may still call twl4030_power_mmc_init for the default behavior.
> > > 
> > > Signed-off-by: Paul Kocialkowski <contact at paulk.fr>
> > > ---
> > >  board/comelit/dig297/dig297.c          | 5 +++++
> > >  board/compulab/cm_t35/cm_t35.c         | 7 +++++++
> > >  board/corscience/tricorder/tricorder.c | 7 +++++++
> > >  board/isee/igep00x0/igep00x0.c         | 7 +++++++
> > >  board/logicpd/omap3som/omap3logic.c    | 7 +++++++
> > >  board/logicpd/zoom1/zoom1.c            | 5 +++++
> > >  board/matrix_vision/mvblx/mvblx.c      | 6 ++++++
> > >  board/nokia/rx51/rx51.c                | 6 ++++++
> > >  board/overo/overo.c                    | 7 +++++++
> > >  board/pandora/pandora.c                | 5 +++++
> > >  board/technexion/tao3530/tao3530.c     | 7 +++++++
> > >  board/ti/beagle/beagle.c               | 7 +++++++
> > >  board/ti/evm/evm.c                     | 7 +++++++
> > >  board/ti/sdp3430/sdp.c                 | 5 +++++
> > >  board/timll/devkit8000/devkit8000.c    | 7 +++++++
> > >  drivers/mmc/omap_hsmmc.c               | 7 +------
> > >  16 files changed, 96 insertions(+), 6 deletions(-)
> > > 
> > > diff --git a/board/comelit/dig297/dig297.c b/board/comelit/dig297/dig297.c
> > > index 2b826df..9d4c41b 100644
> > > --- a/board/comelit/dig297/dig297.c
> > > +++ b/board/comelit/dig297/dig297.c
> > > @@ -133,6 +133,11 @@ int board_mmc_init(bd_t *bis)
> > >  {
> > >  	return omap_mmc_init(0, 0, 0, -1, -1);
> > >  }
> > > +
> > > +void board_mmc_power_init(void)
> > > +{
> > 
> > I just figured, in the context of the SPL, board_mmc_init will be called
> > from omap3/board.c instead of the board file, so perhaps it would be
> > worth adding, in board_mmc_power_init: #ifdef CONFIG_SPL_BUILD and then
> > checking spl_boot_device to only enable the relevant LDO.
> 
> If we get to this point we can do the same thing we do for
> board_mmc_init which is have one in say
> arch/arm/cpu/armv7/omap-common/boot-common.c that checks
> spl_boot_device() 

That wouldn't work for my use case, on the Optimus Black, where
regulators are used in a non-standard way. The whole point of this to me
is to not have platform-common code to handle MMC regulators, because
the way those are wired to MMC devices is not the same for each
platform, but is instead board-specific.

Is there any objection to making a v5 that takes the SPL context in
account on each of those boards?

Thanks

-- 
Paul Kocialkowski, Replicant developer

Replicant is a fully free Android distribution

Website: http://www.replicant.us/
Blog: http://blog.replicant.us/
Wiki/tracker/forums: http://redmine.replicant.us/


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20141111/4219fe12/attachment.pgp>


More information about the U-Boot mailing list