[U-Boot-Users] still got "*** Warning - bad CRC, using default environment" after saveenv is sucessfully done

NZG ngustavson at emacinc.com
Mon May 2 17:02:46 CEST 2005


I was having this same problem, and it turned out I was writing the 
enviornment over the top of some of my u-boot code.

I'd make sure CFG_ENV_OFFSET is set to an empty area.

NZG.
On Monday 02 May 2005 02:21, Wayne Lee wrote:
> Hi, u-boot users,
>
> I have written hardware-dependent flash functions for my EVB u-boot
> support. Hence, "saveenv" works and I can see the env data in the
> configured env sector by "md" command.
>
> However, I still get the warning messages, "*** Warning - bad CRC, using
> default environment", after press reset button.
>
> Should any CONFIG/CFG need to be added in board configuration file?
>
> I use u-boot 1.1.2 and the followings are part of board configurations.
>
> /*-----------------------------------------------------------------------
>  * Physical Memory Map
>  */
> #define CONFIG_NR_DRAM_BANKS	1	   /* we have 1 bank of DRAM */
> #define PHYS_SDRAM_1		0x00000000 /* SDRAM Bank #1 */
> #define PHYS_SDRAM_1_SIZE	0x04000000 /* 64 MB */
> #define PHYS_FLASH_1		0xFF800000 /* Flash Bank #1 */
> #define CFG_FLASH_BASE		PHYS_FLASH_1
>
> /*-----------------------------------------------------------------------
>  * FLASH and environment organization
>  */
> #define CFG_MAX_FLASH_BANKS	1	/* max number of memory banks */
> #define PHYS_FLASH_SIZE	0x00400000	/* 4MB */
> #define CFG_MAX_FLASH_SECT	(71)	/* max number of sectors on one chip
> */
> /* addr of environment */
> #define CFG_FLASH_CFI				/* The flash is CFI
> compatible  */
>
> #define CFG_ENV_IS_IN_FLASH	1
> #define CFG_ENV_SIZE		0x2000	/* Total Size of Environment Sector
> */
> #define CFG_ENV_SECT_SIZE	0x2000
> #define CFG_ENV_OFFSET		0x3F8000	/* environment starts here
> */
> #define CFG_ENV_ADDR		(CFG_FLASH_BASE + CFG_ENV_OFFSET)
>
> Thanks.
> Wayne
>
>
>
>
>
>
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by: NEC IT Guy Games.
> Get your fingers limbered up and give it your best shot. 4 great events, 4
> opportunities to win big! Highest score wins.NEC IT Guy Games. Play to
> win an NEC 61 plasma display. Visit http://www.necitguy.com/?r=20
> _______________________________________________
> U-Boot-Users mailing list
> U-Boot-Users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/u-boot-users




More information about the U-Boot mailing list