]> git.kernelconcepts.de Git - karo-tx-uboot.git/commit
hwconfig: Utilize getenv_f before relocation to allow for larger buffer
authorKumar Gala <galak@kernel.crashing.org>
Fri, 22 Oct 2010 08:18:13 +0000 (03:18 -0500)
committerWolfgang Denk <wd@denx.de>
Sat, 23 Oct 2010 20:10:54 +0000 (22:10 +0200)
commitc4b115f536b0cb41b0d863ab00fe52d7772433a0
treeadd5d84b93ed44959f093bfa6b1bf39dd89e1924
parent3f7ffa440a60d5b37d1eabbee1b4c2af60eb104b
hwconfig: Utilize getenv_f before relocation to allow for larger buffer

Since we use hwconfig in cases before relocation (like getting DDR
params on FSL PPC systems), we can have strings that exceed the early
small (32 byte) buffer size that getenv will handle.

So we explicitly allocate our own buffer on the stack and use if to
handle getting the hwconfig env string.  We currently utilize a string
length of 128 bytes.

This allows us to get rid of boot messages like:

env_buf too small [32]

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
common/hwconfig.c