public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: ghannon@cspi.com
To: alfred hitch <alfred.hitch@gmail.com>
Cc: linux-mtd@lists.infradead.org, Peter Wippich <pewi@gw-instruments.de>
Subject: Re: sector locks handling for J3 flashes?
Date: Wed, 11 Jan 2006 18:36:50 -0000	[thread overview]
Message-ID: <852570F3.00522FB1.00@pine.cspi.com> (raw)


On Wed, 11 Jan 2006, alfred hitch wrote:

> I am actually surprised that noone is running his / her boards with
> flash sectors locked ?

> I am new to embedded designs, but wont this be a pretty standard /
> accepted practice to lock your flash sectors ?

We are also using that same part and we were having some flash
corruption at reboot, although I think it was due to an
error in the reset timing on the board.

I keep the flash locked at all times except to reflash our firmware.
The locking and unlocking is all handled  by a userspace tool
we wrote up and the reflashing script takes care of doing the
unlock/lock around the programming step.

I could send you the code if you would like.

Also, one thing about the J3 part is that any "unlock" of
a block unlocks the whole flash, and a lock only locks one block.
The linux mtd drivers do not take this into consideration.
Although I think the lazy unlock mentioned would not have a
problem with it, it would just never find anything locked once
it unlocked the first block.

The rev D of J3 allows you to make certain sectors permanently locked,
so that an unlock of one area will not unlock sectors that are
setup to not allow unlocking.   Be careful though, or your can turn your
flash into rom very easily if you have no way of stopping the code
before it sets up these bits.

Gary Hannon

             reply	other threads:[~2006-01-11 18:36 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-01-11 18:36 ghannon [this message]
2006-01-12  6:18 ` sector locks handling for J3 flashes? alfred hitch
2006-01-12  7:26   ` alfred hitch
2006-01-12 11:09     ` alfred hitch
  -- strict thread matches above, loose matches on Subject: below --
2006-01-11  5:54 alfred hitch
2006-01-11 10:11 ` Peter Wippich
2006-01-11 10:41   ` alfred hitch
2006-01-13  7:40   ` alfred hitch

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=852570F3.00522FB1.00@pine.cspi.com \
    --to=ghannon@cspi.com \
    --cc=alfred.hitch@gmail.com \
    --cc=linux-mtd@lists.infradead.org \
    --cc=pewi@gw-instruments.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