This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Dm355 Failure to load loadmodules.sh

I currently going throught the manual for using the DM355 board trying to run the encode demos, before you do that you must run the loadmodules to load the video codec's but it is not working?

the ./loadmodules.sh command refuses to work and I think

because of this the demos won't find their video files.

heres the list of errors that I get.

root@192.168.11.2:/opt/dvsdk_1_30_00_23/demos# ./loadmodules.sh

CMEMK Error: Pysical start and end addresses not supplied

insmod: error inserting 'cmemk.ko': -1 Invalid parameters

./loadmodules.sh: line 11: .mapdmaq: command not found

dm350mmap: disagrees about version of symbol davinci_request_dma

dm350mmap: Unknown symbol davinci_request_dma

insmod: error inserting 'dm350mmap.ko': -1 Unknown symbol in module

mknod: wrong number of arguments

Try `mknod --help' for more information.

Can any one help?

  • This sounds like your loadmodules.sh file is corrupted or for some other DVSDK version from the CMEM you are trying to use, the loadmodules.sh file should have some commands in it that look like below which was taken from a 1.30.00.40 DVSDK install:

    #!/bin/sh

    # 12MB
    insmod cmemk.ko phys_start=0x87400000 phys_end=0x88000000 pools=1x2097152,2x1529856,7x829440,1x524288,1x108680,1x81920,2x8192,6x4096

    ./mapdmaq

    insmod dm350mmap.ko
    rm -f /dev/dm350mmap
    mknod /dev/dm350mmap c `awk "\\$2==\"dm350mmap\" {print \\$1}" /proc/devices` 0

    Also note that this script is dependent on having the cmemk.ko and dm350mmap.ko file local to the script, and that the versions of these files must be appropriate with the rest of your system, namely these files from your filesystem must match the U-Boot and UImage (kernel), so it may be worth verifying you are using everything from the same DVSDK install.

  • Sounds like you have a bad loadmodules file.  This file is basically a scipt to keep the user from having to type a bunch of commands at the command line.  One of the first things it does is load cmemk.ko module; it appears it is not passing to correct parameters to cmemk.ko.

    Another possibility is that you are mixing incompatible software from different software releases, please see the following post for more details on how to upgrade software correctly.

    https://community.ti.com/forums/p/75/98.aspx#98

    Let us know if this helps and if there is anything else we can do to assist you.

     

  • Hi Bernie
       
            It's sorted a few of the faults out, so thankyou for that and I found another one my end, but I am still getting  
     
        dm250mmap: disagrees about version of symbol davinci_request_dma
     
    If this is a version issure how do I find out what versions I have and how do I download the latest?
     
    Regards
     
    Slightly happier me. 
  •  

    This is the response during booting. Can any one see a problem with this? 

    this is MT29F16G08FAA device                       
    UBL: detected valid U-Boot magic number             
    UBL: booting to U-Boot                              


    U-Boot 1.2.0 (Oct 17 2007 - 15:38:02)

    DRAM:  128 MB
    NAND:  NAND device: Manufacturer ID: 0x2c, Chip ID: 0xd3 (Micron NAND 1GiB 3,3V)
    Bad block table found at page 524224, version 0x01
    Bad block table found at page 524160, version 0x01
    nand_read_bbt: Bad block at 0x035a0000
    nand_read_bbt: Bad block at 0x062a0000
    nand_read_bbt: Bad block at 0x09860000
    nand_read_bbt: Bad block at 0x144a0000                                         
    nand_read_bbt: Bad block at 0x1a2e0000                                         
    nand_read_bbt: Bad block at 0x21460000                                         
    nand_read_bbt: Bad block at 0x23ce0000                                         
    nand_read_bbt: Bad block at 0x30940000                                         
    nand_read_bbt: Bad block at 0x34e20000                                         
    nand_read_bbt: Bad block at 0x35360000                                         
    nand_read_bbt: Bad block at 0x3ef20000                                         
    NAND device: Manufacturer ID: 0x2c, Chip ID: 0xd3 (Micron NAND 1GiB 3,3V 8-bit)
    Bad block table found at page 524224, version 0x01                             
    Bad block table found at page 524160, version 0x01                             
    nand_read_bbt: Bad block at 0x09c80000                                         
    nand_read_bbt: Bad block at 0x31f80000                                         
    nand_read_bbt: Bad block at 0x3ccc0000                                         
    nand_read_bbt: Bad block at 0x3eda0000                                         
    2048 MiB                                                                       
    In:    serial                                                                  
    Out:   serial                                                                  
    Err:   serial                                                                  
    ARM Clock :- 216MHz                                                            
    DDR Clock :- 171MHz                                                            
    Hit any key to stop autoboot:  0                                               
                                                                                   
    Loading from NAND 1GiB 3,3V 8-bit, offset 0x400000                             
       Image Name:   Linux-2.6.10_mvl401                                           
       Image Type:   ARM Linux Kernel Image (uncompressed)                         
       Data Size:    1578988 Bytes =  1.5 MB                                       
       Load Address: 80008000                                                      
       Entry Point:  80008000                                                      
    ## Booting image at 80700000 ...                                               
       Image Name:   Linux-2.6.10_mvl401                                           
       Image Type:   ARM Linux Kernel Image (uncompressed)                         
       Data Size:    1578988 Bytes =  1.5 MB                                       
       Load Address: 80008000                                                      
       Entry Point:  80008000                                                      
       Verifying Checksum ... OK                                                   
    OK                                                                             
                                                                                   
    Starting kernel ...                                                            
                                                                                   
    Linux version 2.6.10_mvl401 (a0868396@gtcmbuild3.gt.design.ti.com) (gcc version8
    CPU: ARM926EJ-Sid(wb) [41069265] revision 5 (ARMv5TEJ)                         
    CPU0: D VIVT write-back cache                                                  
    CPU0: I cache: 16384 bytes, associativity 4, 32 byte lines, 128 sets           
    CPU0: D cache: 8192 bytes, associativity 4, 32 byte lines, 64 sets             
    Machine: DaVinci DM355 EVM                                                     
    Memory policy: ECC disabled, Data cache writeback                              
    DM0350                                                                         
    Built 1 zonelists                                                              
    Kernel command line: console=ttyS0,115200n8 noinitrd ip=dhcp root=/dev/nfs rw nc
    PID hash table entries: 512 (order: 9, 8192 bytes)                             
    Console: colour dummy device 80x30                                             
    Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)                 
    Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)                   
    Memory: 116MB = 116MB total                                                    
    Memory: 114176KB available (2748K code, 570K data, 180K init)                  
    Mount-cache hash table entries: 512 (order: 0, 4096 bytes)                     
    CPU: Testing write buffer coherency: ok                                        
    spawn_desched_task(00000000)                                                   
    desched cpu_callback 3/00000000                                                
    ksoftirqd started up.                                                          
    desched cpu_callback 2/00000000                                                
    desched thread 0 started up.                                                   
    NET: Registered protocol family 16                                             
    DaVinci: 104 gpio irqs                                                         
    Registering platform device 'serial8250.0'. Parent at platform                 
    Registering platform device 'musb_hdrc'. Parent at platform                    
    Registering platform device 'nand_davinci.0'. Parent at platform               
    Registering platform device 'dm9000.0'. Parent at platform                     
    Registering platform device 'mmc.0'. Parent at platform                        
    Registering platform device 'mmc.1'. Parent at platform                        
    DaVinci I2C DEBUG: 23:57:20 Feb  2 2008                                        
    Registering platform device 'i2c'. Parent at platform                          
    ch0 default output "COMPOSITE", mode "NTSC"                                    
    VPBE Encoder Initialized                                                       
    LogicPD encoder initialized                                                    
    SCSI subsystem initialized                                                     
    usbcore: registered new driver usbfs                                           
    usbcore: registered new driver hub                                             
    musb_hdrc: version 2.2a/db-0.4.8 [cppi-dma] [host] [debug=0]                   
    musb_hdrc: ConfigData=0x06 (UTMI-8, dyn FIFOs, SoftConn)                       
    musb_hdrc: MHDRC RTL version 1.300                                             
    musb_hdrc: USB Host mode controller at c7802000 using DMA, IRQ 12              
    musb_hdrc musb_hdrc: new USB bus registered, assigned bus number 1             
    hub 1-0:1.0: USB hub found                                                     
    hub 1-0:1.0: 1 port detected                                                   
    DaVinci I2C WARNING: i2c: NACK detected                                        
    DaVinci I2C WARNING: i2c: NACK detected                                        
    DaVinci I2C WARNING: i2c: NACK detected                                        
    DaVinci I2C WARNING: i2c: NACK detected                                        
    DaVinci I2C WARNING: i2c: NACK detected                                        
    Registering platform device 'dm_spi.0'. Parent at platform                     
    NetWinder Floating Point Emulator V0.97 (double precision)                     
    JFFS2 version 2.2. (NAND) (C) 2001-2003 Red Hat, Inc.                          
    yaffs Feb  2 2008 23:56:53 Installing.                                         
    Initializing Cryptographic API                                                 
    Registering platform device 'davincifb.0'. Parent at platform                  
    davincifb davincifb.0: dm_osd0_fb: Initial window configuration is invalid.    
    davincifb davincifb.0: dm_osd0_fb: 720x576x16@0,0 with framebuffer size 2025KB 
    davincifb davincifb.0: dm_vid0_fb: Initial window configuration is invalid.    
    davincifb davincifb.0: dm_vid0_fb: 720x576x16@0,0 with framebuffer size 2500KB 
    davincifb davincifb.0: dm_osd1_fb: 720x480x4@0,0 with framebuffer size 1350KB  
    davincifb davincifb.0: dm_vid1_fb: Initial window configuration is invalid.    
    davincifb davincifb.0: dm_vid1_fb: 720x576x16@0,0 with framebuffer size 2500KB 
    watchdog: TI DaVinci Watchdog Timer: timer margin 64 sec                       
    Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing disabled      
    Registering platform device 'serial8250'. Parent at platform                   
    ttyS0 at MMIO 0x1c20000 (irq = 40) is a 16550A                                 
    ttyS1 at MMIO 0x1c20400 (irq = 41) is a 16550A                                 
    ttyS2 at MMIO 0x1e06000 (irq = 14) is a 16550A                                 
    io scheduler noop registered                                                   
    io scheduler anticipatory registered                                           
    RAMDISK driver initialized: 1 RAM disks of 32768K size 1024 blocksize          
    loop: loaded (max 8 devices)                                                   
    dm9000 Ethernet Driver                                                         
    eth0: dm9000 at c7862000,c7864002 IRQ 45 MAC: 00:0e:99:02:c4:2c                
    i2c /dev entries driver                                                        
    Linux video capture interface: v1.00                                           
    Registering platform device 'vpfe.1'. Parent at platform                       
    vpfe vpfe.1: DaVinci v4l2 capture driver V1.0 loaded                           
    Registering platform device 'DavinciDisplay.1'. Parent at platform             
    Trying to register davinci display video device.                               
    layer=c0bf3c00,layer->video_dev=c0bf3d64                                       
    Trying to register davinci display video device.                               
    layer=c0bf3a00,layer->video_dev=c0bf3b64                                       
    davinci_init:DaVinci V4L2 Display Driver V1.0 loaded                           
    ipipe major#: 254, minor# 0                                                    
    Registering platform device 'dm355_ipipe.2'. Parent at platform                
    ipipe driver registered                                                        
    af major#: 253, minor# 0                                                       
    Registering platform device 'dm355_af.2'. Parent at platform                   
    aew major#: 252, minor# 0                                                      
    Registering platform device 'dm355_aew.2'. Parent at platform                  
    elevator: using anticipatory as default io scheduler                           
    nand_davinci nand_davinci.0: Using 4-bit hardware ECC                          
    NAND device: Manufacturer ID: 0x2c, Chip ID: 0xd3 (Micron NAND 1GiB 3,3V 8-bit)
    2 NAND chips detected                                                          
    nand_bbt: ECC error while reading bad block table                              
    nand_bbt: ECC error while reading bad block table                              
    Creating 5 MTD partitions on "nand_davinci.0":                                 
    0x00000000-0x003c0000 : "bootloader"                                           
    0x003c0000-0x00400000 : "params"                                               
    0x00400000-0x00800000 : "kernel"                                               
    0x00800000-0x20800000 : "filesystem1"                                          
    0x20800000-0x80000000 : "filesystem2"                                          
    nand_davinci nand_davinci.0: hardware revision: 2.3                            
    dm_spi.0: davinci SPI Controller driver at 0xc7866000 (irq = 42) use_dma=0     
    Initializing USB Mass Storage driver...                                        
    usbcore: registered new driver usb-storage                                     
    USB Mass Storage support registered.                                           
    usbcore: registered new driver usbhid                                          
    drivers/usb/input/hid-core.c: v2.0:USB HID core driver                         
    mice: PS/2 mouse device common for all mice                                    
    mmc mmc.0: Supporting 4-bit mode                                               
    mmc mmc.0: Using DMA mode                                                      
    mmc mmc.1: Supporting 4-bit mode                                               
    mmc mmc.1: Using DMA mode                                                      
    Registering platform device 'davinci-audio.0'. Parent at platform              
    NET: Registered protocol family 2                                              
    mmcblk0: mmc1:0001 SDMB-32 31360KiB                                            
     mmcblk0: p1                                                                   
    IP: routing cache hash table of 512 buckets, 4Kbytes                           
    TCP: Hash tables configured (established 8192 bind 16384)                      
    Initializing XFRM netlink socket                                               
    NET: Registered protocol family 1                                              
    NET: Registered protocol family 10                                             
    IPv6 over IPv4 tunneling driver                                                
    NET: Registered protocol family 17                                             
    eth0: link down                                                                
    Sending DHCP requests ., OK                                                    
    IP-Config: Got DHCP answer from 0.0.0.0, my address is 192.168.11.2            
    IP-Config: Complete:                                                           
          device=eth0, addr=192.168.11.2, mask=255.255.255.0, gw=192.168.11.1,     
         host=192.168.11.2, domain=, nis-domain=(none),                            
         bootserver=0.0.0.0, rootserver=192.168.11.3, rootpath=                    
    Looking up port of RPC 100003/2 on 192.168.11.3                                
    Looking up port of RPC 100005/1 on 192.168.11.3                                
    VFS: Mounted root (nfs filesystem).                                            
    Freeing init memory: 180K                                                      
    eth0: link up, 100Mbps, full-duplex, lpa 0x45E1                                
    INIT: version 2.85 booting                                                     
    Mounting a tmpfs over /dev...done.                                             
    Creating initial device nodes...done.                                          
    Activating swap...done.                                                        
    Remounting root filesystem...done.                                             
    Calculating module dependencies                                                
    Loading modules:                                                               
    Checking all file systems: fsck                                                
    fsck 1.35 (28-Feb-2004)                                                        
    Mounting local filesystems: mount nothing was mounted                          
    Cleaning: /tmp /var/lock /var/run done.                                        
    Setting up networking (ifupdown) ..                                            
    Cleaning: /etc/network/run/ifstate done.                                       
    Starting network interfaces: done.                                             
    Starting hotplug subsystem:                                                    
       pci                                                                         
       pci      [success]                                                          
       usb                                                                         
       usb      [success]                                                          
       isapnp                                                                      
       isapnp   [success]                                                          
       ide                                                                         
       ide      [success]                                                          
       input                                                                       
       input    [success]                                                          
       scsi                                                                        
       scsi     [success]                                                          
    done.                                                                          
    Starting portmap daemon: portmap.                                              
    done.                                                                          
    Setting pseudo-terminal access permissions...done.                             
    Updating /etc/motd...done.                                                     
    INIT: Entering runlevel: 3                                                     
    Starting NFS common utilities: statd lockd.                                    
    Starting internet superserver: inetd.                                          
    Starting MontaVista target tools daemon: mvltdmvltd version 2.1 MontaVista Soft.
    mvltd[1067]: started on port 34577                                             
    .                                                                              
    MontaVista(R) Linux(R) Professional Edition 4.0.1 (0600980)                    
                                                                                   
    192.168.11.2 login: root                                                       
    Last login: Thu Jan  1 00:00:31 1970 on console                                
    Linux 192.168.11.2 2.6.10_mvl401 #1 Sat Feb 2 23:59:35 EST 2008 armv5tejl GNU/Lx
                                                                                   
    Welcome to MontaVista(R) Linux(R) Professional Edition 4.0.1 (0600980).        
                                                                                   
    root@192.168.11.2:~# cd ..                                                     

     

  • I am glad to hear that you are one step closer here, and I do agree that you are probably still looking at some version issue. Unfortunately identifying what versions of the various software pieces you are using is not necessarily trivial, because the version numbers you see do not necessarily correspond to the TI release version you need, in other words there are multiple releases with the same kernel version that have different driver attributes, so you could find what version by what features are supported and comparing to release notes.

    The easier way would be to setup a TFTP/NFS boot, and boot your kernel and filesystem out of the same DVSDK version so you know they will work together well, the getting started guide goes over these processes. You would also want to burn the U-Boot from the same DVSDK version into the flash, though I am not sure how necessary that is for the DM355, as I do not recall if I had to re burn U-Boot on it to move to the newer DVSDK releases.

    To get the latest versions of the software you will need to register your EVM through www.ti.com/davinciregistration and through the same site there is a link to get to the updates page.

  • I had same problem when I inserted the cmemk.ko kernel module on my DaVinci DM6446. Here is the output:

    # ./loadmodules.sh

    CMEMK Error: Pysical start and end addresses not supplied

    insmod: error inserting 'cmemk.ko': -1 Invalid parameters

     

    The kernel failed to parse the command line argument. I was using kernel 2.6.10 version. Finally I have fixed the problem using the kernel 2.6.30.

    The problem was in the kernel/params.c file (in version 2.6.10) which cannot parse the cmd line argument for kernel module properly.

    This note may help some other.