1. 06 Mar, 2015 1 commit
  2. 14 Dec, 2014 1 commit
  3. 21 Nov, 2014 1 commit
  4. 23 Jul, 2014 1 commit
    • Simon Glass's avatar
      Add a simple malloc() implementation for pre-relocation · d59476b6
      Simon Glass authored
      If we are to have driver model before relocation we need to support some
      way of calling memory allocation routines.
      The standard malloc() is pretty complicated:
      1. It uses some BSS memory for its state, and BSS is not available before
      2. It supports algorithms for reducing memory fragmentation and improving
      performace of free(). Before relocation we could happily just not support
      3. It includes about 4KB of code (Thumb 2) and 1KB of data. However since
      this has been loaded anyway this is not really a problem.
      The simplest way to support pre-relocation malloc() is to reserve an area
      of memory and allocate it in increasing blocks as needed. This
      implementation does this.
      To enable it, you need to define the size of the malloc() pool as described
      in the README. It will be located above the pre-relocation stack on
      supported architectures.
      Note that this implementation is only useful on machines which have some
      memory available before dram_init() is called - this includes those that
      do no DRAM init (like tegra) and those that do it in SPL (quite a few
      boards). Enabling driver model preior to relocation for the rest of the
      boards is left for a later exercise.
      Signed-off-by: default avatarSimon Glass <sjg@chromium.org>
  5. 24 Jul, 2013 1 commit
  6. 08 Jan, 2013 1 commit
    • Albert ARIBAUD's avatar
      arm: move C runtime setup code in crt0.S · e05e5de7
      Albert ARIBAUD authored
      Move all the C runtime setup code from every start.S
      in arch/arm into arch/arm/lib/crt0.S. This covers
      the code sequence from setting up the initial stack
      to calling into board_init_r().
      Also, rewrite the C runtime setup and make functions
      board_init_*() and relocate_code() behave according to
      normal C semantics (no jumping across the C stack any
      more, etc).
      Some SPL targets had to be touched because they use
      start.S explicitly or for some reason; the relevant
      maintainers and custodians are cc:ed.
      Signed-off-by: default avatarAlbert ARIBAUD <albert.u.boot@aribaud.net>
  7. 17 Jan, 2011 1 commit
  8. 09 Jan, 2011 1 commit
  9. 26 Oct, 2010 2 commits
    • Wolfgang Denk's avatar
      Replace CONFIG_SYS_GBL_DATA_SIZE by auto-generated value · 25ddd1fb
      Wolfgang Denk authored
      CONFIG_SYS_GBL_DATA_SIZE has always been just a bad workarond for not
      being able to use "sizeof(struct global_data)" in assembler files.
      Recent experience has shown that manual synchronization is not
      reliable enough.  This patch renames CONFIG_SYS_GBL_DATA_SIZE into
      GENERATED_GBL_DATA_SIZE which gets automatically generated by the
      asm-offsets tool.  In the result, all definitions of this value can be
      deleted from the board config files.  We have to make sure that all
      files that reference such data include the new <asm-offsets.h> file.
      No other changes have been done yet, but it is obvious that similar
      changes / simplifications can be done for other, related macro
      definitions as well.
      Signed-off-by: default avatarWolfgang Denk <wd@denx.de>
      Acked-by: default avatarKumar Gala <galak@kernel.crashing.org>
    • Wolfgang Denk's avatar
      include/asm-offsets.h: automatically generate assembler constants · 16a354f9
      Wolfgang Denk authored
      A recurrent issue is that certain C level constructs like sizeof() or
      offsetof() cannot be used in assembler files, which is inconvenient
      when such constructs are used in the definition of macro names etc.
      To avoid duplication of such definitions (and thus another cause of
      problems), we adapt the Linux way to automatically generate the
      respective definitions from the respective C header files.
      In Linux, this is implemented in include/linux/kbuild.h, Kbuild, and
      arch/*/kernel/asm-offsets.c; we adapt the code from the Linux v2.6.36
      kernel tree.
      We also copy the concept of the include/generated/ directory which can
      be used to hold other automatically generated files as well.
      We start with an architecture-independent lib/asm-offsets.c which
      generates include/generated/generic-asm-offsets.h (included by
      include/asm-offsets.h, which is what will be referred to in the actual
      source code).  Later this may be extended by architecture-specific
      arch/*/lib/asm-offsets.c files that will generate a
      Signed-off-by: default avatarWolfgang Denk <wd@denx.de>
      Acked-by: default avatarKumar Gala <galak@kernel.crashing.org>