Is it needed to build target kernel with MTD when i am having these for my board?
Linux - Embedded & Single-board computerThis forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Is it needed to build target kernel with MTD when i am having these for my board?
Hi,
For my board if I am having the following:
1) Uboot bootloader with that I can partition the NAND memory, required for kernel,root filesystem, filesystem for user data.
2) If I can erase the memory using boot loader commands and write data/image files using boot loader commands specifying the address.
3) If I can use serial port to transfer any files in user filesystem using terminal emulators like Kermit-C, cu, minicom.
4) If I can flash the bootloader used for these tasks with Jtag Flasher provided with the vendor.
5) If I have udev/mdev in installed in target board's root filesystem.
things provided above,
a) do I have to build my target kernel for my board with MTD support?
b) do I have to create device entries in /dev folder of target root filesystem with names /dev/mtdX (char device entries),or /dev/nftlLN ( Nand Flash Translation Layer device entries)?
Please reply!
Last edited by ayyasprings; 11-21-2014 at 08:16 AM.
Kernel needs access to data stored in NAND memory for example root file system to load "init", so obviously it needs driver for that: "mtd". You do not create /dev/mtd* nodes. Kernel should create it automatically during creation of MTD partitions.
You do not create /dev/mtd* nodes. Kernel should create it automatically during creation of MTD partitions.
I am referring the Building Embedded Linux Systems book by Karim Yaghmour.In that it shows some scripts to create nodes to populate root filesystem unless we are using udev/mdev.
Please clarify that.
And also when will the NAND flash translation layer nodes will be required. Is it mandatory like /dev/mtd* ?
Yes, if your system does not use udev or mdev, etc. then you need to create it that way. Nodes in /dev need to be created somehow. You can create it staticaly by mknod and scripts or it could be created dynamically using udev/mdev or kernel can create it by itself using devtmpfs or other method. NFTL as the name suggest is a transation layer for flash memory, it is not needed if you do not need access flash like regular hard disk, "mtd" is sufficient to read data by system.
Do the uboot's nand flash related commands like nandinfo,nandbad, nandwrite, nanderase,etc,.. use Nand Flash Translation Layer driver to access the flash memory, ie) will those commands see flash memory as /dev/nftlLN devices?
It depends on what you want to do with flash memory. If you want to store there bootloader, kernel and system and not need to very often change contents that cannot be cached in RAM then you do not need any FTL.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.