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

2014-11-11 Thread Paul Kocialkowski
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 cont...@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/




signature.asc
Description: This is a digitally signed message part
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


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

2014-11-11 Thread Tom Rini
On Tue, Nov 11, 2014 at 12:57:45PM +0100, Paul Kocialkowski wrote:
 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 cont...@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?

Oh that's right, hmm.  I think the answer is that for the SPL case where
we _need_ to do something different, the board can already provide that
and do it, with v4.  The general case is that ROM will have done what
needs doing for MMCSD load and in your case you can always go and turn
it on in the board code.

-- 
Tom


signature.asc
Description: Digital signature
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


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

2014-11-11 Thread Paul Kocialkowski
Le mardi 11 novembre 2014 à 07:33 -0500, Tom Rini a écrit :
 On Tue, Nov 11, 2014 at 12:57:45PM +0100, Paul Kocialkowski wrote:
  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 cont...@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?
 
 Oh that's right, hmm.  I think the answer is that for the SPL case where
 we _need_ to do something different, the board can already provide that
 and do it, with v4.  The general case is that ROM will have done what
 needs doing for MMCSD load and in your case you can always go and turn
 it on in the board code.

That should indeed cover most use cases. So let's let boards enable all
the regulators they may need for MMC in board_mmc_power_init.

I'm good with v4 then!

-- 
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/




signature.asc
Description: This is a digitally signed message part
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


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

2014-11-10 Thread Tom Rini
On Sat, Nov 08, 2014 at 08:55:47PM +0100, Paul Kocialkowski wrote:
 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 cont...@paulk.fr

Reviewed-by: Tom Rini tr...@ti.com

-- 
Tom


signature.asc
Description: Digital signature
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


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

2014-11-10 Thread Tom Rini
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 cont...@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() 

-- 
Tom


signature.asc
Description: Digital signature
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


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

2014-11-08 Thread Paul Kocialkowski
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 cont...@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)
+{
+   twl4030_power_mmc_init(0);
+}
 #endif
 
 #ifdef CONFIG_CMD_NET
diff --git a/board/compulab/cm_t35/cm_t35.c b/board/compulab/cm_t35/cm_t35.c
index 886c723..43463d5 100644
--- a/board/compulab/cm_t35/cm_t35.c
+++ b/board/compulab/cm_t35/cm_t35.c
@@ -382,6 +382,13 @@ int board_mmc_init(bd_t *bis)
 }
 #endif
 
+#if defined(CONFIG_GENERIC_MMC)
+void board_mmc_power_init(void)
+{
+   twl4030_power_mmc_init(0);
+}
+#endif
+
 #ifdef CONFIG_SYS_I2C_OMAP34XX
 /*
  * Routine: reset_net_chip
diff --git a/board/corscience/tricorder/tricorder.c 
b/board/corscience/tricorder/tricorder.c
index 9e81bf3..0fddf45 100644
--- a/board/corscience/tricorder/tricorder.c
+++ b/board/corscience/tricorder/tricorder.c
@@ -147,6 +147,13 @@ int board_mmc_init(bd_t *bis)
 }
 #endif
 
+#if defined(CONFIG_GENERIC_MMC)
+void board_mmc_power_init(void)
+{
+   twl4030_power_mmc_init(0);
+}
+#endif
+
 /*
  * Routine: get_board_mem_timings
  * Description: If we use SPL then there is no x-loader nor config header
diff --git a/board/isee/igep00x0/igep00x0.c b/board/isee/igep00x0/igep00x0.c
index 7b87cc2..47522f8 100644
--- a/board/isee/igep00x0/igep00x0.c
+++ b/board/isee/igep00x0/igep00x0.c
@@ -150,6 +150,13 @@ int board_mmc_init(bd_t *bis)
 }
 #endif
 
+#if defined(CONFIG_GENERIC_MMC)
+void board_mmc_power_init(void)
+{
+   twl4030_power_mmc_init(0);
+}
+#endif
+
 void set_fdt(void)
 {
switch (gd-bd-bi_arch_number) {
diff --git a/board/logicpd/omap3som/omap3logic.c 
b/board/logicpd/omap3som/omap3logic.c
index 1fd9f2c..609edf1 100644
--- a/board/logicpd/omap3som/omap3logic.c
+++ b/board/logicpd/omap3som/omap3logic.c
@@ -128,6 +128,13 @@ int board_mmc_init(bd_t *bis)
 }
 #endif
 
+#if defined(CONFIG_GENERIC_MMC)
+void board_mmc_power_init(void)
+{
+   twl4030_power_mmc_init(0);
+}
+#endif
+
 #ifdef CONFIG_SMC911X
 /* GPMC CS1 settings for Logic SOM LV/Torpedo LAN92xx Ethernet chip */
 static const u32 gpmc_lan92xx_config[] = {
diff --git a/board/logicpd/zoom1/zoom1.c b/board/logicpd/zoom1/zoom1.c
index 9ef0026..d39203a 100644
--- a/board/logicpd/zoom1/zoom1.c
+++ b/board/logicpd/zoom1/zoom1.c
@@ -109,6 +109,11 @@ int board_mmc_init(bd_t *bis)
 {
return omap_mmc_init(0, 0, 0, -1, -1);
 }
+
+void board_mmc_power_init(void)
+{
+   twl4030_power_mmc_init(0);
+}
 #endif
 
 #ifdef CONFIG_CMD_NET
diff --git a/board/matrix_vision/mvblx/mvblx.c 
b/board/matrix_vision/mvblx/mvblx.c
index a69359f..c9d615b 100644
--- a/board/matrix_vision/mvblx/mvblx.c
+++ b/board/matrix_vision/mvblx/mvblx.c
@@ -94,6 +94,12 @@ int board_mmc_init(bd_t *bis)
omap_mmc_init(1, 0, 0, -1, -1);
return 0;
 }
