• Join
  • Sign In with my.TI Login
Texas Instruments
  • Products
  • Applications
  • Tools & Software
  • Support & Community
  • Sample & Buy
  • About TI
Sample & Purchase Cart Sample & Purchase Cart
  • Search
  • Advanced
TI E2E™ Community
  • Support Forums
  • Blogs
  • Groups
  • Videos
  • 简体中文
  • More ...
TI Home » TI E2E Community » Support Forums » Embedded Software » Linux » Linux forum » Fail to modprobe cmem module when kernel bootup in dm368-evm
Share
Linux
  • Forum
Options
  • Subscribe via RSS

Fail to modprobe cmem module when kernel bootup in dm368-evm

Fail to modprobe cmem module when kernel bootup in dm368-evm

This question is answered
Hu James
Posted by Hu James
on Apr 26 2012 10:18 AM
Prodigy220 points

In my kenel boot up logs:

------------------------------------------------

INIT: version 2.86 booting
Please wait: booting...
Starting udev
udev: starting version 141
Remounting root file system...
Caching udev devnodes
Populating dev cachemv: cannot rename '/tmp/devices': No such file or directory
ALSA: Restoring mixer settings...
NOT configuring network interfaces: / is an NFS mount
hwclock: can't open '/dev/misc/rtc': No such file or directory
Fri Mar 25 00:10:00 UTC 2011
hwclock: can't open '/dev/misc/rtc': No such file or directory
INIT: Entering runlevel: 5
Starting system message bus: dbus.
Starting telnet daemon.
Starting syslogd/klogd: done
Starting thttpd.
FATAL: Module cmemk not found.
FATAL: Module irqk not found.
FATAL: Module edmak not found.
FATAL: Module dm365mmap not found.
BusyBox v1.13.2 (2011-03-24 18:58:44 CDT) multi-call binary

Usage: mknod [OPTIONS] NAME TYPE MAJOR MINOR

Create a special file (block, character, or pipe)

Options:
-m Create the special file using the specified mode (default a=rw)
TYPEs include:
b: Make a block device
c or u: Make a character device
p: Make a named pipe (MAJOR and MINOR are ignored)

------------------------------------------------

I can see those modules located in "/lib/modules/2.6.32.17-davinci1-g77319a0-dirty/kernel/drivers/dsp/"

-----------------------------------------------------

root@dm368-evm:~# ls -l /lib/modules/2.6.32.17-davinci1-g77319a0-dirty/kernel/drivers/dsp/
-rwxr-xr-x 1 root root 26334 Apr 26 2012 cmemk.ko
-rwxr-xr-x 1 root root 6560 Apr 26 2012 dm365mmap.ko
-rwxr-xr-x 1 root root 9657 Apr 26 2012 edmak.ko
-rwxr-xr-x 1 root root 9483 Apr 26 2012 irqk.ko

------------------------------------------------------

 If i check details of "/lib/modules/2.6.32.17-davinci1-g77319a0-dirty", they are like below

------------------------------------------------------

root@dm368-evm:~# ls -l /lib/modules/2.6.32.17-davinci1-g77319a0-dirty
lrwxrwxrwx 1 root root 78 Apr 23 2012 build -> /home/davinci/ti-dvsdk_dm368-evm_4_02_00_06/psp/linux-2.6.32.17-psp03.01.01.39
drwxr-xr-x 6 root root 4096 Apr 23 2012 kernel
-rw-r--r-- 1 root root 45 Apr 26 2012 modules.alias
-rw-r--r-- 1 root root 3359 Apr 23 2012 modules.alias.bin
-rw-r--r-- 1 root root 69 Apr 26 2012 modules.ccwmap
-rw-r--r-- 1 root root 0 Apr 26 2012 modules.dep
-rw-r--r-- 1 root root 4341 Apr 23 2012 modules.dep.bin
-rw-r--r-- 1 root root 73 Apr 26 2012 modules.ieee1394map
-rw-r--r-- 1 root root 141 Apr 26 2012 modules.inputmap
-rw-r--r-- 1 root root 81 Apr 26 2012 modules.isapnpmap
-rw-r--r-- 1 root root 74 Apr 26 2012 modules.ofmap
-rw-r--r-- 1 root root 1702 Apr 23 2012 modules.order
-rw-r--r-- 1 root root 99 Apr 26 2012 modules.pcimap
-rw-r--r-- 1 root root 43 Apr 26 2012 modules.seriomap
-rw-r--r-- 1 root root 49 Apr 26 2012 modules.symbols
-rw-r--r-- 1 root root 5349 Apr 23 2012 modules.symbols.bin
-rw-r--r-- 1 root root 189 Apr 26 2012 modules.usbmap
lrwxrwxrwx 1 root root 78 Apr 23 2012 source -> /home/davinci/ti-dvsdk_dm368-evm_4_02_00_06/psp/linux-2.6.32.17-psp03.01.01.39
root@dm368-evm:~#

-------------------------------------------------

If i try to find the module location, the result like below:

------------------------------------------------

root@dm368-evm:~# depmod /lib/modules/`uname -r`/modules.dep
WARNING: Module /lib/modules/2.6.32.17-davinci1-g77319a0-dirty/modules.dep is not an elf object
root@dm368-evm:~#

