linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 2/7] ARM: shmobile: bockw: use regulator for MMCIF
@ 2013-10-04  1:30 Kuninori Morimoto
  2013-10-08  4:09 ` Simon Horman
  0 siblings, 1 reply; 2+ messages in thread
From: Kuninori Morimoto @ 2013-10-04  1:30 UTC (permalink / raw)
  To: linux-sh

When regulators are used with MMC devices, sh_mmcif_plat_data::ocr
is not needed, they can be removed from platform data.
This patch adds v3.3 regulator settings,
and moved fixed-dummy regulator registration position

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 arch/arm/mach-shmobile/board-bockw.c |   13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)

diff --git a/arch/arm/mach-shmobile/board-bockw.c b/arch/arm/mach-shmobile/board-bockw.c
index 6163fb1..1b1dae3 100644
--- a/arch/arm/mach-shmobile/board-bockw.c
+++ b/arch/arm/mach-shmobile/board-bockw.c
@@ -116,6 +116,11 @@ static struct regulator_consumer_supply dummy_supplies[] = {
 	REGULATOR_SUPPLY("vdd33a", "smsc911x"),
 };
 
+static struct regulator_consumer_supply fixed3v3_power_consumers[] = {
+	REGULATOR_SUPPLY("vmmc", "sh_mmcif"),
+	REGULATOR_SUPPLY("vqmmc", "sh_mmcif"),
+};
+
 static struct smsc911x_platform_config smsc911x_data __initdata = {
 	.irq_polarity	= SMSC911X_IRQ_POLARITY_ACTIVE_LOW,
 	.irq_type	= SMSC911X_IRQ_TYPE_PUSH_PULL,
@@ -271,7 +276,6 @@ static struct resource mmc_resources[] __initdata = {
 
 static struct sh_mmcif_plat_data sh_mmcif_plat __initdata = {
 	.sup_pclk	= 0,
-	.ocr		= MMC_VDD_165_195 | MMC_VDD_32_33 | MMC_VDD_33_34,
 	.caps		= MMC_CAP_4_BIT_DATA |
 			  MMC_CAP_8_BIT_DATA |
 			  MMC_CAP_NEEDS_POLL,
@@ -614,6 +618,10 @@ static void __init bockw_init(void)
 		&usb_phy_platform_data,
 		sizeof(struct rcar_phy_platform_data));
 
+	regulator_register_fixed(0, dummy_supplies,
+				 ARRAY_SIZE(dummy_supplies));
+	regulator_register_always_on(1, "fixed-3.3V", fixed3v3_power_consumers,
+				     ARRAY_SIZE(fixed3v3_power_consumers), 3300000);
 
 	/* for SMSC */
 	fpga = ioremap_nocache(FPGA, SZ_1M);
@@ -629,9 +637,6 @@ static void __init bockw_init(void)
 		val &= ~(1 << 4); /* enable SMSC911x */
 		iowrite16(val, fpga + IRQ0MR);
 
-		regulator_register_fixed(0, dummy_supplies,
-					 ARRAY_SIZE(dummy_supplies));
-
 		platform_device_register_resndata(
 			&platform_bus, "smsc911x", -1,
 			smsc911x_resources, ARRAY_SIZE(smsc911x_resources),
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH 2/7] ARM: shmobile: bockw: use regulator for MMCIF
  2013-10-04  1:30 [PATCH 2/7] ARM: shmobile: bockw: use regulator for MMCIF Kuninori Morimoto
@ 2013-10-08  4:09 ` Simon Horman
  0 siblings, 0 replies; 2+ messages in thread
From: Simon Horman @ 2013-10-08  4:09 UTC (permalink / raw)
  To: linux-sh

On Thu, Oct 03, 2013 at 06:30:55PM -0700, Kuninori Morimoto wrote:
> When regulators are used with MMC devices, sh_mmcif_plat_data::ocr
> is not needed, they can be removed from platform data.
> This patch adds v3.3 regulator settings,
> and moved fixed-dummy regulator registration position
> 
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>

Thanks, I have queued this up.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-10-08  4:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-10-04  1:30 [PATCH 2/7] ARM: shmobile: bockw: use regulator for MMCIF Kuninori Morimoto
2013-10-08  4:09 ` Simon Horman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).