From: hl <hl@rock-chips.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v1 01/12] rockchip: define SUPPORT_SPL and SPL config in RK3288 config
Date: Tue, 27 Oct 2015 08:27:48 +0800 [thread overview]
Message-ID: <562EC504.50907@rock-chips.com> (raw)
In-Reply-To: <CAPnjgZ0wHWxNAuaWEtxg1zU3-3UT=RNwxcVzT=x0uTxCgm+5SA@mail.gmail.com>
Hi Simon,
On 26/10/15 12:12, Simon Glass wrote:
>
> Hi,
>
> On Oct 22, 2015 7:22 PM, "hl" <hl@rock-chips.com
> <mailto:hl@rock-chips.com>> wrote:
> >
> > Hi Simon,
> >
> >
> > On 23/10/15 09:04, Simon Glass wrote:
> >>
> >> Hi Eddie,
> >>
> >> On 22 October 2015 at 18:54, Eddie Cai <eddie.cai@rock-chips.com
> <mailto:eddie.cai@rock-chips.com>> wrote:
> >>>
> >>> Hi Simon
> >>>
> >>> 2015-10-23 0:30 GMT+08:00 Simon Glass <sjg@chromium.org
> <mailto:sjg@chromium.org>>:
> >>>>
> >>>> Hi Eddie,
> >>>>
> >>>> On 22 October 2015 at 10:01, Eddie Cai <eddie.cai@rock-chips.com
> <mailto:eddie.cai@rock-chips.com>> wrote:
> >>>>>
> >>>>> Hi Simon
> >>>>>
> >>>>> 2015-10-22 22:07 GMT+08:00 Simon Glass <sjg@chromium.org
> <mailto:sjg@chromium.org>>:
> >>>>>>
> >>>>>> Hi Lin,
> >>>>>>
> >>>>>> On 20 October 2015 at 20:37, Lin Huang <hl@rock-chips.com
> <mailto:hl@rock-chips.com>> wrote:
> >>>>>>>
> >>>>>>> it may not use SPL in other rockchip SOC, so move SUPPORT_SPL and
> >>>>>>> SPL config to rk3288 configuration.
> >>>>>>>
> >>>>>>> Signed-off-by: Lin Huang <hl@rock-chips.com
> <mailto:hl@rock-chips.com>>
> >>>>>>> ---
> >>>>>>> Changes in v1: None
> >>>>>>>
> >>>>>>> arch/arm/Kconfig | 2 --
> >>>>>>> arch/arm/mach-rockchip/Kconfig | 2 ++
> >>>>>>> 2 files changed, 2 insertions(+), 2 deletions(-)
> >>>>>>>
> >>>>>>> diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
> >>>>>>> index 194fb7b..40fa741 100644
> >>>>>>> --- a/arch/arm/Kconfig
> >>>>>>> +++ b/arch/arm/Kconfig
> >>>>>>> @@ -831,8 +831,6 @@ config TARGET_STM32F429_DISCOVERY
> >>>>>>>
> >>>>>>> config ARCH_ROCKCHIP
> >>>>>>> bool "Support Rockchip SoCs"
> >>>>>>> - select SUPPORT_SPL
> >>>>>>> - select SPL
> >>>>>>> select OF_CONTROL
> >>>>>>> select CPU_V7
> >>>>>>> select DM
> >>>>>>> diff --git a/arch/arm/mach-rockchip/Kconfig
> >>>>>>> b/arch/arm/mach-rockchip/Kconfig
> >>>>>>> index ab50f4e..15cd380 100644
> >>>>>>> --- a/arch/arm/mach-rockchip/Kconfig
> >>>>>>> +++ b/arch/arm/mach-rockchip/Kconfig
> >>>>>>> @@ -2,6 +2,8 @@ if ARCH_ROCKCHIP
> >>>>>>>
> >>>>>>> config ROCKCHIP_RK3288
> >>>>>>> bool "Support Rockchip RK3288"
> >>>>>>> + select SUPPORT_SPL
> >>>>>>> + select SPL
> >>>>>>> help
> >>>>>>> The Rockchip RK3288 is a ARM-based SoC with a quad-core
> >>>>>>> Cortex-A17
> >>>>>>> including NEON and GPU, 1MB L2 cache, Mali-T7
> graphics, two
> >>>>>>> --
> >>>>>>> 1.9.1
> >>>>>>>
> >>>>>> We should avoid little binary blobs for booting the chip. I
> think we
> >>>>>> can live with this as a stepping stone to having a proper SPL, but
> >>>>>> what is the plan for a proper SPL in U-Boot?
> >>>>>
> >>>>> RK3036 have only 8k sram. 4k used by boot rom. The ddr
> initialize code
> >>>>> is
> >>>>> almost 4k. So i don't think we can do SPL.
> >>>>
> >>>> How does U-Boot get loaded in this case? Does it use ROM code? If so
> >>>
> >>> Yes, it use boot rom code to load U-Boot
> >>>>
> >>>> then I think we should create an SPL that handles the DDR init and
> >>>> then returns to the ROM code for loading U-Boot. Also we should
> >>>> document how this works in the README.
> >>>
> >>> It is a good news you agree we can return to boot rom from SPL. Do
> you know
> >>> what size of sram a smallest SPL need?
> >>
> >> Exynos does something a little similar - it has a jump table of ROM
> >> routines that SPL can call.
> >>
> >> You can essentially write your own code for SPL. I very much hope you
> >> can use start.S and cro0.S, but these add up to a tiny amount of code
> >> so should not cause problems. You should be able to put all of your
> >> code into your implementation of board_init_f(), using most of the 4KB
> >> available. U-Boot's SPL framework does add some overhead, but if you
> >> leave out the board_init_r() implementation this is very small.
> >>
> >> If you do get stuck and find the size if over 4KB we should discuss it
> >> and see what can be done.
> >
> >
> > Okay, i will reference exynos to see how to do, thank you.
> >
>
> One last point... U-Boot is written in C so as much as possible of
> this should be C, rather than assembler.
>
Thank you for pointing that. I try to get a clean SPL(only
timer and uart driver), and it can work now,
it take about 600 bytes, i will start to port ddr driver.
>
> Regards,
> Simon
>
--
Lin Huang
next prev parent reply other threads:[~2015-10-27 0:27 UTC|newest]
Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-21 2:37 [U-Boot] [PATCH v1 00/12] Bring up rk3036 uboot Lin Huang
2015-10-21 2:37 ` [U-Boot] [PATCH v1 01/12] rockchip: define SUPPORT_SPL and SPL config in RK3288 config Lin Huang
2015-10-22 14:07 ` Simon Glass
2015-10-22 16:01 ` Eddie Cai
2015-10-22 16:30 ` Simon Glass
2015-10-23 0:54 ` Eddie Cai
2015-10-23 1:04 ` Simon Glass
2015-10-23 1:21 ` hl
2015-10-26 4:12 ` Simon Glass
2015-10-27 0:27 ` hl [this message]
2015-10-27 19:03 ` Simon Glass
2015-10-23 0:50 ` hl
2015-10-23 0:54 ` Simon Glass
2015-10-21 2:37 ` [U-Boot] [PATCH v1 02/12] rockchip: implement rockchip timer init function Lin Huang
2015-10-22 14:07 ` Simon Glass
2015-10-21 2:37 ` [U-Boot] [PATCH v1 03/12] rockchip: serial driver support rk3036 Lin Huang
2015-10-22 14:07 ` Simon Glass
2015-10-23 0:51 ` hl
2015-10-21 2:37 ` [U-Boot] [PATCH v1 04/12] rockchip: Bring in RK3036 device tree file includes and bindings Lin Huang
2015-10-22 14:07 ` Simon Glass
2015-10-21 2:37 ` [U-Boot] [PATCH v1 05/12] rockchip: rk3036: Add clock driver Lin Huang
2015-10-22 14:07 ` Simon Glass
2015-10-23 0:56 ` hl
2015-10-21 2:37 ` [U-Boot] [PATCH v1 06/12] rockchip: rk3036: Add header files for GRF Lin Huang
2015-10-22 14:07 ` Simon Glass
2015-10-21 2:37 ` [U-Boot] [PATCH v1 07/12] rockchip: rk3036: Add Soc reset driver Lin Huang
2015-10-22 14:07 ` Simon Glass
2015-10-21 2:37 ` [U-Boot] [PATCH v1 08/12] rockchip: rk3036: Add a simple syscon driver Lin Huang
2015-10-22 14:08 ` Simon Glass
2015-10-21 2:37 ` [U-Boot] [PATCH v1 09/12] rockchip: rk3036: Add pinctrl driver Lin Huang
2015-10-22 14:08 ` Simon Glass
2015-10-21 2:37 ` [U-Boot] [PATCH v1 10/12] rockchip: Add an rk3036 MMC driver Lin Huang
2015-10-22 14:08 ` Simon Glass
2015-10-23 1:03 ` hl
2015-10-21 2:37 ` [U-Boot] [PATCH v1 11/12] rockchip: rk3036: Add core Soc start-up code Lin Huang
2015-10-22 14:08 ` Simon Glass
2015-10-21 2:37 ` [U-Boot] [PATCH v1 12/12] rockchip: Add basic support for evb-rk3036 board Lin Huang
2015-10-22 14:08 ` Simon Glass
2015-10-23 1:27 ` hl
2015-10-23 1:34 ` Simon Glass
2015-10-23 2:50 ` hl
2015-10-23 2:53 ` Simon Glass
-- strict thread matches above, loose matches on Subject: below --
2015-10-21 5:37 [U-Boot] [PATCH v1 00/12] Bring up rk3036 uboot Lin Huang
2015-10-21 5:37 ` [U-Boot] [PATCH v1 01/12] rockchip: define SUPPORT_SPL and SPL config in RK3288 config Lin Huang
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=562EC504.50907@rock-chips.com \
--to=hl@rock-chips.com \
--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.