From: Alexander Holler <holler@ahsoftware.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] Most ARM CPU's have buggy clear_bss?
Date: Fri, 29 Oct 2010 16:37:04 +0200 [thread overview]
Message-ID: <4CCADC10.9010205@ahsoftware.de> (raw)
In-Reply-To: <4CCACE26.8060104@free.fr>
Hello,
I don't quote the rest, just read the mails before. ;)
Here is the what I've done with the current head and the resulting output:
------------------------------------------------------------------------
dockstar2 u-boot.git # vim drivers/mtd/nand/nand.c (adding printf)
dockstar2 u-boot.git # vim arch/arm/lib/board.c (adding #define DEBUG)
dockstar2 u-boot.git # make distclean
awk '(NF && $1 !~ /^#/) { print $1 ": " $1 "_config; $(MAKE)" }'
boards.cfg > .boards.depend
Generating include/autoconf.mk
dockstar2 u-boot.git # make sheevaplug_config
awk '(NF && $1 !~ /^#/) { print $1 ": " $1 "_config; $(MAKE)" }'
boards.cfg > .boards.depend
Configuring for sheevaplug board...
dockstar2 u-boot.git # make u-boot.bin
Generating include/autoconf.mk
Generating include/autoconf.mk.dep
...
make[1]: Entering directory `/usr/src/u-boot.git/drivers/mtd/nand'
gcc -g -Os -fno-common -ffixed-r8 -msoft-float -D__KERNEL__
-DCONFIG_SYS_TEXT_BASE=0x00700000 -I/usr/src/u-boot.git/include
-fno-builtin -ffreestanding -nostdinc -isystem
/usr/lib/gcc/armv5tel-softfloat-linux-gnueabi/4.5.1/include -pipe
-DCONFIG_ARM -D__ARM__ -marm -mabi=aapcs-linux -mno-thumb-interwork
-march=armv5te -Wall -Wstrict-prototypes -fno-stack-protector \
-o nand.o nand.c -c
...
------------------------------------------------------------------------
Output (I've changed CONFIG_SYS_TEXT_BASE to 0x00700000 along with some
other patches neccessary for my board like different RAM size) to test
u-boot through chainloading):
------------------------------------------------------------------------
Hit any key to stop autoboot: 0
Marvell>> tftpboot 0x700000 u-boot.bin
Using egiga0 device
TFTP from server 192.168.207.1; our IP address is 192.168.207.25
Filename 'u-boot.bin'.
Load address: 0x700000
Loading: ##########################
done
Bytes transferred = 369168 (5a210 hex)
Marvell>> g 0x700000
## Starting application at 0x00700000 ...
U-Boot 2010.12-rc1-00009-g27b7641-dirty (Oct 29 2010 - 15:58:59)
Seagate-DockStar
U-Boot code: 00700000 -> 0075A210 BSS: -> 007A0300
SoC: Kirkwood 88F6281_A0
monitor len: 000A0300
ramsize: 08000000
TLB table at: 07ff0000
Top of RAM usable for U-Boot at: 07ff0000
Reserving 640k for U-Boot at: 07f4f000
Reserving 1152k for malloc() at: 07e2f000
Reserving 48 Bytes for Board Info at: 07e2efd0
Reserving 92 Bytes for Global Data at: 07e2ef74
New Stack Pointer is: 07e2ef70
RAM Configuration:
Bank #0: 00000000 128 MiB
Bank #1: 00000000 0 Bytes
Bank #2: e7dfe27e 4 GiB
Bank #3: 7fdbe1ce 2.7 GiB
relocation Offset is: 0784f000
monitor flash len: 0005A210
Now running in RAM - U-Boot at: 07f4f000
NAND: nand_chip: 0075d198 (this is &nand_chip[0])
(nothing else => killed through calling chip->cmdfunc)
------------------------------------------------------------------------
Output after adding -fPIC:
------------------------------------------------------------------------
Hit any key to stop autoboot: 0
Marvell>> tftpboot 0x700000 u-boot.bin
Using egiga0 device
TFTP from server 192.168.207.1; our IP address is 192.168.207.25
Filename 'u-boot.bin'.
Load address: 0x700000
Loading: ##########################
done
Bytes transferred = 377360 (5c210 hex)
Marvell>> g 0x700000
## Starting application at 0x00700000 ...
U-Boot 2010.12-rc1-00009-g27b7641-dirty (Oct 29 2010 - 16:17:01)
Seagate-DockStar
U-Boot code: 00700000 -> 0075C210 BSS: -> 007A2300
SoC: Kirkwood 88F6281_A0
monitor len: 000A2300
ramsize: 08000000
TLB table at: 07ff0000
Top of RAM usable for U-Boot at: 07ff0000
Reserving 648k for U-Boot at: 07f4d000
Reserving 1152k for malloc() at: 07e2d000
Reserving 48 Bytes for Board Info at: 07e2cfd0
Reserving 92 Bytes for Global Data at: 07e2cf74
New Stack Pointer is: 07e2cf70
RAM Configuration:
Bank #0: 00000000 128 MiB
Bank #1: 00000000 0 Bytes
Bank #2: 0197f8ff 3.3 GiB
Bank #3: 0f0c0cab 3.5 GiB
relocation Offset is: 0784d000
monitor flash len: 0005C210
Now running in RAM - U-Boot at: 07f4d000
NAND: nand_chip: 07fac198 (this is &nand_chip[0])
256 MiB
nand_scan_bbt: Out of memory
ERROR: Cannot import environment: errno = 0
at env_common.c:221/env_import()
*** Warning - import failed, using default environment
ERROR: Environment import failed: errno = 12
at env_common.c:192/set_default_env()
------------------------------------------------------------------------
Up to now I haven't found the time to checked the error I'm getting
here, but at least the output from the printf looks correct. Just ignore
the wrong DRAM sizes, this is already fixed but I haven't that for these
two tests.
The two nand.s are available at my server:
http://ahsoftware.de/nand.s.notworking.gcc.4.5.1_without-fpic
generated with:
gcc -g -Os -fno-common -ffixed-r8 -msoft-float -D__KERNEL__
-DCONFIG_SYS_TEXT_BASE=0x00700000 -I/usr/src/u-boot.git/include
-fno-builtin -ffreestanding -nostdinc -isystem
/usr/lib/gcc/armv5tel-softfloat-linux-gnueabi/4.5.1/include -pipe
-DCONFIG_ARM -D__ARM__ -marm -mabi=aapcs-linux -mno-thumb-interwork
-march=armv5te -Wall -Wstrict-prototypes -fno-stack-protector -S nand.c
http://ahsoftware.de/nand.s.working.gcc.4.5.1_with-fpic
generated with
gcc -g -Os -fno-common -ffixed-r8 -msoft-float -fPIC -D__KERNEL__
-DCONFIG_SYS_TEXT_BASE=0x00700000 -I/usr/src/u-boot.git/include
-fno-builtin -ffreestanding -nostdinc -isystem
/usr/lib/gcc/armv5tel-softfloat-linux-gnueabi/4.5.1/include -pipe
-DCONFIG_ARM -D__ARM__ -marm -mabi=aapcs-linux -mno-thumb-interwork
-march=armv5te -Wall -Wstrict-prototypes -fno-stack-protector -S nand.c
Regards,
Alexander
next prev parent reply other threads:[~2010-10-29 14:37 UTC|newest]
Thread overview: 56+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-27 7:26 [U-Boot] Most ARM CPU's have buggy clear_bss? Darius Augulis
2010-10-27 8:01 ` Sughosh Ganu
2010-10-27 8:22 ` Darius Augulis
2010-10-27 8:54 ` Sughosh Ganu
2010-10-27 8:58 ` Darius Augulis
2010-10-27 9:09 ` Sughosh Ganu
2010-10-27 10:10 ` Darius Augulis
2010-10-27 10:40 ` Wolfgang Denk
2010-10-27 10:59 ` Darius Augulis
2010-10-27 11:41 ` Wolfgang Denk
2010-10-27 15:12 ` Eric Cooper
2010-10-27 18:11 ` Darius Augulis
2010-10-28 5:50 ` Heiko Schocher
2010-10-28 6:09 ` Reinhard Meyer
2010-10-28 6:17 ` Heiko Schocher
2010-10-28 6:20 ` Reinhard Meyer
2010-10-28 6:23 ` Reinhard Meyer
2010-10-28 6:35 ` Heiko Schocher
2010-10-28 6:14 ` Heiko Schocher
2010-10-28 6:36 ` Reinhard Meyer
2010-10-28 6:56 ` Darius Augulis
2010-10-28 8:36 ` Wolfgang Denk
2010-10-28 8:31 ` Wolfgang Denk
2010-10-28 8:39 ` Wolfgang Denk
2010-10-28 8:53 ` Heiko Schocher
2010-10-28 10:23 ` Alexander Holler
2010-10-28 11:16 ` Reinhard Meyer
2010-10-28 11:38 ` Wolfgang Denk
2010-10-28 11:55 ` Reinhard Meyer
2010-10-29 9:29 ` Albert ARIBAUD
2010-10-28 11:46 ` [U-Boot] CONFIG_SKIP_RELOCATE_UBOOT still used? Alexander Holler
2010-10-29 9:32 ` Albert ARIBAUD
2010-10-29 11:32 ` Alexander Holler
2010-10-29 11:43 ` Albert ARIBAUD
2010-10-29 11:48 ` Wolfgang Denk
2010-10-28 9:03 ` [U-Boot] Most ARM CPU's have buggy clear_bss? Alexander Holler
2010-10-28 9:31 ` Alexander Holler
2010-10-29 8:50 ` Alexander Holler
2010-10-29 9:19 ` Albert ARIBAUD
2010-10-29 11:56 ` Alexander Holler
2010-10-29 12:08 ` Albert ARIBAUD
2010-10-29 12:31 ` Alexander Holler
2010-10-29 13:37 ` Albert ARIBAUD
2010-10-29 13:50 ` Alexander Holler
2010-10-29 14:04 ` Albert ARIBAUD
2010-10-29 14:37 ` Alexander Holler [this message]
2010-10-29 14:44 ` Wolfgang Denk
2010-10-29 14:50 ` Alexander Holler
2010-10-29 14:50 ` Reinhard Meyer
2010-10-29 14:58 ` Alexander Holler
2010-10-29 14:54 ` Albert ARIBAUD
2010-10-29 15:05 ` Alexander Holler
2010-10-29 15:23 ` Albert ARIBAUD
2010-10-29 15:32 ` Alexander Holler
2010-10-29 15:38 ` Albert ARIBAUD
2010-10-29 16:56 ` Alexander Holler
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4CCADC10.9010205@ahsoftware.de \
--to=holler@ahsoftware.de \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox