From: Tom Rini Date: Fri, 17 May 2013 14:17:19 -0400 Subject: [U-Boot] Building two different "SPL" for the same board? In-Reply-To: <1368813967.3925.23.camel@localhost> References: <1368813967.3925.23.camel@localhost> Message-ID: <20130517181719.GW32163@bill-the-cat> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Fri, May 17, 2013 at 08:06:07PM +0200, Henrik Nordstr?m wrote: > I am looking into reusing the SPL system initialization part for a very > minimalistic "SPL" which only initializes the board. > > To give a bit of context, on the Allwinner CPUs there is a recovery boot > mode where data can be copied over USB and executed by the CPU. But most > of the board including DRAM controller is not initialized by default so > the very first thing you need to do is to upload & execute board > initialization code (but excluding CPU initialization). > > Note: It is not really an SPL as all it does is initializing the board > and then returning control to the USB loader so additional code > (u-boot.bin) can be uploaded to DRAM and executed. > > I have this implemented today partially out-of-tree leaching objects > from an u-boot build to build a binary with the initialization code. My > question is if it would make sense to try integrate this into the u-boot > tree somehow. Have something similar been done for any other board? > > The current "code" is at > https://github.com/linux-sunxi/sunxi-tools/tree/master/felboot > mainly main.c (entry + stubs), the rest is only for a small printf and > is not needed. I would say you want to hypothetically add a _felboot build target for the allwinner boards that instead of building out a regular CONFIG_SPL_FRAMEWORK (I hope!) SPL spits out just a very tiny one that does what you need for this use case. Having different builds for different SPL cases is a normal thing that we do on a few boards, but none are quite so drastically different sounding as this. -- Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: Digital signature URL: