summaryrefslogtreecommitdiff
path: root/board/nvidia
diff options
context:
space:
mode:
Diffstat (limited to 'board/nvidia')
-rw-r--r--board/nvidia/cardhu/tegra30.dtsi11
-rw-r--r--board/nvidia/common/board.c36
-rw-r--r--board/nvidia/common/pmu.c1
-rw-r--r--board/nvidia/harmony/tegra2-harmony.dts2
-rw-r--r--board/nvidia/seaboard/tegra250.dtsi11
5 files changed, 55 insertions, 6 deletions
diff --git a/board/nvidia/cardhu/tegra30.dtsi b/board/nvidia/cardhu/tegra30.dtsi
index 846c52ce0d3..eb1d3f29544 100644
--- a/board/nvidia/cardhu/tegra30.dtsi
+++ b/board/nvidia/cardhu/tegra30.dtsi
@@ -248,14 +248,21 @@
usb@0x7d008000 {
compatible = "nvidia,tegra250-usb";
- reg = <0x7d008000 0x8000>;
+ reg = <0x7d008000 0x4000>;
periph-id = <59>; // PERIPH_ID_USB3
status = "disabled";
};
+ usb@0x7d004000 {
+ compatible = "nvidia,tegra250-usb";
+ reg = <0x7d004000 0x4000>;
+ periph-id = <58>; // PERIPH_ID_USB2
+ status = "disabled";
+ };
+
usb@0x7d000000 {
compatible = "nvidia,tegra250-usb";
- reg = <0x7d000000 0x8000>;
+ reg = <0x7d000000 0x4000>;
periph-id = <22>; // PERIPH_ID_USBD
status = "disabled";
};
diff --git a/board/nvidia/common/board.c b/board/nvidia/common/board.c
index 5cb219b4f92..1ad40a7b0d0 100644
--- a/board/nvidia/common/board.c
+++ b/board/nvidia/common/board.c
@@ -152,6 +152,37 @@ static void pin_mux_uart(int uart_ids)
#endif /* CONFIG_TEGRA2 */
}
+#if defined(CONFIG_TEGRA3)
+static void enable_clock(enum periph_id pid, int src)
+{
+ /* Assert reset and enable clock */
+ reset_set_enable(pid, 1);
+ clock_enable(pid);
+
+ /* Use 'src' if provided, else use default */
+ if (src != -1)
+ clock_ll_set_source(pid, src);
+
+ /* wait for 2us */
+ udelay(2);
+
+ /* De-assert reset */
+ reset_set_enable(pid, 0);
+}
+
+/* Init misc clocks for kernel booting */
+static void clock_init_misc(void)
+{
+ /* 0 = PLLA_OUT0, -1 = CLK_M (default) */
+ enable_clock(PERIPH_ID_I2S0, -1);
+ enable_clock(PERIPH_ID_I2S1, 0);
+ enable_clock(PERIPH_ID_I2S2, 0);
+ enable_clock(PERIPH_ID_I2S3, 0);
+ enable_clock(PERIPH_ID_I2S4, -1);
+ enable_clock(PERIPH_ID_SPDIF, -1);
+}
+#endif
+
/*
* Routine: pin_mux_switches
* Description: Disable internal pullups for the write protect, SDIO3 write
@@ -380,6 +411,11 @@ int board_early_init_f(void)
init_uarts(gd->blob);
#endif
+#if defined(CONFIG_TEGRA3)
+ /* Initialize misc clocks for kernel booting */
+ clock_init_misc();
+#endif
+
#ifdef CONFIG_VIDEO_TEGRA
/* Get LCD panel size */
lcd_early_init(gd->blob);
diff --git a/board/nvidia/common/pmu.c b/board/nvidia/common/pmu.c
index 0ff3167a8cd..d18c8d71e8f 100644
--- a/board/nvidia/common/pmu.c
+++ b/board/nvidia/common/pmu.c
@@ -47,7 +47,6 @@
#define stp(x, y) ((x < y) ? VDD_TRANSITION_STEP : -VDD_TRANSITION_STEP)
-#define MAX_I2C_RETRY 3
int pmu_read(int reg)
{
int i;
diff --git a/board/nvidia/harmony/tegra2-harmony.dts b/board/nvidia/harmony/tegra2-harmony.dts
index b4965ed014a..0528ebab3e8 100644
--- a/board/nvidia/harmony/tegra2-harmony.dts
+++ b/board/nvidia/harmony/tegra2-harmony.dts
@@ -1,7 +1,7 @@
/dts-v1/;
/memreserve/ 0x1c000000 0x04000000;
-/include/ "../../../arch/arm/cpu/armv7/tegra2/tegra250.dtsi"
+/include/ "../seaboard/tegra250.dtsi"
/ {
model = "NVIDIA Harmony";
diff --git a/board/nvidia/seaboard/tegra250.dtsi b/board/nvidia/seaboard/tegra250.dtsi
index 4a35d53ddde..01f11ad56de 100644
--- a/board/nvidia/seaboard/tegra250.dtsi
+++ b/board/nvidia/seaboard/tegra250.dtsi
@@ -216,14 +216,21 @@
usb@0xc5008000 {
compatible = "nvidia,tegra250-usb";
- reg = <0xc5008000 0x8000>;
+ reg = <0xc5008000 0x4000>;
periph-id = <59>; // PERIPH_ID_USB3
status = "disabled";
};
+ usb@0xc5004000 {
+ compatible = "nvidia,tegra250-usb";
+ reg = <0xc5004000 0x4000>;
+ periph-id = <58>; // PERIPH_ID_USB2
+ status = "disabled";
+ };
+
usb@0xc5000000 {
compatible = "nvidia,tegra250-usb";
- reg = <0xc5000000 0x8000>;
+ reg = <0xc5000000 0x4000>;
periph-id = <22>; // PERIPH_ID_USBD
status = "disabled";
};