Re: [U-Boot] [PATCH 0/9] Remove use of gdata for global_data

2015-01-18 Thread Albert ARIBAUD
Hello Simon,

On Tue, 23 Dec 2014 12:04:50 -0700, Simon Glass s...@chromium.org
wrote:
 Some ARM boards use global_data in SPL before it set up by crt0.S. To
 achieve this they use a separate global_data variable called gdata which
 resides in the data section. The one set up by crt0.S is generally ignored.
 
 This prevents crt0.S from setting up things like the early malloc() pool.
 It therefore prevents driver model from being used in SPL.
 
 However gdata really isn't needed. In fact lowlevel_init() is called just
 before board_init_f() so, for SPL at least, there is no point in doing
 anything before board_init_f(). The one slightly messy area is that SPL
 may want to move the stack from SRAM to SDRAM at some point. But this should
 be done at the end of board_init_f() (or before board_init_r() is called)
 and is not a reason to init DRAM before board_init_f().
 
 It isn't that difficult to get rid of gdata. This series builds on Tom Rini's
 recent series for omap3, and extends it to the other offenders: imx, sunxi
 and zynq.
 
 I have tested so far only on sunxi. This series is available at u-boot-dm
 branch 'gd-working'.

Overall series:

Acked-by: Albert ARIBAUD albert.u.b...@aribaud.net

Amicalement,
-- 
Albert.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/9] Remove use of gdata for global_data

2014-12-28 Thread Ian Campbell
On Tue, 2014-12-23 at 12:04 -0700, Simon Glass wrote:
 Some ARM boards use global_data in SPL before it set up by crt0.S. To
 achieve this they use a separate global_data variable called gdata which
 resides in the data section. The one set up by crt0.S is generally ignored.
 
 This prevents crt0.S from setting up things like the early malloc() pool.
 It therefore prevents driver model from being used in SPL.
 
 However gdata really isn't needed. In fact lowlevel_init() is called just
 before board_init_f() so, for SPL at least, there is no point in doing
 anything before board_init_f(). The one slightly messy area is that SPL
 may want to move the stack from SRAM to SDRAM at some point. But this should
 be done at the end of board_init_f() (or before board_init_r() is called)
 and is not a reason to init DRAM before board_init_f().
 
 It isn't that difficult to get rid of gdata. This series builds on Tom Rini's
 recent series for omap3, and extends it to the other offenders: imx, sunxi
 and zynq.
 
 I have tested so far only on sunxi.

Did you test both FEL and regular mode? (IOW, to what extent do I need
to refresh my memory on the differences between the two...)


  This series is available at u-boot-dm
 branch 'gd-working'.
 
 
 Simon Glass (9):
   arm: Add warnings about using gdata
   sunxi: Move SPL s_init() code to board_init_f()
   sunxi: Drop use of lowlevel_init()
   arm: Reduce the scope of lowlevel_init()
   zynq: Remove reference to gdata
   imx: cm_fx6: Remove reference to gdata
   imx: woodburn: Remove reference to gdata
   imx: ls102xa: Remove reference to gdata
   arm: Drop gdata global_data variable in SPL
 
  arch/arm/cpu/armv7/lowlevel_init.S  | 23 +++-
  arch/arm/cpu/armv7/sunxi/board.c| 66 
 -
  arch/arm/cpu/armv7/zynq/spl.c   |  3 --
  arch/arm/include/asm/spl.h  |  2 -
  arch/arm/lib/spl.c  | 11 +++---
  board/compulab/cm_fx6/spl.c |  1 -
  board/freescale/ls1021aqds/ls1021aqds.c |  3 --
  board/freescale/ls1021atwr/ls1021atwr.c |  3 --
  board/woodburn/woodburn.c   |  3 --
  include/configs/sunxi-common.h  |  1 +
  10 files changed, 53 insertions(+), 63 deletions(-)
 


___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH 0/9] Remove use of gdata for global_data

2014-12-23 Thread Simon Glass
Some ARM boards use global_data in SPL before it set up by crt0.S. To
achieve this they use a separate global_data variable called gdata which
resides in the data section. The one set up by crt0.S is generally ignored.

This prevents crt0.S from setting up things like the early malloc() pool.
It therefore prevents driver model from being used in SPL.

However gdata really isn't needed. In fact lowlevel_init() is called just
before board_init_f() so, for SPL at least, there is no point in doing
anything before board_init_f(). The one slightly messy area is that SPL
may want to move the stack from SRAM to SDRAM at some point. But this should
be done at the end of board_init_f() (or before board_init_r() is called)
and is not a reason to init DRAM before board_init_f().

It isn't that difficult to get rid of gdata. This series builds on Tom Rini's
recent series for omap3, and extends it to the other offenders: imx, sunxi
and zynq.

I have tested so far only on sunxi. This series is available at u-boot-dm
branch 'gd-working'.


Simon Glass (9):
  arm: Add warnings about using gdata
  sunxi: Move SPL s_init() code to board_init_f()
  sunxi: Drop use of lowlevel_init()
  arm: Reduce the scope of lowlevel_init()
  zynq: Remove reference to gdata
  imx: cm_fx6: Remove reference to gdata
  imx: woodburn: Remove reference to gdata
  imx: ls102xa: Remove reference to gdata
  arm: Drop gdata global_data variable in SPL

 arch/arm/cpu/armv7/lowlevel_init.S  | 23 +++-
 arch/arm/cpu/armv7/sunxi/board.c| 66 -
 arch/arm/cpu/armv7/zynq/spl.c   |  3 --
 arch/arm/include/asm/spl.h  |  2 -
 arch/arm/lib/spl.c  | 11 +++---
 board/compulab/cm_fx6/spl.c |  1 -
 board/freescale/ls1021aqds/ls1021aqds.c |  3 --
 board/freescale/ls1021atwr/ls1021atwr.c |  3 --
 board/woodburn/woodburn.c   |  3 --
 include/configs/sunxi-common.h  |  1 +
 10 files changed, 53 insertions(+), 63 deletions(-)

-- 
2.2.0.rc0.207.ga3a616c

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot