From: Heiko Stuebner <heiko@sntech.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/3] rockchip: make boot_mode releated codes reused across all platforms
Date: Thu, 21 Sep 2017 11:02:09 +0200 [thread overview]
Message-ID: <4551943.4geh5MgojS@phil> (raw)
In-Reply-To: <1505224652-29989-1-git-send-email-andy.yan@rock-chips.com>
Hi Andy,
Am Dienstag, 12. September 2017, 21:57:32 CEST schrieb Andy Yan:
> setup_boot_mode function use the same logic but different
> mode register address across all the rockchip platforms,
> so it's better to make this function reused across all the
> platforms, and let the mode register address setting from
> the config file.
>
> Signed-off-by: Andy Yan <andy.yan@rock-chips.com>
>
> ---
>
> arch/arm/include/asm/arch-rockchip/boot_mode.h | 2 ++
> arch/arm/mach-rockchip/Kconfig | 14 +++++++++++
> arch/arm/mach-rockchip/Makefile | 5 +++-
> arch/arm/mach-rockchip/boot_mode.c | 33 ++++++++++++++++++++++++++
> arch/arm/mach-rockchip/rk3036-board.c | 24 -------------------
> arch/arm/mach-rockchip/rk322x-board.c | 24 -------------------
> arch/arm/mach-rockchip/rk3288-board.c | 25 -------------------
> arch/arm/mach-rockchip/rk3399-board.c | 14 +++++++++++
> 8 files changed, 67 insertions(+), 74 deletions(-)
> create mode 100644 arch/arm/mach-rockchip/boot_mode.c
> create mode 100644 arch/arm/mach-rockchip/rk3399-board.c
>
> diff --git a/arch/arm/include/asm/arch-rockchip/boot_mode.h b/arch/arm/include/asm/arch-rockchip/boot_mode.h
> index bd65f60..163b2e7 100644
> --- a/arch/arm/include/asm/arch-rockchip/boot_mode.h
> +++ b/arch/arm/include/asm/arch-rockchip/boot_mode.h
> @@ -16,4 +16,6 @@
> /* enter usb mass storage mode */
> #define BOOT_UMS (REBOOT_FLAG + 12)
>
> +int setup_boot_mode(void);
> +
> #endif
> diff --git a/arch/arm/mach-rockchip/Kconfig b/arch/arm/mach-rockchip/Kconfig
> index d9b25d5..527ca60 100644
> --- a/arch/arm/mach-rockchip/Kconfig
> +++ b/arch/arm/mach-rockchip/Kconfig
> @@ -114,6 +114,7 @@ config ROCKCHIP_RK3399
> select SPL_DRIVERS_MISC_SUPPORT
> select ENABLE_ARM_SOC_BOOT0_HOOK
> select DEBUG_UART_BOARD_INIT
> + select BOARD_LATE_INIT
> help
> The Rockchip RK3399 is a ARM-based SoC with a dual-core Cortex-A72
> and quad-core Cortex-A53.
> @@ -149,6 +150,19 @@ config TPL_ROCKCHIP_BACK_TO_BROM
> SPL will return to the boot rom, which will then load the U-Boot
> binary to keep going on.
>
> +config ROCKCHIP_BOOT_MODE_REG
> + hex "Rockchip boot mode flag register address"
> + default 0x200081c8 if ROCKCHIP_RK3036
> + default 0x110005d8 if ROCKCHIP_RK322X
> + default 0xff730094 if ROCKCHIP_RK3288
> + default 0xff738200 if ROCKCHIP_RK3368
> + default 0xff320300 if ROCKCHIP_RK3399
> + default 0x10300580 if ROCKCHIP_RV1108
could you possibly look up if the rk3188 and rk3066 also support
the subsequent boot to maskrom download mode from the later
patches and include the register if possible?
Thanks
Heiko
next prev parent reply other threads:[~2017-09-21 9:02 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-12 13:55 [U-Boot] [PATCH 0/3] support enter download mode on rockchip platform Andy Yan
2017-09-12 13:57 ` [U-Boot] [PATCH 1/3] rockchip: make boot_mode releated codes reused across all platforms Andy Yan
2017-09-13 4:26 ` Simon Glass
2017-09-21 9:02 ` Heiko Stuebner [this message]
2017-09-21 9:04 ` Andy Yan
2017-09-12 13:57 ` [U-Boot] [PATCH 2/3] rockchip: add support for backing to bootrom download mode Andy Yan
2017-09-13 4:26 ` Simon Glass
2017-09-12 13:58 ` [U-Boot] [PATCH 3/3] rockchip: check download key before bootup Andy Yan
2017-09-13 4:26 ` Simon Glass
2017-09-13 6:14 ` Andy Yan
2017-09-17 17:52 ` Simon Glass
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4551943.4geh5MgojS@phil \
--to=heiko@sntech.de \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.