From: Wolfgang Denk Date: Thu, 18 Nov 2010 00:05:06 +0100 Subject: [U-Boot] fw_setenv broken? In-Reply-To: <1290034139.2927.1192.camel@quadra> References: <1290011424.2927.1123.camel@quadra> <4CE4092B.7090209@denx.de> <20101117173933.665FE14EA7E@gemini.denx.de> <20101117204722.E34FC14EA7E@gemini.denx.de> <20101117214049.52CA614EA7E@gemini.denx.de> <20101117160802.5bacf545@udp111988uds.am.freescale.net> <1290034139.2927.1192.camel@quadra> Message-ID: <20101117230506.83B5B14E646@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Steve Sakoman, In message <1290034139.2927.1192.camel@quadra> you wrote: > > I patched readenv to use the same nand_read_skip_bad function used in > the command line "nand read" tool. I no longer get the -EUCLEAN errors > when reading the environment after using fw_setenv to write from linux. > Now I get: > > *** Warning - bad CRC, using default environment > > Checking the data with the "nand read" command line shows that the > changes I made in linux are indeed there, so I suspect that there is > also some mismatch in the CRC computation between the fw tools and the > u-boot code (i.e. I'm pretty sure this error does *not* refer to the > nand CRC) Try and use the "crc32" command in U-Boot tocheck if the checksum is correct. Check if the environment size in your board config file and in the fw_env.conf file match. Check if both match wether or not redundant env is used. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de The amount of time between slipping on the peel and landing on the pavement is precisely 1 bananosecond.