[U-Boot] [PATCH v5 0/5] Clean out SPL and enable driver model
Tom Rini
trini at konsulko.com
Tue Mar 3 15:48:04 CET 2015
On Tue, Mar 03, 2015 at 09:06:15AM -0500, Tom Rini wrote:
> On Mon, Mar 02, 2015 at 09:39:37PM -0700, Simon Glass wrote:
> > Hi Tom,
> >
> > On 2 March 2015 at 17:51, Tom Rini <trini at konsulko.com> wrote:
> > > On Mon, Mar 02, 2015 at 03:19:05PM -0700, Simon Glass wrote:
> > >> Hi,
> > >>
> > >> On 26 February 2015 at 10:26, Simon Glass <sjg at chromium.org> wrote:
> > >> > This series includes a few more patches aimed at getting rid of gdata, the
> > >> > parallel global_data structure introduced on some ARM boards.
> > >> >
> > >> > It also collects together the other patches which have been sent previously,
> > >> > so that everything is in one place.
> > >> >
> > >> > I would like get this agreed and applied to u-boot-dm this week if possible
> > >> > so that we will at last have driver model available in SPL.
> > >> >
> > >> > This series is available at u-boot-dm/spl-working.
> > >> >
> > >> > Changes in v5:
> > >> > - Rebase to master
> > >>
> > >> Are there any more comments on this? I know Albert was looking at
> > >> applying it, but I am tempted to bring it through the u-boot-dm tree
> > >> and get it in. RC3 is soon!
> > >
> > > Did you have something that switched beaglebone black over to this?
> > > Thanks!
> >
> > I think I sent patches at the time but they were too radical. I'm even
> > nervous about the current set which is why I want time for people to
> > test this.
> >
> > I'll dig this up and send a v6.
>
> I recall you had something radical before but I solved those problems (I
> thought!) differently and that brought us back to the need to add
> CONFIG_SPL_STACK_R which shouldn't be a big deal. I'm kicking at the
> problem again differently this morning (aside, conmux + XMODEM is broken
> in conmux it seem which breaks my workflow on some boards pretty bad).
OK, yeah, it's not _that_ bad:
diff --git a/arch/arm/cpu/armv7/am33xx/board.c b/arch/arm/cpu/armv7/am33xx/board.c
index 81477aa..4436413 100644
--- a/arch/arm/cpu/armv7/am33xx/board.c
+++ b/arch/arm/cpu/armv7/am33xx/board.c
@@ -204,18 +204,20 @@ int arch_misc_init(void)
}
#ifndef CONFIG_SKIP_LOWLEVEL_INIT
+#ifdef CONFIG_SPL_BUILD
/*
* In the case of non-SPL based booting we'll want to call these
* functions a tiny bit later as it will require gd to be set and cleared
* and that's not true in s_init in this case so we cannot do it there.
*/
-int board_early_init_f(void)
+void board_init_f(ulong dummy)
{
prcm_init();
set_mux_conf_regs();
- return 0;
+ sdram_init();
}
+#endif
/*
* This function is the place to do per-board things such as ramp up the
@@ -298,9 +300,5 @@ void s_init(void)
/* Enable RTC32K clock */
rtc32k_enable();
#endif
-#ifdef CONFIG_SPL_BUILD
- board_early_init_f();
- sdram_init();
-#endif
}
#endif
diff --git a/configs/am335x_evm_defconfig b/configs/am335x_evm_defconfig
index 2e5aeaa..deecf95 100644
--- a/configs/am335x_evm_defconfig
+++ b/configs/am335x_evm_defconfig
@@ -1,4 +1,6 @@
CONFIG_SPL=y
+CONFIG_CONFIG_SPL_STACK_R=y
+CONFIG_CONFIG_SPL_STACK_R_ADDR=0x82000000
CONFIG_SYS_EXTRA_OPTIONS="NAND"
CONFIG_CONS_INDEX=1
+S:CONFIG_ARM=y
diff --git a/include/configs/ti_armv7_common.h b/include/configs/ti_armv7_common.h
index 2bd1164..1882073 100644
--- a/include/configs/ti_armv7_common.h
+++ b/include/configs/ti_armv7_common.h
@@ -216,7 +216,6 @@
* end of the BSS area. We place our stack at 32MiB after the start of
* DRAM to allow room for all of the above.
*/
-#define CONFIG_SPL_STACK (CONFIG_SYS_SDRAM_BASE + (32 << 20))
#ifndef CONFIG_SYS_TEXT_BASE
#define CONFIG_SYS_TEXT_BASE 0x80800000
#endif
I might even go so far as to say that's a clean-up. I do need to put
this through it's paces tho on am335x and then work on converting the
rest of the families.
But, Albert, shall we put this in right after -rc3?
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20150303/9699afc1/attachment.sig>
More information about the U-Boot
mailing list