[v3,3/5] rockchip: Enable pre console for rk3399

Message ID 20200402114125.2501-4-jagan@amarulasolutions.com
State New
Headers show
Series
  • rockchip: rk3399: Fix HDMI out
Related show

Commit Message

Jagan Teki April 2, 2020, 11:41 a.m. UTC
Enable pre console buffer for rk3399 platform.

This would help to capture the console messages prior to
the console being initialised. Enabling this would help
to capture all the console messages on video output source
like HDMI. So we can find the full console messages of
U-Boot proper on HDMI display when enabled it for RK3399
platform boards.

Buffer address used for pre console is 0x0f200000 which is
ram base plus 240MiB. right now the Allwinner SoC is using
similar computation.

Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
---
 arch/arm/mach-rockchip/Kconfig | 1 +
 common/Kconfig                 | 1 +
 2 files changed, 2 insertions(+)

Comments

Kever Yang April 2, 2020, 12:47 p.m. UTC | #1
On 2020/4/2 下午7:41, Jagan Teki wrote:
> Enable pre console buffer for rk3399 platform.
>
> This would help to capture the console messages prior to
> the console being initialised. Enabling this would help
> to capture all the console messages on video output source
> like HDMI. So we can find the full console messages of
> U-Boot proper on HDMI display when enabled it for RK3399
> platform boards.
>
> Buffer address used for pre console is 0x0f200000 which is
> ram base plus 240MiB. right now the Allwinner SoC is using
> similar computation.
>
> Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>



Reviewed-by: Kever Yang <kever.yang@rock-chips.com>

Thanks,
- Kever
> ---
>   arch/arm/mach-rockchip/Kconfig | 1 +
>   common/Kconfig                 | 1 +
>   2 files changed, 2 insertions(+)
>
> diff --git a/arch/arm/mach-rockchip/Kconfig b/arch/arm/mach-rockchip/Kconfig
> index ed7514ab75..0cb1f23d0f 100644
> --- a/arch/arm/mach-rockchip/Kconfig
> +++ b/arch/arm/mach-rockchip/Kconfig
> @@ -229,6 +229,7 @@ config ROCKCHIP_RK3399
>   	select DM_PMIC
>   	select DM_REGULATOR_FIXED
>   	select BOARD_LATE_INIT
> +	imply PRE_CONSOLE_BUFFER
>   	imply ROCKCHIP_COMMON_BOARD
>   	imply ROCKCHIP_SDRAM_COMMON
>   	imply SPL_ROCKCHIP_COMMON_BOARD
> diff --git a/common/Kconfig b/common/Kconfig
> index 46e4193fc8..bd35de3056 100644
> --- a/common/Kconfig
> +++ b/common/Kconfig
> @@ -568,6 +568,7 @@ config PRE_CON_BUF_ADDR
>   	default 0x2f000000 if ARCH_SUNXI && MACH_SUN9I
>   	default 0x4f000000 if ARCH_SUNXI && !MACH_SUN9I
>   	default 0x0f000000 if ROCKCHIP_RK3288
> +	default 0x0f200000 if ROCKCHIP_RK3399
>   	help
>   	  This sets the start address of the pre-console buffer. This must
>   	  be in available memory and is accessed before relocation and

Patch

diff --git a/arch/arm/mach-rockchip/Kconfig b/arch/arm/mach-rockchip/Kconfig
index ed7514ab75..0cb1f23d0f 100644
--- a/arch/arm/mach-rockchip/Kconfig
+++ b/arch/arm/mach-rockchip/Kconfig
@@ -229,6 +229,7 @@  config ROCKCHIP_RK3399
 	select DM_PMIC
 	select DM_REGULATOR_FIXED
 	select BOARD_LATE_INIT
+	imply PRE_CONSOLE_BUFFER
 	imply ROCKCHIP_COMMON_BOARD
 	imply ROCKCHIP_SDRAM_COMMON
 	imply SPL_ROCKCHIP_COMMON_BOARD
diff --git a/common/Kconfig b/common/Kconfig
index 46e4193fc8..bd35de3056 100644
--- a/common/Kconfig
+++ b/common/Kconfig
@@ -568,6 +568,7 @@  config PRE_CON_BUF_ADDR
 	default 0x2f000000 if ARCH_SUNXI && MACH_SUN9I
 	default 0x4f000000 if ARCH_SUNXI && !MACH_SUN9I
 	default 0x0f000000 if ROCKCHIP_RK3288
+	default 0x0f200000 if ROCKCHIP_RK3399
 	help
 	  This sets the start address of the pre-console buffer. This must
 	  be in available memory and is accessed before relocation and