• Wolfgang Denk's avatar
    TQM8xx[LM]: Fix broken environment alignment. · 67c31036
    Wolfgang Denk authored
    With recent toolchains, the environment sectors were no longer aligned to
    sector boundaries. The reason was a combination of two bugs:
    
    1) common/environment.c assumed that CONFIG_TQM8xxL would be defined
       for all TQM8xxL and TQM8xxM boards. But "include/common.h", where
       this gets defined, is not included here (and cannot be included
       without causing lots of problems).
    
       Added a new #define CFG_USE_PPCENV for all boards which really
       want to put the environment is a ".ppcenv" section.
    
    2) The linker scripts just include environment.o, silently assuming
       that the objects in that file are really in the order in which
       they are coded in the C file, i. e. "environment" first, then
       "redundand_environment", and "env_size" last. However, current
       toolchains (GCC-4.x) reorder the objects, causing the environment
       data not to start on a flash sector boundary:
    
       Instead of:					we got:
    
    	40008000 T environment			40008000 T env_size
    	4000c000 T redundand_environment	40008004 T redundand_environment
    	40010000 T env_size			4000c004 T environment
    
       Note: this patch fixes just the first part, and cures the alignment
       problem by making sure that "env_size" gets placed correctly. However,
       we still have a potential issue because primary and redundant
       environment sectors are actually swapped, i. e. we have now:
    
    	40008000 T redundand_environment
    	4000c000 T environment
    	40010000 T env_size
    
       This shall be fixed in the next version.
    Signed-off-by: default avatarWolfgang Denk <wd@denx.de>
    67c31036
Name
Last commit
Last update
board Loading commit data...
common Loading commit data...
cpu Loading commit data...
disk Loading commit data...
doc Loading commit data...
drivers Loading commit data...
dtt Loading commit data...
examples Loading commit data...
fs Loading commit data...
include Loading commit data...
lib_arm Loading commit data...
lib_avr32 Loading commit data...
lib_blackfin Loading commit data...
lib_generic Loading commit data...
lib_i386 Loading commit data...
lib_m68k Loading commit data...
lib_microblaze Loading commit data...
lib_mips Loading commit data...
lib_nios Loading commit data...
lib_nios2 Loading commit data...
lib_ppc Loading commit data...
libfdt Loading commit data...
nand_spl Loading commit data...
net Loading commit data...
post Loading commit data...
rtc Loading commit data...
tools Loading commit data...
CHANGELOG Loading commit data...
CHANGELOG-before-U-Boot-1.1.5 Loading commit data...
COPYING Loading commit data...
CREDITS Loading commit data...
MAINTAINERS Loading commit data...
MAKEALL Loading commit data...
Makefile Loading commit data...
README Loading commit data...
arm_config.mk Loading commit data...
avr32_config.mk Loading commit data...
blackfin_config.mk Loading commit data...
config.mk Loading commit data...
i386_config.mk Loading commit data...
m68k_config.mk Loading commit data...
microblaze_config.mk Loading commit data...
mips_config.mk Loading commit data...
mkconfig Loading commit data...
nios2_config.mk Loading commit data...
nios_config.mk Loading commit data...
ppc_config.mk Loading commit data...
rules.mk Loading commit data...