public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: Stuart Menefy <Stuart.Menefy@st.com>
To: linux-mtd@lists.infradead.org
Subject: CFI vs JEDEC read commands
Date: Mon, 11 Jun 2001 18:11:31 +0100	[thread overview]
Message-ID: <1010611181131.ZM26024@bristol.st.com> (raw)

Folks

In adding support for ST M29W160DT I've come across what looks like
a bug in the chip, but but which has exposed what looks like an
inconsistency in the probing in MTD.

The board I'm working on has two banks of Flash mapped into contiguous
addresses, and I was seeing problems when probing for the second bank
of Flash. The problem is that the first bank is being left in command
mode after the probe, and so the second bank is detected as an alias
for the first.

In cfi_cfi_probe() there is a call to cfi_send_cmd(0xff, ...) which I
assume is supposed to reset the device back to read mode to avoid this
problem. However the ST chip uses 0xf0 as its reset code, and changing
the 0xff to 0xf0 appears to fix the problem. 

All the documentation I've been able to check, for both CFI and JEDEC
devices, including the ST M29W160DT indicates that an unrecognised
command should put the device back into read mode. Unfortunately the ST
chip doesn't appear to be doing this, which I assume is a bug.

Has anybody else come across a problem like this?

However, this got me looking at the code. In virtually every case, a
'read' command is 0xf0, apart from two (one in cfi_cfi_probe and
the other in cfi_cmdset_unknown), when is it 0xff. Is this
deliberate, and would changing the remaining two to 0xf0 cause any
problems?

Many thanks

Stuart

             reply	other threads:[~2001-06-12  7:47 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-06-11 17:11 Stuart Menefy [this message]
2001-06-12  8:51 ` CFI vs JEDEC read commands David Woodhouse

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=1010611181131.ZM26024@bristol.st.com \
    --to=stuart.menefy@st.com \
    --cc=linux-mtd@lists.infradead.org \
    /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