[U-Boot] Getting started with uboot

Thomas Heller theller at ctypes.org
Wed Aug 4 22:08:14 CEST 2010


Wolfgang Denk schrieb:
> Dear Thomas Heller,
> 
> In message <i3ccjf$a05$1 at dough.gmane.org> you wrote:
>> Where does uboot store the environment variables?
>> 
>> I have my tx25 board booting correctly from uboot when
>> entering interactive commands:
> 
> Check the board config file:
> 
> include/configs/tx25.h:
>  33
>  34 #define CONFIG_SYS_MONITOR_LEN          (256 << 10)     /* 256 kB for U-Boot */
>  35
> ...
> 
> 102 #define CONFIG_ENV_IS_IN_NAND
> 103 #define CONFIG_ENV_OFFSET       CONFIG_SYS_MONITOR_LEN
> 104 #define CONFIG_ENV_SIZE         (128 * 1024)    /* 128 kB NAND block size */
> 105 #define CONFIG_ENV_OFFSET_REDUND        (CONFIG_ENV_OFFSET + CONFIG_ENV_SIZE)
> 
> 
>> > => nand read 0x80108000 0x02040000 0x00260000
>> > 
>> > NAND read: device 0 offset 0x2040000, size 0x260000
>> >  2490368 bytes read: OK
> 
> 0x02040000 is more than 32 MiB, i. e. far, far away from the
> envrionment.

Yes, but this is the kernel partition.  The rootfs starts at a lower address.
And actually this is the problem: I put uboot into the RedBoot flash
partition, which is only 0x40000 in size (256 kB), but uboot apparently
needs much more.

Which raises the question: why is the environment so large?  Wouldn't a
few kB be enough (4kB, 16kB for example)?

Thanks, also to Elie, for the quick answers.  I'll get it to work now.

Thomas



More information about the U-Boot mailing list