Minor fixes to NAND code and docs
Erase logic:
- command invocation
+ treat "nand erase N" (no offset/length) as "erase whole chip N"
+ catch a few more bogus parameter cases, like length == 0 (sigh)
- nand_erase() should be static
- on error
+ say which block failed, and if it was a bad block
+ don't give up after the first error; try to erase the rest
- on success, say which nand device was erased (name isn't unique)
Device list ("nand list"):
- say how many blocks there are
- split summary into two lines
- give example in the docs
Doc tweaks:
- Use @option{...} for DaVinci's supported hardware ECC options
For the record, I've observed that _sometimes_ erasing bad blocks causes
failure reports, and that manufacturer bad block markers aren't always
erasable (even when erasing their blocks doesn't trigger an error report).
git-svn-id: svn://svn.berlios.de/openocd/trunk@2724 b42882b7-edfa-0310-969c-e2dbd0fdcd60
This commit is contained in:
@@ -3898,9 +3898,17 @@ for more information.
|
||||
@end deffn
|
||||
|
||||
@deffn Command {nand list}
|
||||
Prints a one-line summary of each device declared
|
||||
Prints a summary of each device declared
|
||||
using @command{nand device}, numbered from zero.
|
||||
Note that un-probed devices show no details.
|
||||
@example
|
||||
> nand list
|
||||
#0: NAND 1GiB 3,3V 8-bit (Micron) pagesize: 2048, buswidth: 8,
|
||||
blocksize: 131072, blocks: 8192
|
||||
#1: NAND 1GiB 3,3V 8-bit (Micron) pagesize: 2048, buswidth: 8,
|
||||
blocksize: 131072, blocks: 8192
|
||||
>
|
||||
@end example
|
||||
@end deffn
|
||||
|
||||
@deffn Command {nand probe} num
|
||||
@@ -3950,13 +3958,15 @@ spare areas associated with each data page.
|
||||
@end itemize
|
||||
@end deffn
|
||||
|
||||
@deffn Command {nand erase} num offset length
|
||||
@deffn Command {nand erase} num [offset length]
|
||||
@cindex NAND erasing
|
||||
@cindex NAND programming
|
||||
Erases blocks on the specified NAND device, starting at the
|
||||
specified @var{offset} and continuing for @var{length} bytes.
|
||||
Both of those values must be exact multiples of the device's
|
||||
block size, and the region they specify must fit entirely in the chip.
|
||||
If those parameters are not specified,
|
||||
the whole NAND chip will be erased.
|
||||
The @var{num} parameter is the value shown by @command{nand list}.
|
||||
|
||||
@b{NOTE:} This command will try to erase bad blocks, when told
|
||||
@@ -4079,7 +4089,8 @@ This driver handles the NAND controllers found on DaVinci family
|
||||
chips from Texas Instruments.
|
||||
It takes three extra parameters:
|
||||
address of the NAND chip;
|
||||
hardware ECC mode to use (hwecc1, hwecc4, hwecc4_infix);
|
||||
hardware ECC mode to use (@option{hwecc1},
|
||||
@option{hwecc4}, @option{hwecc4_infix});
|
||||
address of the AEMIF controller on this processor.
|
||||
@example
|
||||
nand device davinci dm355.arm 0x02000000 hwecc4 0x01e10000
|
||||
|
||||
Reference in New Issue
Block a user