Dear All,
I need to flash all my bootables into NAND flash instead of SD card for this I did the changes in nand_device_info.c & nand_ids.c according to the new nand chip & as per the data sheet
BTW the node is not getting created, & the nand device is not getting detected, & from the console logs I see the messages like " Scanning for the Nand device, No Nand device found"
could you please let me know what are all the other configurations needs to be done in uboot & kernel source in ltib for I.MX28
Any help would be greatly appreciated
Thanks in advance
The following are general considerations regarding i.MX28 NAND under Linux.
1.
To configure NAND parameters in Linux driver :
Please use Chapter 14 (NAND GPMI Flash Driver) of i.MX28_Linux_BSP_RM.pdf for
details about the NAND driver.
To add a New NAND flash to the BSP:
Use the NAND datasheet to know ID bytes, timings, and dimensions of the NAND flash.
Add these parameters into the BSP source code.
MTD standard table is checked first by MTD
drivers/mtd/nand/nand_ids.c
Freescale BSP extended table is checked second
drivers/mtd/nand/nand_device_info.c
For the NAND to be recognized, it must have an entry in both tables.
2.
To prepare boot NAND, first generate the boot stream file under host PC :
./ltib
./ltib -p boot_stream.spec -f
(assuming kernel command line as following :
"noinitrd console=ttyAM0,115200 root=/dev/mtdblock1 rootfstype=jffs2 gpmi" )
Then, after booting SD :
flash_eraseall /dev/mtd0
kobs-ng init /boot/imx28_ivt_linux.sb
flash_eraseall /dev/mtd1
nandwrite /dev/mtd1 /boot/rootfs.jffs2
According to users reports it may be recommended to use UBIFS or ext3 file
system on NAND.
3.
As for UBIFS details, please look at the following resources :
http://www.mjmwired.net/kernel/Documentation/filesystems/ubifs.txt
http://codingordie.blogspot.com/2010/06/ubifs-how-to.html
4.
Please pay attention on the following NAND parameters - if they are correctly reflected in BSP :
- Page size ;
- number of pages per block ;
- ECC parameters ;
- NAND ID ;
- number of address cycles.
Particularly - if ECC parameters are set properly to guarantee NAND reliability.
5.
JFFS2 is not supported.
Strictly speaking JFFS2 should work and some problems with it under i.MX28 BSP
might relate to the fact, that UBIFS as the next generation of JFFS2 is more
preferable regarding Bad Block treatment.
6.
Also the following may be useful :