AnsweredAssumed Answered

uboot-envtools on imx.6 issues

Question asked by Dennis Johansson on Jul 30, 2013
Latest reply on Feb 20, 2014 by Eric Nelson
Branched to a new discussion

Hi!

I try to manipulate the u-boot env-var from linux and trying to use uboot-envtools but I cant get it to work.

I have been looking at the sourcecode config in u-boot (mx6_iwg15m_q7.h), and it gives me the offset and the env size.

 

#define CONFIG_ENV_SECT_SIZE(8 * 1024)
#define CONFIG_ENV_SIZE     CONFIG_ENV_SECT_SIZE

 

#if defined(CONFIG_FSL_ENV_IN_MMC)

    #define CONFIG_ENV_IS_IN_MMC1
    #define CONFIG_ENV_OFFSET   (768 * 1024)

 

cat /proc/mtd gives me:

dev:size   erasesize  name

mtd0: 00010000 00008000 "bootloader"

 

I define my fw_env.config

/dev/mtd0   0xc0000 0x2000  0x2000

 

When i try to read the env. variables i get a crc error.

 

fw_printenv

Warning: Bad CRC, using default environment

bootcmd=bootp; setenv bootargs root=/dev/nfs nfsroot=${serverip}:${rootpath} ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}::off; bootm

bootdelay=5

baudrate=115200

 

I cant understand why it does not work

Any tip are welcome!

Thanks

 

/Dennis

Outcomes