[U-Boot-Users] compile problem

Rick Bronson rick at efn.org
Tue Feb 18 01:36:30 CET 2003


Hi,

  I'm trying to put regualar NAND (not DiskonChip) support into uboot but
have ran into a problem with the compiler (I think).  Here is my
compile line:

/opt/hardhat/devkit/arm/sa_le/bin/arm_sa_le-gcc -D__KERNEL__ -I/home/rick/mms/emerald/boot/u-boot-0.2.0/include  -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -Uarm -fno-common -pipe -g -mapcs-32 -D__ARM__ -DTEXT_BASE=0x21fa0000 -D__LINUX_ARM_ARCH__=4 -march=armv4 -mtune=arm9tdmi -mshort-load-bytes -msoft-float   -Wa,-alh,-L  -c -o cmd_nand.o cmd_nand.c > cmd_nand.lst

Here is the output (lots of stuff truncated):

 805:cmd_nand.c    **** int nand_read_ecc(struct nand_chip *nand, loff_t start, size_t len,
 806:cmd_nand.c    **** 		 size_t * retlen, u_char *buf, u_char *ecc_code)
 3212 1214 0380A0E1 	mov r8,r3
 818:cmd_nand.c    **** 	printf ("nand_read_ecc1: %x\n", (uint) len);
 3219              	.stabn 68,0,818,.LM421-nand_read_ecc
 3220              	.LM421:
 3221 1220 04039FE5 	ldr r0,.L461+4
 3222 1224 0810A0E1 	mov r1,r8
 3223 1228 FEFFFFEB 	bl printf

nand should be in r0
start should be in r1
len should be in r2
retlen should be in r3

  On line 3212 retlen gets put in r8, on line 818 printf is called to
  print "len" but instead retlen is printed.

  Anyone have any clue on this one?

  Thanks much.

  Rick Bronson




More information about the U-Boot mailing list