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.

video decode demo not working

Hi,

I have flashed OMAP_SDK_1.0.2 on OMAP 35 x micron board and tring to run decode demo from DVSDK_3_00_00_29. I have copied DVSDK demo files in SD card. I have copied decodeCombo.x64P in decode directory and I am able to decode and run audio mp3 file as follows:-

[root@OMAP3EVM decode]# ./decode -a ../interface/data/sounds/davincieffect.mp3
Decode demo started.
Decode demo ARM Load: 5% DSP Load: 5% Display Type: VGA Video Codec: N/A Video fps: 0 fps Video bit rate: 0 kbps Video resol

Decode demo ARM Load: 0% DSP Load: 6% Display Type: VGA Video Codec: N/A Video fps: 0 fps Video bit rate: 0 kbps Video resol

Decode demo ARM Load: 1% DSP Load: 6% Display Type: VGA Video Codec: N/A Video fps: 0 fps Video bit rate: 0 kbps Video resol

Decode demo ARM Load: 0% DSP Load: 6% Display Type: VGA Video Codec: N/A Video fps: 0 fps Video bit rate: 0 kbps Video resol
End of clip reached, exiting..

 

but I while decoding the Video files (.m4v and .264) then the following errors are coming:-

[root@OMAP3EVM decode]# ./decode -v ../interface/data/videos/davincieffect_ntsc_1.264
Decode demo started.
decode: page allocation failure. order:10, mode:0xd1
[<c002f374>] (dump_stack+0x0/0x14) from [<c008c730>] (__alloc_pages+0x288/0x29c)
[<c008c4a8>] (__alloc_pages+0x0/0x29c) from [<c008c76c>] (__get_free_pages+0x28/0x5c)
[<c008c744>] (__get_free_pages+0x0/0x5c) from [<c01c2888>] (omap35xvout_alloc_buffer+0x40/0xa0)
[<c01c2848>] (omap35xvout_alloc_buffer+0x0/0xa0) from [<c01c2a34>] (omap35x_buffer_setup+0xbc/0x280)
 r5:c3786000 r4:c3786000
[<c01c2978>] (omap35x_buffer_setup+0x0/0x280) from [<c01bfccc>] (videobuf_reqbufs+0x124/0x1dc)
[<c01bfba8>] (videobuf_reqbufs+0x0/0x1dc) from [<c01c403c>] (omap24xxvout_do_ioctl+0x894/0x158c)
 r7:c066de38 r6:c3786304 r5:c3786000 r4:00000000
[<c01c37a8>] (omap24xxvout_do_ioctl+0x0/0x158c) from [<c01afc54>] (video_usercopy+0x1b8/0x2b8)
[<c01afa9c>] (video_usercopy+0x0/0x2b8) from [<c01c4e94>] (omap24xxvout_ioctl+0xdc/0xec)
[<c01c4db8>] (omap24xxvout_ioctl+0x0/0xec) from [<c00b2550>] (do_ioctl+0x68/0x78)
[<c00b24e8>] (do_ioctl+0x0/0x78) from [<c00b27c0>] (vfs_ioctl+0x260/0x278)
 r5:413e0c0c r4:c09c0a80
[<c00b2560>] (vfs_ioctl+0x0/0x278) from [<c00b2818>] (sys_ioctl+0x40/0x64)
 r7:c09c0a80 r6:c0145608 r5:413e0c0c r4:00000008
[<c00b27d8>] (sys_ioctl+0x0/0x64) from [<c002ae40>] (ret_fast_syscall+0x0/0x2c)
 r7:00000036 r6:413e1680 r5:00000002 r4:00000002
Mem-info:
DMA per-cpu:
CPU    0: Hot: hi:   18, btch:   3 usd:  11   Cold: hi:    6, btch:   1 usd:   5
Active:1468 inactive:1404 dirty:0 writeback:4 unstable:0
 free:9814 slab:417 mapped:265 pagetables:25 bounce:0
DMA free:39256kB min:1196kB low:1492kB high:1792kB active:5872kB inactive:5616kB present:89408kB pages_scanned:0 all_unreclaolowmem_reserve[]: 0 0
DMA: 34*4kB 58*8kB 2*16kB 1*32kB 7*64kB 12*128kB 3*256kB 10*512kB 14*1024kB 8*2048kB 0*4096kB 0*8192kB = 39256kB
Swap cache: add 0, delete 0, find 0/0, race 0+0
Free swap  = 0kB
Total swap = 0kB
Free swap:            0kB
22528 pages of RAM
10645 free pages
8062 reserved pages
417 slab pages
347 pages shared
0 pages swap cached
Error: Failed to create display device

 

It seems this is the issue of the memory on OMAP 35x board. After flashing newer SDK images the onboard memory is as follows:-

