Skip to content

avr32 fixes

Bas Mevissen u-boot 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest0 of 3 patches 0 repliesNew

Patches in v1 No applies recorded yet

None of the 3 patches the cover letter announces are in this archive.

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [U-Boot] [PATCH 0/3] avr32 fixes
Quoted 11 lines · Bas Mevissen
Quoted 6 lines

Ok, I wasn't aware of that problem. I don't think I've ever tried running u-boot with empty environment; in fact, I'm not even sure how you do that since it will fall back to a default environment if it can't find anything in flash.

Yes, the strange thing is that it worked fine a few times. But for some reason, it failed later on.
I'll try to reproduce the problem and make a proper report.

Here it is, pasted as quotation to avoid line wrapping:

Quoted 23 lines

U-Boot 2008.10 (Aug 1 2010 - 01:34:48)

U-Boot code: 00000000 -> 00012f66 data: 000198e8 -> 0004f4e0
malloc: Using memory from 0x11f70000 to 0x11fb0000
DMA: Using memory from 0x11f6c000 to 0x11f70000
Flash: 3.2 GB at address 0x00000000
DRAM Configuration:
Bank #0: 10000000 32 MB
WARNING: Cannot allocate space for boot parameters *** Warning - bad CRC, using default environment

*** Unhandled exception 5 at PC=0xffffffff
MMU exception at address 0xffffffff

   pc: ffffffff    lr: 11fb7ff0    sp: 11f6bf3c   r12: ffffffff                 
  r11: 00041a67   r10: 00041a67    r9: 00000002    r8: 00000001                 
   r7: 00041a67    r6: 11fca850    r5: 11f6bfa0    r4: 00000001                 
   r3: 00041a67    r2: 00041a67    r1: 0001a85c    r0: 0001a858                 

Flags: qvNzc
Mode bits: hrje....g
CPU Mode: Supervisor

Quoted 7 lines
Stack: (0x11f6bf3c to 0x11f6bfa0)                                               

bf20: 11fb819e
bf40: 11f6bfcc 11fca850 11f6bfa0 11fcf2a0 11fb0762 11f6bfcc 11fca850 11f6bfa0
bf60: 11fcf2a0 11f6bfcc 0001a860 0001a85c 0001a858 11fb0182 02000000 11fca850
bf80: 24007fb4 11fcf2a0 68616e64 11fb0000 00000000 11fb0000 00000000 00000000 Unhandled exception

I don't know how u-boot knows the flash layout. Maybe something changed between 1.3.3 and 2008.10 (default partition table?)

I compiled pristine 2008.10 for atngw100 with just LZMA compression enabled and the right command line and boot command for OpenWRT:

Quoted 12 lines
include/configs/atngw100.h renamed from include/configs/atngw100.h.orig +1 -0
@@ -62,6 +62,7 @@
 
 /* User serviceable stuff */
 #define CONFIG_DOS_PARTITION		1
+#define CONFIG_LZMA			1
 
 #define CONFIG_CMDLINE_TAG		1
 #define CONFIG_SETUP_MEMORY_TAGS	1
@@ -71,9 +72,9 @@
 

include/configs/atngw100.h line 80

Quoted 10 lines
include/configs/atngw100.h renamed from include/configs/atngw100.h.orig +2 -2
 #define CONFIG_BAUDRATE			115200
 #define CONFIG_BOOTARGS							\
-	"console=ttyS0 root=/dev/mtdblock1 rootfstype=jffs2"
+	"console=ttyS0i,115200 root=/dev/mtdblock2 rootfstype=jffs2 init=/etc/preinit"
 #define CONFIG_BOOTCOMMAND						\
-	"fsload; bootm"
+	"bootm 0x20000"
 
 /*
  * Only interrupt autoboot if <space> is pressed. Otherwise, garbage

(make atngw100_config && make)

This is what 1.3.3 does. I just took the plain image from OpenWRT and not the one padded to 128K bytes as usual with OpenWRT. For 1.3.3, that does not seem to make a difference.

OpenWRT only adds LZMA decompression support to the pristine sources.

Quoted 12 lines

U-Boot 1.3.3 (Aug 1 2010 - 03:05:20)

U-Boot code: 00000000 -> 00011600 data: 00017b20 -> 0004e408
SDRAM: 32 MB at address 0x10000000
Testing SDRAM...OK
malloc: Using memory from 0x11f71000 to 0x11fb1000
DMA: Using memory from 0x11f6d000 to 0x11f71000
Flash: 8 MB at address 0x00000000
DRAM Configuration:
Bank #0: 10000000 32 MB
*** Warning - bad CRC, using default environment

Quoted 9 lines
In:    serial
Out:   serial
Err:   serial
Net:   macb0, macb1

Press SPACE to abort autoboot in 1 seconds
Wrong Image Format for bootm command
ERROR: can't get kernel image!
Uboot>

You notice that the flash size is correctly recognized. I fully erased the flash between both attempts and there was no power cycle in between. Actually, I'm not even physically touching the board.

Signature · 1 line
Bas.