From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wolfgang Denk Date: Sat, 22 Dec 2012 00:09:36 +0100 Subject: [U-Boot] where is the crc stored? In-Reply-To: <1356125251.28896.119.camel@genx> References: <1356114777.28896.92.camel@genx> <20121221195421.3D449200FB7@gemini.denx.de> <1356125251.28896.119.camel@genx> Message-ID: <20121221230936.F245C201213@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 John Stile, In message <1356125251.28896.119.camel@genx> you wrote: > > I am a total new-bee, but I have read there is a crc check in u-boot. Actually there are several such checks, for several different purposes. > The crc check can result in a: > Warning: Bad CRC, using default environment THis is when checking if there is a valid environment. So we are talkign about the CRC which protects the persistent environment copy. The structure of this is defined in "include/environment.h", see struct environment_s - as you can see, this is a CRC32. > The crc is considered during the bootcmd. No, this has absolutely nothing to do with bootcmd. > I would like to know where this crc is stored. In the first 4 bytes of the external representation of the environment. > I would like to know is it 8-bit, 16-bit, and 32-bit, or other. 32 bit. 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 ultimate barrier is one's viewpoint. - Terry Pratchett, _The Dark Side of the Sun_