Andre Heider has uploaded this change for review. ( https://review.coreboot.org/23796
Change subject: soc/nvidia/tegra210: set up the clock of the chosen UART
......................................................................
soc/nvidia/tegra210: set up the clock of the chosen UART
Don't always set up UARTA, but instead honor
CONFIG_CONSOLE_SERIAL_TEGRA210_UARTx and set up the clock of the
chosen UART.
Now the matching clock for the used UART is set up
(the UART driver uses CONFIG_CONSOLE_SERIAL_TEGRA210_UART_ADDRESS, which
in return is already based on CONFIG_CONSOLE_SERIAL_TEGRA210_UARTx).
Change-Id: Ife209d42af83459136a019c21c2a069396ab36db
Signed-off-by: Andre Heider <a.heider(a)gmail.com>
---
M src/soc/nvidia/tegra210/clock.c
1 file changed, 7 insertions(+), 3 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/96/23796/1
diff --git a/src/soc/nvidia/tegra210/clock.c b/src/soc/nvidia/tegra210/clock.c
index cc8af55..ba1efdc 100644
--- a/src/soc/nvidia/tegra210/clock.c
+++ b/src/soc/nvidia/tegra210/clock.c
@@ -21,6 +21,7 @@
#include <soc/clk_rst.h>
#include <soc/clock.h>
#include <soc/clst_clk.h>
+#include <soc/console_uart.h>
#include <soc/flow.h>
#include <soc/maincpu.h>
#include <soc/pmc.h>
@@ -489,12 +490,15 @@
*/
void clock_early_uart(void)
{
- write32(CLK_RST_REG(clk_src_uarta),
- CLK_SRC_DEV_ID(UARTA, PLLP) << CLK_SOURCE_SHIFT |
+ if (console_uart_get_id() == UART_ID_NONE)
+ return;
+
+ write32(console_uart_clk_rst_reg(),
+ console_uart_clk_src_dev_id() << CLK_SOURCE_SHIFT |
CLK_UART_DIV_OVERRIDE |
CLK_DIVIDER(TEGRA_PLLP_KHZ, 1843));
- clock_enable_clear_reset_l(CLK_L_UARTA);
+ console_uart_clock_enable_clear_reset();
}
/* Enable output clock (CLK1~3) for external peripherals. */
--
To view, visit https://review.coreboot.org/23796
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ife209d42af83459136a019c21c2a069396ab36db
Gerrit-Change-Number: 23796
Gerrit-PatchSet: 1
Gerrit-Owner: Andre Heider <a.heider(a)gmail.com>
Hello Julius Werner, Jonathan Neuschäfer, build bot (Jenkins),
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/23783
to look at the new patch set (#2).
Change subject: soc/nvidia/tegra210: add missing bl31 params
......................................................................
soc/nvidia/tegra210: add missing bl31 params
The ATF tegra210 platform supports more than the currently used
'tzdram_size' parameter, see plat/nvidia/tegra/include/tegra_private.h
in the ATF tree.
Add the missing parameters and set them accordingly. The passed UART id
is based on CONFIG_CONSOLE_SERIAL_TEGRA210_UARTx, so ATF now uses the
same port for console output as coreboot.
Successfully tested with UARTB.
Change-Id: I7a47647216a154894e6c2c1fd3b304e18e85c6a5
Signed-off-by: Andre Heider <a.heider(a)gmail.com>
---
M src/soc/nvidia/tegra210/arm_tf.c
1 file changed, 31 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/83/23783/2
--
To view, visit https://review.coreboot.org/23783
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I7a47647216a154894e6c2c1fd3b304e18e85c6a5
Gerrit-Change-Number: 23783
Gerrit-PatchSet: 2
Gerrit-Owner: Andre Heider <a.heider(a)gmail.com>
Gerrit-Reviewer: Andre Heider <a.heider(a)gmail.com>
Gerrit-Reviewer: Jonathan Neuschäfer <j.neuschaefer(a)gmx.net>
Gerrit-Reviewer: Julius Werner <jwerner(a)chromium.org>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Patrick Rudolph has uploaded this change for review. ( https://review.coreboot.org/23792
Change subject: soc/cavium/bootblock: Get rid of register X1
......................................................................
soc/cavium/bootblock: Get rid of register X1
The register X1 isn't used. Document it and remove it.
Change-Id: I9324ea9de24ba4baaef9dde890c443dd0f921ad9
Signed-off-by: Patrick Rudolph <patrick.rudolph(a)9elements.com>
---
M src/soc/cavium/cn81xx/bootblock_custom.S
M src/soc/cavium/common/bootblock.c
M src/soc/cavium/common/include/soc/bootblock.h
3 files changed, 7 insertions(+), 8 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/92/23792/1
diff --git a/src/soc/cavium/cn81xx/bootblock_custom.S b/src/soc/cavium/cn81xx/bootblock_custom.S
index 69985b7..2f503c8 100644
--- a/src/soc/cavium/cn81xx/bootblock_custom.S
+++ b/src/soc/cavium/cn81xx/bootblock_custom.S
@@ -29,7 +29,11 @@
*/
ic ialluis
fmov d30, x0 /* Save X0 in FPR for use later */
- fmov d31, x1 /* Save X1 in FPR for use later */
+ /**
+ * The BDK stores X1 for later use, but it turns out that we don't need
+ * this "feature". The idea is to hide the devicetree somewhere in
+ * flash, that only the ROM will find it and point to it using X1.
+ */
adr x1, _start /* x1 = _start location based on PC */
fmov d29, x1 /* Save PC in FPR for use later */
@@ -84,7 +88,7 @@
adr x0, _start
/**
- * Check if IROM has loaded the code to CONFIG_BOOTROM_OFFSET.
+ * Check if IROM has loaded the code to BOOTROM_OFFSET.
* In case the offset is wrong, try to relocate.
* Ideally the following code is never executed.
* FIXME: Add region overlap check.
@@ -248,8 +252,7 @@
bl arm64_init_cpu
fmov x0, d30 /* The original X0, info from previous image */
- fmov x1, d31 /* The original X1, info from previous image */
- fmov x2, d29 /* The original PC we were loaded at */
+ fmov x1, d29 /* The original PC we were loaded at */
/* Call C entry */
bl bootblock_main
diff --git a/src/soc/cavium/common/bootblock.c b/src/soc/cavium/common/bootblock.c
index c61a8d7..7b9d524 100644
--- a/src/soc/cavium/common/bootblock.c
+++ b/src/soc/cavium/common/bootblock.c
@@ -32,7 +32,6 @@
/* C code entry point for the boot block */
void bootblock_main(const uint64_t reg_x0,
- const uint64_t reg_x1,
const uint64_t reg_pc)
{
uint64_t base_timestamp = 0;
@@ -57,8 +56,6 @@
printk(BIOS_ERR,
"BOOTBLOCK: RST Boot Failure Code %lld\n",
reg_x0);
-
- printk(BIOS_DEBUG, "BOOTBLOCK: FDT 0x%llX\n", reg_x1);
}
bootblock_soc_init();
diff --git a/src/soc/cavium/common/include/soc/bootblock.h b/src/soc/cavium/common/include/soc/bootblock.h
index e347e86..bfb9745 100644
--- a/src/soc/cavium/common/include/soc/bootblock.h
+++ b/src/soc/cavium/common/include/soc/bootblock.h
@@ -14,7 +14,6 @@
void bootblock_mainboard_init(void);
void bootblock_main(const uint64_t reg_x0,
- const uint64_t reg_x1,
const uint64_t reg_pc);
--
To view, visit https://review.coreboot.org/23792
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I9324ea9de24ba4baaef9dde890c443dd0f921ad9
Gerrit-Change-Number: 23792
Gerrit-PatchSet: 1
Gerrit-Owner: Patrick Rudolph <patrick.rudolph(a)9elements.com>