
I know this is a rather long email, but I want to give all the details. Bear with me :-).
I was under the impression that the CFI patch was already included in the f188896c... commit and that I didn't need to apply it. I had tried the git-rebase, but it gave me errors and then wouldn't build. I assumed that the git-rebase step was only required for future patches, so figured I would sort it out later. I should have mentioned that in my last email, I apologize for the miscommunication.
Here's the git-rebase output:
david@chiron:~/u-boot-coldfire$ git-rebase master patched Already on branch "patched" First, rewinding head to replay your work on top of it...
HEAD is now at 33dac03... Coding Style Cleanup; update CHANGELOG
Applying ColdFire: Added MCF5275 cpu support.
Wrote tree ab2c1c1174d5a83b77fb13ef256dea1ad52bfc76 Committed: 70fb3f277a4032eb9d94e840247a9912de4678be
Applying ColdFire: Added M5275EVB support.
error: patch failed: MAKEALL:648 error: MAKEALL: patch does not apply Using index info to reconstruct a base tree... Falling back to patching base and 3-way merge... Auto-merged MAKEALL Auto-merged Makefile Wrote tree de37f7363a7d043338a21751cbedfbc1cff75ab8 Committed: dcba0b1aea040e60724b6fabd273f3ce42efa36f
Resulting in these build errors:
make[1]: Leaving directory `/home/david/u-boot/drivers/pcmcia' make -C drivers/spi/ make[1]: Entering directory `/home/david/u-boot/drivers/spi' mpc8xxx_spi.c:26:29: error: asm/mpc8xxx_spi.h: No such file or directory make[1]: *** No rule to make target `.depend', needed by `libspi.a'. Stop. make[1]: Leaving directory `/home/david/u-boot/drivers/spi' make: *** [drivers/spi/libspi.a] Error 2
I have applied the CFI patch from the original email using git-am, that seems to work fine. U-boot compiles successfully with these warnings:
david@chiron:~/u-boot$ ./MAKEALL M5275EVB Configuring for M5275EVB board... board.c: In function 'init_baudrate': board.c:179: warning: pointer targets in passing argument 2 of 'getenv_r' differ in signedness board.c:182: warning: pointer targets in passing argument 1 of 'simple_strtoul' differ in signedness m68k_linux.c: In function 'do_bootm_linux': m68k_linux.c:154: warning: implicit declaration of function 'do_reset' m68k-elf-ld: warning: library search path "/lib" is unsafe for cross-compilation m68k-elf-ld: warning: library search path "/usr/lib" is unsafe for cross-compilation m68k-elf-ld: warning: library search path "/usr/local/lib" is unsafe for cross-compilation ./MAKEALL: 265: ppc_8xx-size: not found
I programmed the board (an M5275EVB Rev. B) with the srec using CF Flasher, and U-Boot boots to the prompt.
However, I've run into these problems, and I'm wondering if guys have as well, or if I'm doing something wrong.
1) I can't save environment variables using saveenv. I can change them just fine, and saveenv runs as usual, but on reset, I get a "*** Warning - bad CRC, using default environment "
example:
-> printenv
bootcmd=bootm ffe40000 bootdelay=5
baudrate=19200
ethaddr=00:06:3b:01:41:55
eth1addr=00:0e:0c:bc:e5:60
stdin=serial
stdout=serial
stderr=serial
ethact=FEC0
Environment size: 156/8188 bytes -> setenv ipaddr 192.168.1.101
-> printenv
bootcmd=bootm ffe40000 bootdelay=5
baudrate=19200
ethaddr=00:06:3b:01:41:55
eth1addr=00:0e:0c:bc:e5:60
stdin=serial
stdout=serial
stderr=serial
ethact=FEC0
ipaddr=192.168.1.101
Environment size: 177/8188 bytes -> saveenv
Saving Environment to Flash... Un-Protected 1 sectors Erasing Flash... . done
Erased 1 sectors Writing to Flash... done Protected 1 sectors ->
U-Boot 1.3.1-ge4d87286 (Jan 26 2008 - 13:23:51)
CPU: Freescale Coldfire MCF5275 at 150 MHz Board: Freescale MCF5275 EVB I2C: ready DRAM: 16 MB FLASH: 2 MB *** Warning - bad CRC, using default environment
etc.
2) Ethernet does not seem to work. After setting the ipaddr, serverip, and netmask variables, I run tftpboot and don't get anything but checksum errors. The TFTP transfer works fine with the exact same setup (router, ip addresses, etc.) when I use dBug. I've run Wireshark on the ethernet interface and haven't seen a single packet from the board while running the tftpboot command. I've tried pinging the board, seen the packets sent on Wireshark, and got no response.
-> printenv
bootcmd=bootm ffe40000 bootdelay=5
baudrate=19200
ethaddr=00:06:3b:01:41:55
eth1addr=00:0e:0c:bc:e5:60
stdin=serial
stdout=serial
stderr=serial
ethact=FEC0
ipaddr=192.168.1.101
serverip=192.168.1.100
netmask=255.255.255.0
Environment size: 222/8188 bytes -> tftpboot 0x50000 image.bin
Using FEC0 device TFTP from server 192.168.1.100; our IP address is 192.168.1.101
Filename 'image.bin'.
Load address: 0x50000 Loading: checksum bad checksum bad checksum bad
Abort
->
Anything to clear this up would help. Do either of you have ethernet and saveenv working? Thanks for your help and your patience.
-David