NAND Writing: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
(Added recipe for copying files.) |
||
Line 1: | Line 1: | ||
Some recipes for putting filesystems onto NAND FLASH. See also [[Installing_to_NAND]]. |
|||
=== Bad Block Table Messed Up === |
|||
This is a recipe for erasing the NAND Flash and rewriting it, in the event that the bad block table is potentially messed up. |
This is a recipe for erasing the NAND Flash and rewriting it, in the event that the bad block table is potentially messed up. |
||
Line 10: | Line 14: | ||
Reboot, and the BBT should be recreated as cafe_nand loads, based on the bad blocks found during formatting. |
Reboot, and the BBT should be recreated as cafe_nand loads, based on the bad blocks found during formatting. |
||
=== Copying Stuff on as Files === |
|||
This is for when you don't have a preformatted JFFS2 image and you just want to make an empty filesystem and copy on some files. |
|||
modprobe mtdchar |
|||
flash_eraseall -j /dev/mtd0 |
|||
mount -tjffs2 mtd0 /mnt |
|||
# Now use cp, or tar, or whatever to copy files into /mnt |
|||
umount /mnt |
|||
Note that the "umount" command will sometimes take a while to finish. |
Revision as of 23:23, 2 November 2006
Some recipes for putting filesystems onto NAND FLASH. See also Installing_to_NAND.
Bad Block Table Messed Up
This is a recipe for erasing the NAND Flash and rewriting it, in the event that the bad block table is potentially messed up.
Boot from a USB key, passing the cmdline argument "cafe_nand.skipbbt=1"
Login as root
modprobe mtdchar flash_eraseall -j /dev/mtd0 nandwrite -p /dev/mtd0 build131.img
Reboot, and the BBT should be recreated as cafe_nand loads, based on the bad blocks found during formatting.
Copying Stuff on as Files
This is for when you don't have a preformatted JFFS2 image and you just want to make an empty filesystem and copy on some files.
modprobe mtdchar flash_eraseall -j /dev/mtd0 mount -tjffs2 mtd0 /mnt # Now use cp, or tar, or whatever to copy files into /mnt umount /mnt
Note that the "umount" command will sometimes take a while to finish.