aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2013-10-03 21:30:55 -0400
committerSimon Horman <horms+renesas@verge.net.au>2013-12-10 03:24:18 -0500
commit06ac2a61e1559e5986b1e2269d110d51576ab8d4 (patch)
tree255dd310ce58c9a455e555b2ba8655abd1166c4e /arch/arm
parentea8d8a911f4850312834a0ff45c3d5ebc31fb1f1 (diff)
ARM: shmobile: bockw: use regulator for MMCIF
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> Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/mach-shmobile/board-bockw.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/arch/arm/mach-shmobile/board-bockw.c b/arch/arm/mach-shmobile/board-bockw.c
index 38611526fe9a..540f0dc2431a 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[] = {
116 REGULATOR_SUPPLY("vdd33a", "smsc911x"), 116 REGULATOR_SUPPLY("vdd33a", "smsc911x"),
117}; 117};
118 118
119static struct regulator_consumer_supply fixed3v3_power_consumers[] = {
120 REGULATOR_SUPPLY("vmmc", "sh_mmcif"),
121 REGULATOR_SUPPLY("vqmmc", "sh_mmcif"),
122};
123
119static struct smsc911x_platform_config smsc911x_data __initdata = { 124static struct smsc911x_platform_config smsc911x_data __initdata = {
120 .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_LOW, 125 .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_LOW,
121 .irq_type = SMSC911X_IRQ_TYPE_PUSH_PULL, 126 .irq_type = SMSC911X_IRQ_TYPE_PUSH_PULL,
@@ -271,7 +276,6 @@ static struct resource mmc_resources[] __initdata = {
271 276
272static struct sh_mmcif_plat_data sh_mmcif_plat __initdata = { 277static struct sh_mmcif_plat_data sh_mmcif_plat __initdata = {
273 .sup_pclk = 0, 278 .sup_pclk = 0,
274 .ocr = MMC_VDD_165_195 | MMC_VDD_32_33 | MMC_VDD_33_34,
275 .caps = MMC_CAP_4_BIT_DATA | 279 .caps = MMC_CAP_4_BIT_DATA |
276 MMC_CAP_8_BIT_DATA | 280 MMC_CAP_8_BIT_DATA |
277 MMC_CAP_NEEDS_POLL, 281 MMC_CAP_NEEDS_POLL,
@@ -614,6 +618,10 @@ static void __init bockw_init(void)
614 &usb_phy_platform_data, 618 &usb_phy_platform_data,
615 sizeof(struct rcar_phy_platform_data)); 619 sizeof(struct rcar_phy_platform_data));
616 620
621 regulator_register_fixed(0, dummy_supplies,
622 ARRAY_SIZE(dummy_supplies));
623 regulator_register_always_on(1, "fixed-3.3V", fixed3v3_power_consumers,
624 ARRAY_SIZE(fixed3v3_power_consumers), 3300000);
617 625
618 /* for SMSC */ 626 /* for SMSC */
619 fpga = ioremap_nocache(FPGA, SZ_1M); 627 fpga = ioremap_nocache(FPGA, SZ_1M);
@@ -629,9 +637,6 @@ static void __init bockw_init(void)
629 val &= ~(1 << 4); /* enable SMSC911x */ 637 val &= ~(1 << 4); /* enable SMSC911x */
630 iowrite16(val, fpga + IRQ0MR); 638 iowrite16(val, fpga + IRQ0MR);
631 639
632 regulator_register_fixed(0, dummy_supplies,
633 ARRAY_SIZE(dummy_supplies));
634
635 platform_device_register_resndata( 640 platform_device_register_resndata(
636 &platform_bus, "smsc911x", -1, 641 &platform_bus, "smsc911x", -1,
637 smsc911x_resources, ARRAY_SIZE(smsc911x_resources), 642 smsc911x_resources, ARRAY_SIZE(smsc911x_resources),