Filesystem                Size      Used Available Use% Mounted on
rootfs                  7.7M     4.0M      3.3M  81% /
/dev/root                7.1M     4.0M      3.3M  81% /
mdev                     57.5M         0     57.5M   0% /dev
none                     57.5M         0     57.5M   0% /tmp

 

What may be the fix .

  • Could you post the boot arguments you are using in U-Boot? Often a failure like this could be rooted in how the kernel was booted.

    I have not seen this error myself but for an allocation failuire it may be worth checking RAM memory space, do you have plenty of free RAM when using a command like top or free?

  • HI Thompson,

    Thanks for responding. The following is the bootargs parameter

    setenv bootargs_rd mem=88M console=ttyS0,115200n8 root=/dev/ram0 initrd=0x81600000,40M ramdisk_size=40960 video=omap24xxfb:rotation=90

    the following arguments are showing while giving to and free command

    [root@OMAP3EVM /]# top

    PID  PPID USER     STAT   VSZ %MEM %CPU COMMAND
      321   319 root     R     3156   4%   0% top
      319     1 root     S     3156   4%   0% -/bin/sh
        1     0 root     S     3152   4%   0% init
      316     1 root     S     3152   4%   0% /sbin/syslogd
      318     1 root     S     3152   4%   0% /usr/sbin/telnetd
      268     2 root     SW<      0   0%   0% [kmmcd]
        2     0 root     SW<      0   0%   0% [kthreadd]
        3     2 root     SWN      0   0%   0% [ksoftirqd/0]
        4     2 root     SW<      0   0%   0% [watchdog/0]
        5     2 root     SW<      0   0%   0% [events/0]
        6     2 root     SW<      0   0%   0% [khelper]
       57     2 root     SW<      0   0%   0% [kblockd/0]
       63     2 root     SW       0   0%   0% [twl4030-irq]
       64     2 root     SW       0   0%   0% [twl4030-gpio]
       65     2 root     SW<      0   0%   0% [omap2_mcspi/0]
       72     2 root     SW<      0   0%   0% [ksuspend_usbd]
       75     2 root     SW<      0   0%   0% [khubd]
      100     2 root     SW       0   0%   0% [pdflush]
      101     2 root     SW       0   0%   0% [pdflush]
      102     2 root     SW<      0   0%   0% [kswapd0]


    [root@OMAP3EVM /]# free
                  total         used         free       shared      buffers
      Mem:        85232        42652        42580            0         8192
     Swap:            0            0            0
    Total:        85232        42652        42580

    The following shows the memory on board

    [root@OMAP3EVM /]# df -h
    Filesystem                Size      Used Available Use% Mounted on
    rootfs                    7.7M      4.0M      3.3M  55% /
    /dev/root                 7.7M      4.0M      3.3M  55% /
    mdev                     41.6M         0     41.6M   0% /dev
    none                     41.6M         0     41.6M   0% /tmp


    How to check the RAM memory available on OMAP board?Why the video demos are not working? where am I going wrong? How to make it work? Why the OMAP default images as well as filesystem was write-enable and how to revert it back. The earlier memory on OMAP board before flashing new images were as follows:-





    [root@OMAP3EVM/]# df -h
    Filesystem                Size      Used Available Use% Mounted on
    rootfs                  120.5M     20.7M     99.8M  17% /
    /dev/root               120.5M     20.7M     99.8M  17% /
    mdev                     61.5M         0     61.5M   0% /dev
    none                     61.5M         0     61.5M   0% /tmp

    Regards,

    Vineet

  •  

    Hi Thompson,

     

    We had recompiled the kernel and enabled video(.ko) files as a module and now decode and encode application is working but it is failed to create display

     

    [root@OMAP3EVM decode]# ./decode -v /mnt/data/videos/davincieffect_ntsc_1.264
    Decode demo started.
    Error: Failed to create display device
    [root@OMAP3EVM decode]#

     

    Now I am able to decode and encode the files but not able to display on LCD. Is there any fix for the display video to LCD or do I need to enable some driver while compiling the kernel? How to play the .yuv files and .264 files to LCD? However ./interface -l 0 is working and displaying buttons on LCD screen.

     

    Regards,

    Vineet

  • The free command shows how much RAM you have available and it appears you have plenty.

    I setup the DVSDK version you are using and the video worked in my case, though I am setup to do a TFTP kernel with NFS filesystem. As a debugging step if you have not already could you try setting up your board to boot your kernel and filesystem over NFS as discussed in the getting started guide? This should narrow down where the problem is, if it is something specific to your ramdisk flash boot or if there is overall something wrong with your software install or board.

    The failure to create display device is a somewhat generic error, it means for some reason the demo could not access the display driver, which could stem from the driver not being instantiated to the driver not supporting the mode the decode demo is asking for, or some other driver level failure. The fact that the OSD shows up properly when you run interface is a good sign though, that should prove the display driver is at least in place.