[PATCH 2/5] ARM: OMAP3EVM: Adding USB internal LDOs board file

2012-06-20 Thread Zumeng Chen
EHCI PHY requires these regulators:
EVM Rev =E  -- VAUX2
EVM Rev  E  -- VUSB1V5, VUSB1V8

Adding USB internal LDOs (vusb1v5  vusb1v8) and VAUX2 to omap3evm
board file. Also removing vaux2_{1/2/3} supplies as they are not
used on omap3 evm.

But we need not to add vaux2 in twl4030_platform_data since it will
be added conditionally.

Signed-off-by: Ajay Kumar Gupta ajay.gu...@ti.com
Signed-off-by: Vaibhav Hiremath hvaib...@ti.com
Signed-off-by: Zumeng Chen zumeng.c...@windriver.com
---
 arch/arm/mach-omap2/board-omap3evm.c |   25 +
 1 files changed, 25 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-omap2/board-omap3evm.c 
b/arch/arm/mach-omap2/board-omap3evm.c
index 0b83d0e..1bfbe42 100644
--- a/arch/arm/mach-omap2/board-omap3evm.c
+++ b/arch/arm/mach-omap2/board-omap3evm.c
@@ -466,6 +466,28 @@ struct wl12xx_platform_data omap3evm_wlan_data __initdata 
= {
 };
 #endif
 
+/* VAUX2 for USB */
+static struct regulator_consumer_supply omap3evm_vaux2_supplies[] = {
+   REGULATOR_SUPPLY(VDD_CSIPHY1, omap3isp),/* OMAP ISP */
+   REGULATOR_SUPPLY(VDD_CSIPHY2, omap3isp),/* OMAP ISP */
+   REGULATOR_SUPPLY(hsusb1, ehci-omap.0),
+   REGULATOR_SUPPLY(vaux2, NULL),
+};
+
+static struct regulator_init_data omap3evm_vaux2 = {
+   .constraints = {
+   .min_uV = 280,
+   .max_uV = 280,
+   .apply_uV   = true,
+   .valid_modes_mask   = REGULATOR_MODE_NORMAL
+   | REGULATOR_MODE_STANDBY,
+   .valid_ops_mask = REGULATOR_CHANGE_MODE
+   | REGULATOR_CHANGE_STATUS,
+   },
+   .num_consumer_supplies  = ARRAY_SIZE(omap3evm_vaux2_supplies),
+   .consumer_supplies  = omap3evm_vaux2_supplies,
+};
+
 static struct twl4030_platform_data omap3evm_twldata = {
/* platform_data for children goes here */
.keypad = omap3evm_kp_data,
@@ -659,6 +681,9 @@ static void __init omap3_evm_init(void)
omap_mux_init_gpio(63, OMAP_PIN_INPUT);
omap_hsmmc_init(mmc);
 
+   if (get_omap3_evm_rev() = OMAP3EVM_BOARD_GEN_2)
+   omap3evm_twldata.vaux2 = omap3evm_vaux2;
+
omap3_evm_i2c_init();
 
omap_display_init(omap3_evm_dss_data);
-- 
1.7.5.4

--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 2/5] ARM: OMAP3EVM: Adding USB internal LDOs board file

2012-06-11 Thread Zumeng Chen
EHCI PHY requires these regulators:
EVM Rev =E  -- VAUX2
EVM Rev  E  -- VUSB1V5, VUSB1V8

Adding USB internal LDOs (vusb1v5  vusb1v8) and VAUX2 to omap3evm
board file. Also removing vaux2_{1/2/3} supplies as they are not
used on omap3 evm.

But we need not to add vaux2 in twl4030_platform_data since it will
be added conditionally.

Signed-off-by: Ajay Kumar Gupta ajay.gu...@ti.com
Signed-off-by: Vaibhav Hiremath hvaib...@ti.com
Signed-off-by: Zumeng Chen zumeng.c...@gmail.com
---
 arch/arm/mach-omap2/board-omap3evm.c |   27 +++
 1 files changed, 27 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-omap2/board-omap3evm.c 
b/arch/arm/mach-omap2/board-omap3evm.c
index fef911d..7e5e18f 100644
--- a/arch/arm/mach-omap2/board-omap3evm.c
+++ b/arch/arm/mach-omap2/board-omap3evm.c
@@ -466,6 +466,30 @@ struct wl12xx_platform_data omap3evm_wlan_data __initdata 
= {
 };
 #endif
 
+/* VAUX2 for USB */
+static struct regulator_consumer_supply omap3evm_vaux2_supplies[] = {
+   REGULATOR_SUPPLY(VDD_CSIPHY1, omap3isp),/* OMAP ISP */
+   REGULATOR_SUPPLY(VDD_CSIPHY2, omap3isp),/* OMAP ISP */
+   REGULATOR_SUPPLY(hsusb1, ehci-omap.0),
+   {
+   .supply = vaux2,
+   }
+};
+
+static struct regulator_init_data omap3evm_vaux2 = {
+   .constraints = {
+   .min_uV = 280,
+   .max_uV = 280,
+   .apply_uV   = true,
+   .valid_modes_mask   = REGULATOR_MODE_NORMAL
+   | REGULATOR_MODE_STANDBY,
+   .valid_ops_mask = REGULATOR_CHANGE_MODE
+   | REGULATOR_CHANGE_STATUS,
+   },
+   .num_consumer_supplies  = ARRAY_SIZE(omap3evm_vaux2_supplies),
+   .consumer_supplies  = omap3evm_vaux2_supplies,
+};
+
 static struct twl4030_platform_data omap3evm_twldata = {
/* platform_data for children goes here */
.keypad = omap3evm_kp_data,
@@ -659,6 +683,9 @@ static void __init omap3_evm_init(void)
omap_mux_init_gpio(63, OMAP_PIN_INPUT);
omap_hsmmc_init(mmc);
 
+   if (get_omap3_evm_rev() = OMAP3EVM_BOARD_GEN_2)
+   omap3evm_twldata.vaux2 = omap3evm_vaux2;
+
omap3_evm_i2c_init();
 
omap_display_init(omap3_evm_dss_data);
-- 
1.7.5.4

--
To unsubscribe from this list: send the line unsubscribe linux-omap in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html