LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Embedded & Single-board computer (http://www.linuxquestions.org/questions/linux-embedded-and-single-board-computer-78/)
-   -   proc/mtd is empty (http://www.linuxquestions.org/questions/linux-embedded-and-single-board-computer-78/proc-mtd-is-empty-4175444475/)

ranjana kumari 01-07-2013 04:49 AM

proc/mtd is empty
 
when i gave cat /proc/mtd on the target board which has tms320dm368 microcontroller i got following message
dev: size erasesize name

I am not able to see the partitions for bootloader, params, kernel and filesystem..
In the kernel configuration file
CONFIG_JFFS2 =y
please suggest where could be the problem

dpdonny 01-07-2013 08:46 AM

What about MTD kernel config parameters? You should have at least the following defined?

CONFIG_MTD
CONFIG_MTD_CHAR
CONFIG_MTD_BLKDEVS
CONFIG_MTD_BLOCK

Does dmesg report any indication of a problem detecting flash?

What kind of flash are you using NOR or NAND? Are the proper config parameters set?

ranjana kumari 01-07-2013 11:11 PM

In my kernel config file

CONFIG_MTD = y
CONFIG_MTD_CHAR = y
CONFIG_MTD_BLKDEVS = y
CONFIG_MTD_BLOCK = y

dmesg doesnot report any indication of a problem detecting flash

Iam using Nand flash

when I am using Linux-2.6.32.17-davinci1 as uImage cat/proc/mtd is empty but if I use Linux-2.6.18_pro500-davinci_IPNC cat /proc/mtd displays the partition for bootloader,params,kernel and filesystem.
So please suggest what changes need to be done in kernel - Linux-2.6.32.17-davinci1
to see the partition for different parameters

dpdonny 01-08-2013 09:42 AM

The problem most likely lies in your board file and/or kernel config files. Do a diff of each kernel's .config file. Look for board and/or MTD config differences.

Not sure what board target you are using, but it's probably under arch/arm/mach-davinci/board-*.c.

Here is an example of the MTD NAND partitions being defined on a Davinci board.

#ifdef CONFIG_DA830_UI_NAND
static struct mtd_partition da830_evm_nand_partitions[] = {
[0] = {
.name = "bootloader",
.offset = 0,
.size = SZ_32K,
.mask_flags = MTD_WRITEABLE,
},
...
[3] = {
.name = "filesystem",
.offset = 0,
.size = SZ_32K,
.mask_flags = MTD_WRITEABLE,
},


};
#endif

The above example comes from arch/arm/mach-davinci/board-da830-evm.c in the 3.1.0 distro. Note, da830_evm_nand_partitions is conditionally compiled in based on CONFIG_DA830_UI_NAND. Perhaps you have a similar issue?

ranjana kumari 01-09-2013 04:01 AM

ipv6: disagrees about version of symbol module_layout
modprobe: FATAL: Error inserting ipv6 (/lib/modules/2.6.32.17-davinci1/kernel/net/ipv6/ipv6.ko): Invalid module format

Starting syslogd/klogd: done
Starting thttpdipv6: disagrees about version of symbol module_layout
.
ipv6: disagrees about version of symbol module_layout
cmemk: disagrees about version of symbol module_layout
FATAL: Error inserting cmemk (/lib/modules/2.6.32.17-davinci1/kernel/drivers/dsp/cmemk.ko): Invalid module format
irqk: disagrees about version of symbol module_layout
FATAL: Error inserting irqk (/lib/modules/2.6.32.17-davinci1/kernel/drivers/dsp/irqk.ko): Invalid module format
edmak: disagrees about version of symbol module_layout
FATAL: Error inserting edmak (/lib/modules/2.6.32.17-davinci1/kernel/drivers/dsp/edmak.ko): Invalid module format
dm365mmap: disagrees about version of symbol module_layout
FATAL: Error inserting dm365mmap (/lib/modules/2.6.32.17-davinci1/kernel/drivers/dsp/dm365mmap.ko): Invalid module format
BusyBox v1.13.2 (2011-03-24 18:58:44 CDT) multi-call binary

the abobe kernel modules are not laoaded ...so is this the reason for cat /proc/mtd to be empty


All times are GMT -5. The time now is 11:39 AM.