+
+void board_mmc_power_init(void)
+{
+   twl4030_power_mmc_init(0);
+   twl4030_power_mmc_init(1);
+}
 #endif
 
 #if defined(CONFIG_CMD_NET)
diff --git a/board/nokia/rx51/rx51.c b/board/nokia/rx51/rx51.c
index c2e07db..b6b8ad6 100644
--- a/board/nokia/rx51/rx51.c
+++ b/board/nokia/rx51/rx51.c
@@ -659,3 +659,9 @@ int board_mmc_init(bd_t *bis)
omap_mmc_init(1, 0, 0, -1, -1);
return 0;
 }
+
+void board_mmc_power_init(void)
+{
+   twl4030_power_mmc_init(0);
+   twl4030_power_mmc_init(1);
+}
diff --git a/board/overo/overo.c b/board/overo/overo.c
index dfb8602..b7f85e7 100644
--- a/board/overo/overo.c
+++ b/board/overo/overo.c
@@ -493,6 +493,13 @@ int board_mmc_init(bd_t *bis)
 }
 #endif
 
+#if defined(CONFIG_GENERIC_MMC)
+void board_mmc_power_init(void)
+{
+   

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

2014-11-08 Thread Paul Kocialkowski
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 cont...@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.

In addition (on v4), board_mmc_init may call omap_mmc_init with a
dev_index that is not used in the board's board_mmc_init, hence not
listed to be enabled on board_mmc_power_init, leaving the MMC device
potentially unpowered in that case. This is why we need to treat SPL
context separately.

This should never actually be a problem as spl_boot_device() will return
what the BootROM booted the SPL from, so it must have already enabled
the relevant LDO. However, I'm using peripheral booting on the Optimus
Black so I hardcode omap3_boot_device to MMC 1/2, so the LDOs are not
enabled at all in my case. And after all, we shouldn't rely on what the
BootROM did or didn't do.

While I'm not suggesting harcoding different behavior should happen on
upstream code, we can imagine that omap3's spl_boot_device could become
more flexible and return something else than what the BootROM booted the
SPL from, hence making that case a valid one.

What do you think?

 + twl4030_power_mmc_init(0);
 +}
  #endif
  
  #ifdef CONFIG_CMD_NET
 diff --git a/board/compulab/cm_t35/cm_t35.c b/board/compulab/cm_t35/cm_t35.c
 index 886c723..43463d5 100644
 --- a/board/compulab/cm_t35/cm_t35.c
 +++ b/board/compulab/cm_t35/cm_t35.c
 @@ -382,6 +382,13 @@ int board_mmc_init(bd_t *bis)
  }
  #endif
  
 +#if defined(CONFIG_GENERIC_MMC)
 +void board_mmc_power_init(void)
 +{
 + twl4030_power_mmc_init(0);
 +}
 +#endif
 +
  #ifdef CONFIG_SYS_I2C_OMAP34XX
  /*
   * Routine: reset_net_chip
 diff --git a/board/corscience/tricorder/tricorder.c 
 b/board/corscience/tricorder/tricorder.c
 index 9e81bf3..0fddf45 100644
 --- a/board/corscience/tricorder/tricorder.c
 +++ b/board/corscience/tricorder/tricorder.c
 @@ -147,6 +147,13 @@ int board_mmc_init(bd_t *bis)
  }
  #endif
  
 +#if defined(CONFIG_GENERIC_MMC)
 +void board_mmc_power_init(void)
 +{
 + twl4030_power_mmc_init(0);
 +}
 +#endif
 +
  /*
   * Routine: get_board_mem_timings
   * Description: If we use SPL then there is no x-loader nor config header
 diff --git a/board/isee/igep00x0/igep00x0.c b/board/isee/igep00x0/igep00x0.c
 index 7b87cc2..47522f8 100644
 --- a/board/isee/igep00x0/igep00x0.c
 +++ b/board/isee/igep00x0/igep00x0.c
 @@ -150,6 +150,13 @@ int board_mmc_init(bd_t *bis)
  }
  #endif
  
 +#if defined(CONFIG_GENERIC_MMC)
 +void board_mmc_power_init(void)
 +{
 + twl4030_power_mmc_init(0);
 +}
 +#endif
 +
  void set_fdt(void)
  {
   switch (gd-bd-bi_arch_number) {
 diff --git a/board/logicpd/omap3som/omap3logic.c 
 b/board/logicpd/omap3som/omap3logic.c
 index 1fd9f2c..609edf1 100644
 --- a/board/logicpd/omap3som/omap3logic.c
 +++ b/board/logicpd/omap3som/omap3logic.c
 @@ -128,6 +128,13 @@ int board_mmc_init(bd_t *bis)
  }
  #endif
  
 +#if defined(CONFIG_GENERIC_MMC)
 +void board_mmc_power_init(void)
 +{
 + twl4030_power_mmc_init(0);
 +}
 +#endif
 +
  #ifdef CONFIG_SMC911X
  /* GPMC CS1 settings for Logic SOM LV/Torpedo LAN92xx Ethernet chip */
  static const u32 gpmc_lan92xx_config[] = {
 diff --git a/board/logicpd/zoom1/zoom1.c b/board/logicpd/zoom1/zoom1.c
 index 9ef0026..d39203a 100644
 ---