Age | Commit message (Collapse) | Author |
|
Now, the MTD_NANDFLASH stands for SLC nand, and the MTD_MLCNANDFLASH
stands for the MLC nand.
This patch includes the stdbool.h, and changes the "isNAND" to boolean type,
and checks the right nand type for the MLC and SLC nand.
If the user wants to format a MLC nand for JFFS2, we will print out a message
to warn him, and exit right now.
Signed-off-by: Huang Shijie <b32955@freescale.com>
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
|
|
Saves a syscall.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
|
|
We should use the off_t type instead of off64_t or u_int32_t as its
length is controlled by the WITHOUT_LARGEFILE flag.
Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
|
|
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Signed-off-by: Artem Bityutskiy <dedekind1@gmail.com>
|
|
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
|
|
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
|
|
Commit a8801d8 (unify flash_erase and flash_eraseall) changed the
flash_erase interface in a backwards incompatible way. Before that
commit start position was given in bytes, and now it must be provided
in blocks.
While I agree the new interface is nicer, we shouldn't break the
interface. I have scripts that expect the old behaviour, and I'm
most likely not alone, so change the interface back to the old
way.
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
|
|
Need to use unsigned arithmetic and a 64-bit cast in order to
calculate and output the correct offset for eraseblocks at large
offsets. Signed integer arithmetic does not produce the correct
result "uint64_t" result, so for offsets over 2GB we get
messages like:
Erasing 512 Kibyte @ ffffffff83180000 -- 4308642136 % complete.
Note that this error was not affecting proper erasure; it just
produced incorrect status messages.
Also, we should not add an extra eraseblock for the final status
message; this gives misleading output when, for example, the
following statement is executed:
$ flash_erase /dev/mtd0 0 1
Erasing 512 Kibyte @ 80000 -- 100 % complete
We aren't erasing at offset 0x80000; it should display offset 0.
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
|
|
These have overlapping functionality, and while flash_eraseall supports
newer 64bit ioctls, flash_erase does not. So rather than graft support
onto flash_erase, merge the functionality of two into flash_erase so we
only have to support one util from now on.
A simple wrapper is provided to ease old flash_eraseall users into the
new combined flash_erase util.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
|
|
Signed-off-by: Josh Boyer <jwboyer@gmail.com>
|
|
Add a basic usage message to flash_erase.c.
Signed-off-by: Steven Finney <sfinney@healthhero.com>
|
|
|