From: Manuel Sahm <Manuel.Sahm@feig.de>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] make env
Date: Tue, 25 Mar 2008 17:19:17 +0100 [thread overview]
Message-ID: <47E92605.2080808@feig.de> (raw)
In-Reply-To: <87fxufc4cx.fsf@denx.de>
Hello,
but why is there a error concerning NAND flashs if only NOR flashs are
supported ?
"nand_write: attempting to write not page aligned data"
Thank you
Manuel Sahm
Markus Klotzb?cher schrieb:
> Hi Manuel,
>
> Manuel Sahm <Manuel.Sahm@feig.de> writes:
>
>
>> I took the U-Boot version 1.3.2; now I am able to generate the make env
>> -> fw_printenv utility.
>>
>> I copy the jw_printenv binary and rename it to fw_setenv.
>>
>
> A (hard) link would be enough.
>
>
>> I use the config file in the /etc directory.
>> I want to access a NAND flash. [Pagesize = 0x800; ERASEBLOCKSIZE=0x20000]
>> My uboot is in mtd1.
>> mtd1 is from 0x20000 ... 0x100000 in my NAND-Flash
>> The Uboot enviroment is from 0x60000...0x80000; the redundant from
>> 0x80000...0x100000
>>
>> My fw_config file is:
>>
>> /dev/mtd1 0x40000 0x20000 0x20000
>> /dev/mtd1 0x60000 0x20000 0x20000
>>
>> Is this correct ?
>>
>
> Looks OK to me.
>
>
>> I am able tu use fw_printenv, the variables are printed on the console
>> If I use fw_setenv I get errors:
>>
>> fw_setenv test 1
>>
>> Unlocking Flash
>> Done
>> nand_write: attempting to write not page aligned data
>> Erasing old enviroment
>> Done
>> Writing enviroment to /dev/mtd1: Invalid argument
>> Error: can?t write fw_env to flash
>>
>> What?s wrong ????
>>
>
> I think the problem is that the fw_setenv so far only supports NOR
> flash. Environment in NAND is implemented slightly different, especially
> it doesn't (and can't) invalidate the former valid environment after the
> updated one was written successfully. So I'm afraid you will have to
> update this tool to support NAND.
>
> Best regards
>
> Markus Klotzbuecher
>
> --
> DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
> HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
> Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
>
next prev parent reply other threads:[~2008-03-25 16:19 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-20 15:57 [U-Boot-Users] make env Manuel Sahm
2008-03-20 16:04 ` Wolfgang Denk
2008-03-20 17:56 ` Ladislav Michl
2008-03-20 20:02 ` Wolfgang Denk
2008-03-20 20:11 ` Ladislav Michl
2008-03-20 21:27 ` Wolfgang Denk
2008-03-20 21:33 ` Ladislav Michl
2008-03-25 12:56 ` Manuel Sahm
2008-03-25 13:36 ` Markus Klotzbücher
2008-03-25 16:19 ` Manuel Sahm [this message]
2008-03-25 17:04 ` Markus Klotzbücher
2008-03-25 20:11 ` Wolfgang Denk
2008-04-02 9:31 ` Manuel Sahm
2008-04-02 10:39 ` Wolfgang Denk
2008-04-02 11:18 ` Manuel Sahm
2008-04-02 14:33 ` Wolfgang Denk
2008-04-06 17:37 ` Markus Klotzbücher
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=47E92605.2080808@feig.de \
--to=manuel.sahm@feig.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.