From: u-boot user <aparna_badve@yahoo.com>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] problems with CRC in fw_printenv and fw_setenv utility and use
Date: Fri, 11 Jan 2008 16:09:18 -0800 (PST) [thread overview]
Message-ID: <14767876.post@talk.nabble.com> (raw)
Hello all,
I have built the binary fw_printenv by using mtd-user.h from mtd-utils on
the internet as it fw_printenv won't compile it without using that file. So
I have used mtd-user.h and mtd-abi.h. The contents of my configuration file
are
# MTD device name Device offset Env. size Flash sector size
/dev/mtd1 0x0000 0x4000 0x4000
When I run fw_printenv it complained with error Warning : Bad CRC using
default environment in env_init function in fw_env.c source code. To gain a
better understanding I print the value crc1 calculated using
crc32(0,environment.data,ENV_SIZE). The value it prints is CRC
computed:FE641197
If I print the environment.crc value it is D0CA8A0E. As the checksum values
are different crc1_ok is not set and I get the error. Any clue as to why
these values would be different?
When I use the fw_setenv utility to set an environment variable it gives the
following errors
Writing CRC value to flash: D0C78567
Unlocking flash...
Other dev values are: 0
Current dev value: 0
Done
Erasing old environment...
MTD erase error on /dev/mtd1: Invalid argument
Error: can't write fw_env to flash
I want to be able to set bootvars and print bootvars from user space Linux
code. Linux has support for mtd-utils we tested the mtd-utils interface.
I look forward to your replies. I appreciate your help.
Thanks and Regards
--
View this message in context: http://www.nabble.com/problems-with-CRC-in-fw_printenv-and-fw_setenv-utility-and-use-tp14767876p14767876.html
Sent from the Uboot - Users mailing list archive at Nabble.com.
next reply other threads:[~2008-01-12 0:09 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-01-12 0:09 u-boot user [this message]
2008-01-14 8:00 ` [U-Boot-Users] problems with CRC in fw_printenv and fw_setenv utility and use Markus Klotzbücher
2008-02-15 16:32 ` techie_vasu
2008-02-15 17:19 ` Markus Klotzbücher
2008-02-15 16:33 ` techie_vasu
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=14767876.post@talk.nabble.com \
--to=aparna_badve@yahoo.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox