From mboxrd@z Thu Jan 1 00:00:00 1970 From: Johannes Stezenbach Date: Thu, 24 Jan 2008 16:10:40 +0100 Subject: [U-Boot-Users] [patch 0/3] KB9202 CodeSourcery ARM EABI toolchainbuild fixes In-Reply-To: <000101c85dd5$e94cc980$9a4d010a@Emea.Arm.com> References: <20071025161052.790841794@sig21.net> <000101c85dd5$e94cc980$9a4d010a@Emea.Arm.com> Message-ID: <20080124151040.GA18167@sig21.net> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Wed, Jan 23, 2008, Peter Pearse wrote: > > -----Original Message----- > > From: u-boot-users-bounces at lists.sourceforge.net > > [mailto:u-boot-users-bounces at lists.sourceforge.net] On Behalf > > Of Johannes Stezenbach > > Sent: 25 October 2007 17:11 > > > > I wanted to build u-boot-1.3.0-rc3 for the KwikByte KB9202 > > board with the current ARM toolchain from CodeSourcery. > > I needed the following three patches to get it to build. > > > > The first one is probably a bugfix needed for other toolchains, too. > > Thanks for this - it has alerted me to the use of > sub rx, rx, #CONSTANT in several of the ARM .S assembler files. > Whilst sub rx, rx, #CONSTANT saves code size it does demand > that users understand their constants, what they are for and where > they are used. > For ARM #CONSTANT in this context must be capable of being formed by > rotating > an 8 bit constant in a 32 bit register > e.g. 0x22000 is allowed whereas 0x20200 is not. > > I am going to reject your patch though. It is the code that should be > changed. > I have added an action to my list of required patches > http://www.denx.de/wiki/UBoot/PatchStatus to examine the use of constants in > the ARM assembler > code. The simple patch below at least circumvents the problem and allows u-boot to build for the kb9202. Please consider applying this one. It is not toolchain specific. > > The other two patches are specific to the CodeSourcery > > toolchain (or probably to any EABI toolchain with gcc-4.2.x). > > I haven't checked if they break the build for other ARM > > toolchains, so it's probably better to not apply them unless > > someone else confirms they're OK. > > > > Thanks for submitting these - they will be of use/interest to users building > EABI code. > > However I do not propose to submit them to the main tree since they are > toolchain > specific. The standard toolchain for building U-Boot is that supplied in the > ELDK > http://www.denx.de/wiki/DULG/ELDK. > Of course many users have reasons for using others, however to support all > possible > toolchains would result in a support nightmare..... The patch propsed in [U-Boot-Users] [patch u-boot git 2/3] better ARM9 compiler options From: David Brownell - 2008-01-18 20:55 http://sourceforge.net/mailarchive/forum.php?thread_name=200801181250.50303.david-b%40pacbell.net&forum_name=u-boot-users would take care of the CodeSourcery build issues, too. It should work with any toolchain. --- KB9202 compile fix make -C cpu/arm920t start.o ... start.S: Assembler messages: start.S:205: Error: invalid constant (20200) after fixup etc. The environment size is the same as in the kb9202 patch available from www.kwikbyte.com. Signed-off-by: Johannes Stezenbach diff --git a/include/configs/kb9202.h b/include/configs/kb9202.h index 75d9c3b..88e8737 100644 --- a/include/configs/kb9202.h +++ b/include/configs/kb9202.h @@ -128,8 +128,8 @@ #define CFG_ENV_IS_IN_EEPROM #ifdef CONFIG_KB9202 -#define CFG_ENV_OFFSET 0x3E00 -#define CFG_ENV_SIZE 0x0200 +#define CFG_ENV_OFFSET 0x2000 +#define CFG_ENV_SIZE 0x2000 #else #define CFG_ENV_OFFSET 0x1000 #define CFG_ENV_SIZE 0x1000 Thanks, Johannes