-------------------------------------------------

content of "/etc/init.d/modutils.sh" is like below:

------------------------------------------------

root@dm368-evm:~# cat /etc/init.d/modutils.sh
#!/bin/sh

LOAD_MODULE=modprobe
[ -e /sbin/modprobe ] || LOAD_MODULE=insmod

if [ -e /sbin/depmod -a ! -f /lib/modules/`uname -r`/modules.dep ]; then
[ "$VERBOSE" != no ] && echo "Calculating module dependencies ..."
depmod -Ae
fi

if [ -f /proc/modules ]; then
if [ -f /etc/modules ]; then
[ "$VERBOSE" != no ] && echo -n "Loading modules: "
while read module args
do
case "$module" in
\#*|"") continue ;;
esac
[ "$VERBOSE" != no ] && echo -n "$module "
eval "$LOAD_MODULE $module $args >/dev/null 2>&1"
done < /etc/modules
[ "$VERBOSE" != no ] && echo
fi
fi

: exit 0

--------------------------------------------------

Could you help on this ?

BTW: nothing printed after "modprobe -l"

Regards,

James

Report Abuse
  • Reply
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
All Replies
  • Norman Wong
    Posted by Norman Wong
    on Apr 26 2012 11:36 AM
    Guru14970 points

    Not sure if the "depmod filename" is what you intended. Maybe try "depmod -a" to rebuild the modules.dep file.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hu James
    Posted by Hu James
    on Apr 29 2012 11:32 AM
    Prodigy220 points

    I search the command for "depmod", it seems kernel Makefile is to run the command:

    [linux-devkit]:~/ti-dvsdk_dm368-evm_4_02_00_06/psp/linux-2.6.32.17-psp03.01.01.39> vim Makefile

    ------------------------------------------

    # Run depmod only if we have System.map and depmod is executable
    quiet_cmd_depmod = DEPMOD $(KERNELRELEASE)
    cmd_depmod = \
    if [ -r System.map -a -x $(DEPMOD) ]; then \
    $(DEPMOD) -ae -F System.map \
    $(if $(strip $(INSTALL_MOD_PATH)), -b $(INSTALL_MOD_PATH) ) \
    $(KERNELRELEASE); \
    fi

    -----------------------------------------

    Is that to say, kernel Makefile does not work well to depmod/install modules ?

    You can see the size of module.des is zero.

    -----------------------------------------------

    davinci@ubuntu:~/targetfs/lib/modules/2.6.32.17-davinci1-g77319a0-dirty$ ls -l modules.dep
    -rw-r--r-- 1 root root 0 2012-04-26 23:09 modules.dep

    -----------------------------------------------

    Could some one can help on this ?

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Norman Wong
    Posted by Norman Wong
    on Apr 29 2012 17:30 PM
    Verified Answer
    Verified by Hu James
    Guru14970 points

    I don't think a cross-platform depmod exists on the host. Not with TI's toolchain. You have to "depmod -a" on the target.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hu James
    Posted by Hu James
    on Apr 30 2012 08:55 AM
    Prodigy220 points

    Hi Wong,

    It works as you told.

    After i run command "depmod -a" in the target, new modules.dep of "/lib/modules/2.6.32.17-davinci1-g77319a0-dirty/modules.dep" is created, and it works with "modprobe "

    But i still could not understand why TI DVSDK build environment could not create target's "/lib/modules/2.6.32.17-davinci1-g77319a0-dirty/modules.dep" ?

    In theory,  it built out any resource which "depmod -a" requested in its DVSDK build environment for the target.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Norman Wong
    Posted by Norman Wong
    on Apr 30 2012 11:23 AM
    Guru14970 points

    I am not expert in the module.dep file format. I agree that it should be be platform independent but it appears not. As such, a cross-platform version of depmod is required. Similiar to the need for a cross-compiler. Google about for "cross depmod" and there are some hits that would suggest there is one for a non-TI platform. Somebody did think about it. The lack of a cross-depmod in the toolchain is a real hindrance to building a complete target filesystem on the host. You have to have a working target to finish the filesystem and then save the filesytem for production.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
TI E2E™ Community
  • Support Forums
  • Blogs
  • Videos
  • Groups
  • Site Support & Feedback
  • Settings
TI E2E™ Community Groups
  • TI University Program
  • Make the Switch
  • Microcontroller Projects
  • Motor Drive & Control
Other Communities
  • Deyisupport
  • Designsomething.org
  • beagleboard.org
  • TI on Element 14
  • TI on TechXchangeSM
Other Technical & Support Resources
  • WEBENCH® Design Center
  • Product Information Centers
  • Technical Documents
  • TI Design Network
  • TI Technical Articles
  • TI Training

All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms of Use of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms of Use of this site. TI, its suppliers and providers of content reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

Follow Us Texas Instruments on Facebook Texas Instruments on Twitter Texas Instruments on LinkedIn Texas Instruments on Google+
TI Worldwide | Contact Us | my.TI Login | Site Map | Corporate Citizenship | mobile m.ti.com (Mobile Version)

TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs and
embedded processors, along with software, tools and the industry’s largest sales/support staff.

© Copyright 1995-2013 Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy Policy | Terms of Use