summaryrefslogtreecommitdiff
path: root/arch/arm/mach-ux500/cpu-db8500.c
diff options
context:
space:
mode:
authorPhilippe Langlais <philippe.langlais@linaro.org>2011-07-05 14:40:21 +0200
committerUlf Hansson <ulf.hansson@stericsson.com>2011-09-19 15:15:43 +0200
commit2e4fbd86739c42bec905896d5358849de48452c1 (patch)
treede3fab64545f7d0ee4038a6d083d4feb45a371cd /arch/arm/mach-ux500/cpu-db8500.c
parentca36d68fd19bc9d5a30923b05e68aadb5fef3c62 (diff)
ux500: fix PRCMU boot problem, use new MFD driver & code cleanup
Signed-off-by: Philippe Langlais <philippe.langlais@linaro.org>
Diffstat (limited to 'arch/arm/mach-ux500/cpu-db8500.c')
-rw-r--r--arch/arm/mach-ux500/cpu-db8500.c236
1 files changed, 3 insertions, 233 deletions
diff --git a/arch/arm/mach-ux500/cpu-db8500.c b/arch/arm/mach-ux500/cpu-db8500.c
index 679ec31ed32..17289c66107 100644
--- a/arch/arm/mach-ux500/cpu-db8500.c
+++ b/arch/arm/mach-ux500/cpu-db8500.c
@@ -17,7 +17,6 @@
#include <linux/gpio/nomadik.h>
#include <linux/platform_device.h>
#include <linux/io.h>
-#include <linux/regulator/machine.h>
#include <linux/sys_soc.h>
#include <asm/mach/map.h>
@@ -31,7 +30,6 @@
#include <mach/ste-dma40-db8500.h>
#include "devices-db8500.h"
-#include "regulator-db8500.h"
/* minimum static i/o mapping required to boot U8500 platforms */
static struct map_desc u8500_uart_io_desc[] __initdata = {
@@ -138,242 +136,14 @@ static struct platform_device db8500_pmu_device = {
.dev.platform_data = &db8500_pmu_platdata,
};
-/*
- * Power domain switches (ePODs) modeled as regulators for the DB8500 SoC
- */
-
-static struct regulator_consumer_supply db8500_vape_consumers[] = {
- REGULATOR_SUPPLY("v-ape", NULL),
- REGULATOR_SUPPLY("v-i2c", "nmk-i2c.0"),
- REGULATOR_SUPPLY("v-i2c", "nmk-i2c.1"),
- REGULATOR_SUPPLY("v-i2c", "nmk-i2c.2"),
- REGULATOR_SUPPLY("v-i2c", "nmk-i2c.3"),
- /* "v-mmc" changed to "vcore" in the mainline kernel */
- REGULATOR_SUPPLY("vcore", "sdi0"),
- REGULATOR_SUPPLY("vcore", "sdi1"),
- REGULATOR_SUPPLY("vcore", "sdi2"),
- REGULATOR_SUPPLY("vcore", "sdi3"),
- REGULATOR_SUPPLY("vcore", "sdi4"),
- REGULATOR_SUPPLY("v-dma", "dma40.0"),
- REGULATOR_SUPPLY("v-ape", "ab8500-usb.0"),
- /* "v-uart" changed to "vcore" in the mainline kernel */
- REGULATOR_SUPPLY("vcore", "uart0"),
- REGULATOR_SUPPLY("vcore", "uart1"),
- REGULATOR_SUPPLY("vcore", "uart2"),
- REGULATOR_SUPPLY("v-ape", "nmk-ske-keypad.0"),
-};
-
-static struct regulator_consumer_supply db8500_vsmps2_consumers[] = {
- REGULATOR_SUPPLY("musb_1v8", "ab8500-usb.0"),
- /* AV8100 regulator */
- REGULATOR_SUPPLY("hdmi_1v8", "0-0070"),
-};
-
-static struct regulator_consumer_supply db8500_b2r2_mcde_consumers[] = {
- REGULATOR_SUPPLY("vsupply", "b2r2.0"),
- REGULATOR_SUPPLY("vsupply", "mcde"),
-};
-
-/* SVA MMDSP regulator switch */
-static struct regulator_consumer_supply db8500_svammdsp_consumers[] = {
- REGULATOR_SUPPLY("sva-mmdsp", "cm_control"),
-};
-
-/* SVA pipe regulator switch */
-static struct regulator_consumer_supply db8500_svapipe_consumers[] = {
- REGULATOR_SUPPLY("sva-pipe", "cm_control"),
-};
-
-/* SIA MMDSP regulator switch */
-static struct regulator_consumer_supply db8500_siammdsp_consumers[] = {
- REGULATOR_SUPPLY("sia-mmdsp", "cm_control"),
-};
-
-/* SIA pipe regulator switch */
-static struct regulator_consumer_supply db8500_siapipe_consumers[] = {
- REGULATOR_SUPPLY("sia-pipe", "cm_control"),
-};
-
-static struct regulator_consumer_supply db8500_sga_consumers[] = {
- REGULATOR_SUPPLY("v-mali", NULL),
-};
-
-/* ESRAM1 and 2 regulator switch */
-static struct regulator_consumer_supply db8500_esram12_consumers[] = {
- REGULATOR_SUPPLY("esram12", "cm_control"),
-};
-
-/* ESRAM3 and 4 regulator switch */
-static struct regulator_consumer_supply db8500_esram34_consumers[] = {
- REGULATOR_SUPPLY("v-esram34", "mcde"),
- REGULATOR_SUPPLY("esram34", "cm_control"),
-};
-
-static struct regulator_init_data db8500_regulators[DB8500_NUM_REGULATORS] = {
- [DB8500_REGULATOR_VAPE] = {
- .constraints = {
- .name = "db8500-vape",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- .consumer_supplies = db8500_vape_consumers,
- .num_consumer_supplies = ARRAY_SIZE(db8500_vape_consumers),
- },
- [DB8500_REGULATOR_VARM] = {
- .constraints = {
- .name = "db8500-varm",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- },
- [DB8500_REGULATOR_VMODEM] = {
- .constraints = {
- .name = "db8500-vmodem",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- },
- [DB8500_REGULATOR_VPLL] = {
- .constraints = {
- .name = "db8500-vpll",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- },
- [DB8500_REGULATOR_VSMPS1] = {
- .constraints = {
- .name = "db8500-vsmps1",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- },
- [DB8500_REGULATOR_VSMPS2] = {
- .constraints = {
- .name = "db8500-vsmps2",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- .consumer_supplies = db8500_vsmps2_consumers,
- .num_consumer_supplies = ARRAY_SIZE(db8500_vsmps2_consumers),
- },
- [DB8500_REGULATOR_VSMPS3] = {
- .constraints = {
- .name = "db8500-vsmps3",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- },
- [DB8500_REGULATOR_VRF1] = {
- .constraints = {
- .name = "db8500-vrf1",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- },
- [DB8500_REGULATOR_SWITCH_SVAMMDSP] = {
- .supply_regulator = "db8500-vape",
- .constraints = {
- .name = "db8500-sva-mmdsp",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- .consumer_supplies = db8500_svammdsp_consumers,
- .num_consumer_supplies = ARRAY_SIZE(db8500_svammdsp_consumers),
- },
- [DB8500_REGULATOR_SWITCH_SVAMMDSPRET] = {
- .constraints = {
- /* "ret" means "retention" */
- .name = "db8500-sva-mmdsp-ret",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- },
- [DB8500_REGULATOR_SWITCH_SVAPIPE] = {
- .supply_regulator = "db8500-vape",
- .constraints = {
- .name = "db8500-sva-pipe",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- .consumer_supplies = db8500_svapipe_consumers,
- .num_consumer_supplies = ARRAY_SIZE(db8500_svapipe_consumers),
- },
- [DB8500_REGULATOR_SWITCH_SIAMMDSP] = {
- .supply_regulator = "db8500-vape",
- .constraints = {
- .name = "db8500-sia-mmdsp",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- .consumer_supplies = db8500_siammdsp_consumers,
- .num_consumer_supplies = ARRAY_SIZE(db8500_siammdsp_consumers),
- },
- [DB8500_REGULATOR_SWITCH_SIAMMDSPRET] = {
- .constraints = {
- .name = "db8500-sia-mmdsp-ret",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- },
- [DB8500_REGULATOR_SWITCH_SIAPIPE] = {
- .supply_regulator = "db8500-vape",
- .constraints = {
- .name = "db8500-sia-pipe",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- .consumer_supplies = db8500_siapipe_consumers,
- .num_consumer_supplies = ARRAY_SIZE(db8500_siapipe_consumers),
- },
- [DB8500_REGULATOR_SWITCH_SGA] = {
- .supply_regulator = "db8500-vape",
- .constraints = {
- .name = "db8500-sga",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- .consumer_supplies = db8500_sga_consumers,
- .num_consumer_supplies = ARRAY_SIZE(db8500_sga_consumers),
-
- },
- [DB8500_REGULATOR_SWITCH_B2R2_MCDE] = {
- .supply_regulator = "db8500-vape",
- .constraints = {
- .name = "db8500-b2r2-mcde",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- .consumer_supplies = db8500_b2r2_mcde_consumers,
- .num_consumer_supplies = ARRAY_SIZE(db8500_b2r2_mcde_consumers),
- },
- [DB8500_REGULATOR_SWITCH_ESRAM12] = {
- .supply_regulator = "db8500-vape",
- .constraints = {
- .name = "db8500-esram12",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- .consumer_supplies = db8500_esram12_consumers,
- .num_consumer_supplies = ARRAY_SIZE(db8500_esram12_consumers),
- },
- [DB8500_REGULATOR_SWITCH_ESRAM12RET] = {
- .constraints = {
- .name = "db8500-esram12-ret",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- },
- [DB8500_REGULATOR_SWITCH_ESRAM34] = {
- .supply_regulator = "db8500-vape",
- .constraints = {
- .name = "db8500-esram34",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- .consumer_supplies = db8500_esram34_consumers,
- .num_consumer_supplies = ARRAY_SIZE(db8500_esram34_consumers),
- },
- [DB8500_REGULATOR_SWITCH_ESRAM34RET] = {
- .constraints = {
- .name = "db8500-esram34-ret",
- .valid_ops_mask = REGULATOR_CHANGE_STATUS,
- },
- },
-};
-
-static struct platform_device db8500_regulator_device = {
- .name = "db8500-regulators",
- .id = 0,
- .dev = {
- .platform_data = &db8500_regulators,
- },
+static struct platform_device db8500_prcmu_device = {
+ .name = "db8500-prcmu",
};
static struct platform_device *platform_devs[] __initdata = {
&u8500_dma40_device,
&db8500_pmu_device,
- &db8500_regulator_device,
+ &db8500_prcmu_device,
};
static resource_size_t __initdata db8500_gpio_base[] = {