From: Xiangfu Liu <xiangfu@openmobilefree.net>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v3 3/5] jz4740 nand spl files
Date: Sun, 09 Jan 2011 23:48:01 +0800 [thread overview]
Message-ID: <4D29D8B1.2090605@openmobilefree.net> (raw)
In-Reply-To: <20101213180535.002bfd85@udp111988uds.am.freescale.net>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi Scott
>
> I don't see any of my comments on v3 addressed or responded to:
> http://lists.denx.de/pipermail/u-boot/2010-December/083601.html
On 12/14/2010 08:05 AM, Scott Wood wrote:
>> nand_spl/nand_boot_jz4740.c | 344 +++++++++++++++++++++++++++++
>
> As I asked last time, is there any reason you can't use the standard
> nand_boot.c? Your non-SPL NAND driver looks like the type that would
> work with it.
thanks for point out, in next version patches, I will remove the nand_boot_jz4740.c
>
>> +LDSCRIPT= $(TOPDIR)/nand_spl/board/$(BOARDDIR)/u-boot.lds
>> +LDFLAGS = -Bstatic -T $(LDSCRIPT) -Ttext $(TEXT_BASE)
>> +AFLAGS += -DCONFIG_NAND_SPL
>> +CFLAGS += -DCONFIG_NAND_SPL -O2
>
> Are you sure you want -O2 and not -Os? What are the space constraints
> for this SPL?
>
the nand_spl must less then 8kb.
~~~
#The boot program can load two areas of data from NAND flash to internal SRAM, one is the normal
#area up to 8KB starting from NAND flash address 0, the other is the backup area up to 8KB starting
#from NAND flash address 0x2000. After reset, the boot program will first read the normal area data
#from NAND flash using hardware Reed-Solomon ECC. If no ECC error is detected or ECC error is
#correctable, the boot program then branches to internal SRAM at 4 bytes offset. If it detects an
#uncorrectable ECC error, it will continue to read the backup area of data from NAND flash using
#hardware Reed-Solomon ECC.
~~~
I try to add "-Os", then I got some compile error:
~~~
mipsel-openwrt-linux-gcc -g -Os -D__KERNEL__ -DCONFIG_SYS_TEXT_BASE=0x80100000 -I/home/xiangfu/workspace/PanGu/u-boot.upstream/include -fno-builtin -ffreestanding -nostdinc -isystem /home/xiangfu/workspace/PanGu/openwrt-xburst/staging_dir/toolchain-mipsel_gcc-4.3.3+cs_uClibc-0.9.30.1/usr/lib/gcc/mipsel-openwrt-linux-uclibc/4.3.3/include -pipe -DCONFIG_MIPS -D__MIPS__ -G 0 -mabicalls -fpic -msoft-float -march=4kc -mtune=4kc -mabicalls -mips32 -Wall -Wstrict-prototypes -fno-stack-protector -DCONFIG_NAND_SPL -Os -c -o jz4740_nand.o jz4740_nand.c
jz4740_nand.c: In function 'board_nand_init':
jz4740_nand.c:298: warning: implicit declaration of function 'usb_boot'
cd /home/xiangfu/workspace/PanGu/u-boot.upstream/nand_spl/board/xburst/nanonote && mipsel-openwrt-linux-ld -Bstatic -T /home/xiangfu/workspace/PanGu/u-boot.upstream/nand_spl/board/xburst/nanonote/u-boot.lds -Ttext 0x80000000 $UNDEF_SYM start.o usbboot.o nand_boot.o cpu.o jz4740.o jz_serial.o jz4740_nand.o \
-Map /home/xiangfu/workspace/PanGu/u-boot.upstream/nand_spl/u-boot-spl.map \
-o /home/xiangfu/workspace/PanGu/u-boot.upstream/nand_spl/u-boot-spl
jz4740.o: In function `sdram_init':
jz4740.c:(.text+0x60): undefined reference to `memcpy'
~~~
>> +$(nandobj)u-boot-spl-16k.bin: $(nandobj)u-boot-spl.bin
>> + dd bs=1024 count=8 if=/dev/zero of=$(nandobj)junk1
>> + cat $< $(nandobj)junk1 > $(nandobj)junk2
>> + dd bs=1024 count=8 if=$(nandobj)junk2 of=$(nandobj)junk3
>> + cat $(nandobj)junk3 $(nandobj)junk3 > $(nandobj)junk4
>> + dd bs=1024 count=256 if=/dev/zero of=$(nandobj)junk5
>> + cat $(nandobj)junk4 $(nandobj)junk5 > $(nandobj)junk6
>> + dd bs=1024 count=256 if=$(nandobj)junk6 of=$@
>> + rm -f $(nandobj)junk*
>
> Again, please explain what's going on here. Other boards don't do this.
>
add comments in "Makefile" in next patches.
- --
Best Regards
Xiangfu Liu
http://www.openmobilefree.net
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAk0p2LEACgkQRRAEFRxkgLSVCwCeIQ3AC86hiUy98sBLoG8Zq1EE
WP8An3a8aIyzzwDJ46I/wBNytwGyJTyK
=YvtK
-----END PGP SIGNATURE-----
next prev parent reply other threads:[~2011-01-09 15:48 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-12-06 11:53 [U-Boot] [PATCH v3 0/5] new cpu, ingenic xburst jz4740 xiangfu at openmobilefree.net
2010-12-06 11:53 ` [U-Boot] [PATCH v3 1/5] those files are jz4740 base files xiangfu at openmobilefree.net
2010-12-06 11:53 ` [U-Boot] [PATCH v3 2/5] this is jz4740 head file xiangfu at openmobilefree.net
2010-12-06 11:53 ` [U-Boot] [PATCH v3 3/5] jz4740 nand spl files xiangfu at openmobilefree.net
2010-12-06 11:53 ` [U-Boot] [PATCH v3 4/5] jz4740 nand driver xiangfu at openmobilefree.net
2010-12-06 11:53 ` [U-Boot] [PATCH v3 5/5] add Ben NanoNote board xiangfu at openmobilefree.net
2010-12-14 0:05 ` [U-Boot] [PATCH v3 3/5] jz4740 nand spl files Scott Wood
2011-01-09 15:48 ` Xiangfu Liu [this message]
2011-01-10 18:43 ` Scott Wood
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=4D29D8B1.2090605@openmobilefree.net \
--to=xiangfu@openmobilefree.net \
--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