From: Stefan Roese <sr@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] CFI driver problems on MPC8260 and 440EPx systems
Date: Thu, 27 Dec 2007 07:55:40 +0100 [thread overview]
Message-ID: <200712270755.40671.sr@denx.de> (raw)
In-Reply-To: <20071226230925.E9A6D24889@gemini.denx.de>
Hi Wolfgang,
On Thursday 27 December 2007, Wolfgang Denk wrote:
> even after pulling the latest CFI updates from the u-boot-cfi-flash
> repository, I still see the following issues:
>
> a) on MPC8260:
>
> [Stefan: for testing please use the TQM8260_AD board in the xpert VL.]
>
> The CFI driver returns from an "erase" operation with the flash still
> in a undefined state; immediate reads after an erase do not show 0xFF
> patterns. If you wait a few milliseconds, the flash will finally
> change into the expected erased state.
>
> Example:
>
> => era 40280000 +1 ; md 40280000 10 ; sleep 1 ; md 40280000
>
> . done
> Erased 1 sectors
> 40280000: 004c004c 00080008 004c004c 00080008 .L.L.....L.L.... <= bad
> 40280010: 004c004c 00080008 004c004c 00080008 .L.L.....L.L.... <= bad
> 40280020: 004c004c 00080008 004c004c 00080008 .L.L.....L.L.... <= bad
> 40280030: 004c004c 00080008 004c004c 00080008 .L.L.....L.L.... <= bad
> 40280000: ffffffff ffffffff ffffffff ffffffff ................ <- good
> 40280010: ffffffff ffffffff ffffffff ffffffff ................ <- good
> 40280020: ffffffff ffffffff ffffffff ffffffff ................ <- good
> 40280030: ffffffff ffffffff ffffffff ffffffff ................ <- good
>
> Playing with CFI paramaters (like manually increasing write timeout
> and/or erase timeout) does not change anything. Neither does adding
> sync() instructions to the flash_read?() and flash_write?()
> functions.
Unfortunately I have no clue right now what could be causing this. I'll try to
dig into it when I find a little time for it.
> b) on 440EPx:
>
> [Stefan: for testing please use the Sequoia board in the pollux VL.]
>
> The CFI driver does not detect that it's writing to flash that is not
> (sufficiently) erased:
>
> => md FC000000 10
> fc000000: 00000000 00000000 00000000 00000000 ................
> fc000010: 00000000 00000000 00000000 00000000 ................
> fc000020: 00000000 00000000 00000000 00000000 ................
> fc000030: 00000000 00000000 00000000 00000000 ................
> => mw.b 0 FF 400
> => md 0
> 00000000: ffffffff ffffffff ffffffff ffffffff ................
> 00000010: ffffffff ffffffff ffffffff ffffffff ................
> 00000020: ffffffff ffffffff ffffffff ffffffff ................
> 00000030: ffffffff ffffffff ffffffff ffffffff ................
> => cp.b 0 FC000000 400
> Copy to Flash... done <= should issue error message here!!!!
> => md FC000000
> fc000000: 00000000 00000000 00000000 00000000 ................
> fc000010: 00000000 00000000 00000000 00000000 ................
> fc000020: 00000000 00000000 00000000 00000000 ................
> fc000030: 00000000 00000000 00000000 00000000 ................
> =>
>
> I consider this a major bug.
Yes, me too.
A quick look at the code shows, that the check for a (sufficiently) erased
destination is totally missing from the buffered write version (enabled via
the CFG_FLASH_USE_BUFFER_WRITE define). I'll send a patch in a minute that
fixes this problem. Tested on Sequoia.
Best regards,
Stefan
=====================================================================
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:[~2007-12-27 6:55 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-26 23:09 [U-Boot-Users] CFI driver problems on MPC8260 and 440EPx systems Wolfgang Denk
2007-12-26 23:42 ` Haavard Skinnemoen
2007-12-26 23:49 ` Wolfgang Denk
2007-12-27 6:55 ` Stefan Roese [this message]
2008-01-02 10:52 ` [U-Boot-Users] CFI: flash accessor functions used for source read too Stefan Roese
2008-01-04 14:42 ` Haavard Skinnemoen
2008-01-09 11:22 ` 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=200712270755.40671.sr@denx.de \
--to=sr@denx.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox