public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] ARM: BeagleBoard-X15: Enable VTT regulator
@ 2015-06-16 15:06 Lokesh Vutla
  2015-06-16 15:43 ` Tom Rini
  2015-06-19 20:25 ` [U-Boot] " Tom Rini
  0 siblings, 2 replies; 3+ messages in thread
From: Lokesh Vutla @ 2015-06-16 15:06 UTC (permalink / raw)
  To: u-boot

BeagleBoard-X15 uses a vtt regulator for DDR3 termination
and this is controlled by gpio7_11. Configuring gpio7_11.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
---
 board/ti/beagle_x15/board.c  | 23 +++++++++++++++++++++++
 include/configs/beagle_x15.h |  2 ++
 2 files changed, 25 insertions(+)

diff --git a/board/ti/beagle_x15/board.c b/board/ti/beagle_x15/board.c
index b6c17ec..c7f19c7 100644
--- a/board/ti/beagle_x15/board.c
+++ b/board/ti/beagle_x15/board.c
@@ -14,6 +14,8 @@
 #include <usb.h>
 #include <asm/omap_common.h>
 #include <asm/emif.h>
+#include <asm/gpio.h>
+#include <asm/arch/gpio.h>
 #include <asm/arch/clock.h>
 #include <asm/arch/dra7xx_iodelay.h>
 #include <asm/arch/sys_proto.h>
@@ -30,6 +32,9 @@
 
 DECLARE_GLOBAL_DATA_PTR;
 
+/* GPIO 7_11 */
+#define GPIO_DDR_VTT_EN 203
+
 const struct omap_sysinfo sysinfo = {
 	"Board: BeagleBoard x15\n"
 };
@@ -404,3 +409,21 @@ int board_eth_init(bd_t *bis)
 	return ret;
 }
 #endif
+
+#ifdef CONFIG_BOARD_EARLY_INIT_F
+/* VTT regulator enable */
+static inline void vtt_regulator_enable(void)
+{
+	if (omap_hw_init_context() == OMAP_INIT_CONTEXT_UBOOT_AFTER_SPL)
+		return;
+
+	gpio_request(GPIO_DDR_VTT_EN, "ddr_vtt_en");
+	gpio_direction_output(GPIO_DDR_VTT_EN, 1);
+}
+
+int board_early_init_f(void)
+{
+	vtt_regulator_enable();
+	return 0;
+}
+#endif
diff --git a/include/configs/beagle_x15.h b/include/configs/beagle_x15.h
index 8d072c6..c5dde99 100644
--- a/include/configs/beagle_x15.h
+++ b/include/configs/beagle_x15.h
@@ -18,6 +18,8 @@
 #define CONFIG_IODELAY_RECALIBRATION
 #endif
 
+#define CONFIG_BOARD_EARLY_INIT_F
+
 #define CONFIG_NR_DRAM_BANKS		2
 
 #define CONFIG_ENV_SIZE			(64 << 10)
-- 
1.9.1

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

* [U-Boot] [PATCH] ARM: BeagleBoard-X15: Enable VTT regulator
  2015-06-16 15:06 [U-Boot] [PATCH] ARM: BeagleBoard-X15: Enable VTT regulator Lokesh Vutla
@ 2015-06-16 15:43 ` Tom Rini
  2015-06-19 20:25 ` [U-Boot] " Tom Rini
  1 sibling, 0 replies; 3+ messages in thread
From: Tom Rini @ 2015-06-16 15:43 UTC (permalink / raw)
  To: u-boot

On Tue, Jun 16, 2015 at 08:36:05PM +0530, Lokesh Vutla wrote:

> BeagleBoard-X15 uses a vtt regulator for DDR3 termination
> and this is controlled by gpio7_11. Configuring gpio7_11.
> 
> Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>

Reviewed-by: Tom Rini <trini@konsulko.com>

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20150616/043565d6/attachment.sig>

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

* [U-Boot] ARM: BeagleBoard-X15: Enable VTT regulator
  2015-06-16 15:06 [U-Boot] [PATCH] ARM: BeagleBoard-X15: Enable VTT regulator Lokesh Vutla
  2015-06-16 15:43 ` Tom Rini
@ 2015-06-19 20:25 ` Tom Rini
  1 sibling, 0 replies; 3+ messages in thread
From: Tom Rini @ 2015-06-19 20:25 UTC (permalink / raw)
  To: u-boot

On Tue, Jun 16, 2015 at 08:36:05PM +0530, Lokesh Vutla wrote:

> BeagleBoard-X15 uses a vtt regulator for DDR3 termination
> and this is controlled by gpio7_11. Configuring gpio7_11.
> 
> Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
> Reviewed-by: Tom Rini <trini@konsulko.com>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20150619/1206ad9c/attachment.sig>

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

end of thread, other threads:[~2015-06-19 20:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-16 15:06 [U-Boot] [PATCH] ARM: BeagleBoard-X15: Enable VTT regulator Lokesh Vutla
2015-06-16 15:43 ` Tom Rini
2015-06-19 20:25 ` [U-Boot] " Tom Rini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox