From: Steven Scholz <steven.scholz@imc-berlin.de>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] Verify CRC on environment?
Date: Wed, 25 May 2005 11:01:14 +0200 [thread overview]
Message-ID: <42943EDA.7020404@imc-berlin.de> (raw)
Hi,
(how) can I verify the CRC of the environment using the crc32 command?
I am using CFG_ENV_ADDR_REDUND, so I guess I have to skip 5 bytes of header.
Do the two last 0x00 count?
My environment is at 10030000:
10030000: 4c 16 71 5f 00 62 6f 6f 74 64 65 6c 61 79 3d 30
10030010: 00 62 61 75 64 72 61 74 65 3d 31 31 35 32 30 30
10030020: 00 73 65 72 69 61 6c 23 3d 31 32 38 33 30 30 00
10030030: 73 74 64 69 6e 3d 73 65 72 69 61 6c 00 73 74 64
10030040: 6f 75 74 3d 73 65 72 69 61 6c 00 73 74 64 65 72
10030050: 72 3d 73 65 72 69 61 6c 00 00 3d 73 65 72 69 61
10030060: 6c 00 00 64 65 72 72 3d 73 65 72 69 61 6c 00 00
10030070: 74 64 65 72 72 3d 73 65 72 69 61 6c 00 00
That 0x7D, so 125+1 = 126 bytes
So I thought I have to calculate the crc over 126 - 5 = 0x79 bytes
crc32 10030005 0x79
CRC32 for 10030005 ... 1003007d ==> 8889f3af
But this is obviously wrong... :-(
--
Steven Scholz
next reply other threads:[~2005-05-25 9:01 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-25 9:01 Steven Scholz [this message]
2005-05-25 9:12 ` [U-Boot-Users] Verify CRC on environment? Wolfgang Denk
2005-05-25 9:14 ` Steven Scholz
2005-05-25 9:32 ` Wolfgang Denk
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=42943EDA.7020404@imc-berlin.de \
--to=steven.scholz@imc-berlin.de \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.