Skip to content
Snippets Groups Projects
  1. Oct 23, 2011
  2. Oct 10, 2011
  3. Jul 28, 2011
  4. Jan 18, 2011
  5. Jan 10, 2011
    • Michal Simek's avatar
      microblaze: Fix bd_info pointer · 1020286e
      Michal Simek authored
      
      Patch "Replace CONFIG_SYS_GBL_DATA_SIZE by auto-generated value"
      (sha1: 25ddd1fb)
      introduce GENERATED_GBL_DATA_SIZE which is sizeof aligned gd_t
      (currently 0x40).
      Microblaze configs used 0x40(128) because this place also contained
      board info structure which lies on the top of ram.
      
      U-Boot is placed to the top of the ram (for example 0xd7ffffff)
      and bd structure was moved out of ram.
      
      This patch is fixing this scheme with GENERATED_BD_INFO_SIZE
      which swap global data and board info structures.
      
      For example:
      Current: gd 0xd7ffffc0, bd 0xd8000000
      Fixed:   gd 0xd7ffffc0, bd 0xd7ffff90
      
      Signed-off-by: default avatarMichal Simek <monstr@monstr.eu>
      1020286e
  6. Nov 17, 2010
    • Sebastien Carlier's avatar
      Switch from archive libraries to partial linking · 6d8962e8
      Sebastien Carlier authored
      
      Before this commit, weak symbols were not overridden by non-weak symbols
      found in archive libraries when linking with recent versions of
      binutils.  As stated in the System V ABI, "the link editor does not
      extract archive members to resolve undefined weak symbols".
      
      This commit changes all Makefiles to use partial linking (ld -r) instead
      of creating library archives, which forces all symbols to participate in
      linking, allowing non-weak symbols to override weak symbols as intended.
      This approach is also used by Linux, from which the gmake function
      cmd_link_o_target (defined in config.mk and used in all Makefiles) is
      inspired.
      
      The name of each former library archive is preserved except for
      extensions which change from ".a" to ".o".  This commit updates
      references accordingly where needed, in particular in some linker
      scripts.
      
      This commit reveals board configurations that exclude some features but
      include source files that depend these disabled features in the build,
      resulting in undefined symbols.  Known such cases include:
      - disabling CMD_NET but not CMD_NFS;
      - enabling CONFIG_OF_LIBFDT but not CONFIG_QE.
      
      Signed-off-by: default avatarSebastien Carlier <sebastien.carlier@gmail.com>
      6d8962e8
  7. Oct 26, 2010
    • 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>
      25ddd1fb
  8. Oct 18, 2010
    • John Rigby's avatar
      FDT: only call boot_get_fdt from generic code · 5a75e121
      John Rigby authored
      
      All arches except nios2 and microblaze call boot_get_fdt
      from bootm_start in common/cmd_bootm.c.
      
      Having nios2 and microblaze do so as well removes code from
      their respective do_bootm_linux routines and allows removal of
      a nasty ifdef from bootm_start.
      
      In the case where boot_get_fdt returns an error bootm_start
      returns and the platform specific do_bootm_linux routines
      will never get called.
      
      Also only check argv[3] for an fdt addr if argc > 3 first.
      This is already the case for nios2.
      
      Signed-off-by: default avatarJohn Rigby <john.rigby@linaro.org>
      CC: Scott McNutt <smcnutt@psyent.com>
      CC: Michal Simek <monstr@monstr.eu>
      CC: Thomas Chou <thomas@wytron.com.tw>
      Acked-by: default avatarWolfgang Denk <wd@denx.de>
      Acked-by: default avatarMichal Simek <monstr@monstr.eu>
      Tested-by: default avatarThomas Chou <thomas@wytron.com.tw>
      5a75e121
    • Wolfgang Denk's avatar
      Rename TEXT_BASE into CONFIG_SYS_TEXT_BASE · 14d0a02a
      Wolfgang Denk authored
      
      The change is currently needed to be able to remove the board
      configuration scripting from the top level Makefile and replace it by
      a simple, table driven script.
      
      Moving this configuration setting into the "CONFIG_*" name space is
      also desirable because it is needed if we ever should move forward to
      a Kconfig driven configuration system.
      
      Signed-off-by: default avatarWolfgang Denk <wd@denx.de>
      14d0a02a
  9. Oct 12, 2010
  10. Jul 04, 2010
    • Wolfgang Denk's avatar
      Make sure that argv[] argument pointers are not modified. · 54841ab5
      Wolfgang Denk authored
      
      The hush shell dynamically allocates (and re-allocates) memory for the
      argument strings in the "char *argv[]" argument vector passed to
      commands.  Any code that modifies these pointers will cause serious
      corruption of the malloc data structures and crash U-Boot, so make
      sure the compiler can check that no such modifications are being done
      by changing the code into "char * const argv[]".
      
      This modification is the result of debugging a strange crash caused
      after adding a new command, which used the following argument
      processing code which has been working perfectly fine in all Unix
      systems since version 6 - but not so in U-Boot:
      
      int main (int argc, char **argv)
      {
      	while (--argc > 0 && **++argv == '-') {
      /* ====> */	while (*++*argv) {
      			switch (**argv) {
      			case 'd':
      				debug++;
      				break;
      			...
      			default:
      				usage ();
      			}
      		}
      	}
      	...
      }
      
      The line marked "====>" will corrupt the malloc data structures and
      usually cause U-Boot to crash when the next command gets executed by
      the shell.  With the modification, the compiler will prevent this with
      an
      	error: increment of read-only location '*argv'
      
      N.B.: The code above can be trivially rewritten like this:
      
      	while (--argc > 0 && **++argv == '-') {
      		char *arg = *argv;
      		while (*++arg) {
      			switch (*arg) {
      			...
      
      Signed-off-by: default avatarWolfgang Denk <wd@denx.de>
      Acked-by: default avatarMike Frysinger <vapier@gentoo.org>
      54841ab5
  11. Apr 16, 2010
  12. Apr 13, 2010
Loading