2009-10-06 21:56:50     BF537 Bluetechnix wrong memory display

Document created by Aaronwu Employee on Aug 19, 2013
Version 1Show Document
  • View in full screen mode

2009-10-06 21:56:50     BF537 Bluetechnix wrong memory display

Rafael Beims (BRAZIL)

Message: 80914   

 

Hello,

 

I'm trying to create an application for the Bluetechnix CM-BF537E board. I can compile the uClinux (uClinux-dist-2009R1-RC6.tar.bz2), and I can boot the generated image. However, when I try to start a bigger application, for instance vlc, I get errors about the failure to allocate memory:

 

# vlc

 

VLC media player 0.8.6b Janus

 

starting VLC root wrapper... using UID 0 (root)

 

***************************************

 

* Running VLC as root is discouraged. *

 

***************************************

 

It is potentially dangerous, and might not even work properly.

vlc: page allocation failure. order:7, mode:0x40d0

Hardware Trace:

 

   0 Target : <0x00004ab8> { _dump_stack + 0x0 }

     Source : <0x0002df4a> { ___alloc_pages_internal + 0x1b2 } CALL pcrel

   1 Target : <0x0002df4a> { ___alloc_pages_internal + 0x1b2 }

     Source : <0x0000d722> { _printk + 0x16 } RTS

   2 Target : <0x0000d71e> { _printk + 0x12 }

     Source : <0x0000df94> { _vprintk + 0x130 } RTS

   3 Target : <0x0000df88> { _vprintk + 0x124 }

     Source : <0xffa00bbc> { __common_int_entry + 0xd8 }

   4 Target : <0xffa00b5a> { __common_int_entry + 0x76 }

     Source : <0xffa009a4> { _return_from_int + 0x58 }

   5 Target : <0xffa009a4> { _return_from_int + 0x58 }

     Source : <0xffa0097a> { _return_from_int + 0x2e }

   6 Target : <0xffa0094c> { _return_from_int + 0x0 }

     Source : <0xffa00b56> { __common_int_entry + 0x72 }

   7 Target : <0xffa00b54> { __common_int_entry + 0x70 }

     Source : <0xffa0035a> { _asm_do_IRQ + 0x6e }

   8 Target : <0xffa00352> { _asm_do_IRQ + 0x66 }

     Source : <0x000114c6> { __local_bh_enable + 0x3e } RTS

   9 Target : <0x00011488> { __local_bh_enable + 0x0 }

     Source : <0x000115b0> { ___do_softirq + 0xa0 } JUMP.L

  10 Target : <0x000115a8> { ___do_softirq + 0x98 }

     Source : <0x0001158c> { ___do_softirq + 0x7c } IF !CC JUMP

  11 Target : <0x0001156e> { ___do_softirq + 0x5e }

     Source : <0x00028c88> { _rcu_process_callbacks + 0x30 } RTS

  12 Target : <0x00028c84> { _rcu_process_callbacks + 0x2c }

     Source : <0x00028bbe> { ___rcu_process_callbacks + 0x132 } RTS

  13 Target : <0x00028bb8> { ___rcu_process_callbacks + 0x12c }

     Source : <0x00028b42> { ___rcu_process_callbacks + 0xb6 } IF !CC JUMP

  14 Target : <0x00028b3c> { ___rcu_process_callbacks + 0xb0 }

     Source : <0x00028bc4> { ___rcu_process_callbacks + 0x138 } IF CC JUMP

  15 Target : <0x00028bc0> { ___rcu_process_callbacks + 0x134 }

     Source : <0x00028b2e> { ___rcu_process_callbacks + 0xa2 } IF !CC JUMP

 

Stack info:

SP: [0x00265df8] <0x00265df8> /* kernel dynamic memory */

FP: (0x00265e78)

Memory from 0x00265df0 to 00266000

 

00265df0: 00265df8 <0002df22>[00abb080]<0002df4e> 00abb080  00000000  000240d0  00abb268

00265e10: 00000007  000040d0  00000001  00000048  00264000  00264000  00000000  000240d0

00265e30: 00264000  00000010  00000000  00000000  00000000  00000000  00311440 <0002e072>

00265e50: 00ac36a0  00075890  00076000  ffffffda  00000002  00000000  00000005 <00035488>

00265e70: 00ac36a0  00000004 (00000000)<00035696> 4acbe054  00000000  00000000  00000002

00265e90: 00000000  00000000  00000000  000000f5  00000000  008e2a00  00000001  00001000

00265eb0: 00001000  0063f888 <000038f0> 00000000  00075890  0017e688  00264000  00000002

00265ed0: 00ac36a0  00000005  00001000  00000000  00000000  00000005  00000002  00000000

00265ef0: ffa00818  000038a8  000000c0  00000000  ffffe000  00000000  00000005 <0060f5d8>

00265f10: 008b5868  00324403  00001802  00000005  00000000  0017b49c  00008000  00000000

00265f30: 00000000  00266000  0017b49c  0017b49c <0017ac68> ffa00d80  02002020  0066596b

00265f50: 0089f78f  0066596a  0089f786  00000000  00000007  00000000  00000000  00000000

00265f70: 00000000  00000000  00000000  00000000  00000000  00000000  00000000  00000000

00265f90: 00000000  00000000  00000000  00000000  00000000  00000000  00000000  002c1940

00265fb0: 00000000  0063f73c  0063f888  003f9188  009a6034  0017e688  00000000  00000001

00265fd0: 000000c0  00000001  00000001  00000000  00000005  00001802  00000005  00075890

00265ff0: 00000000  00000000  000000c0  00000006

 

Return addresses in stack:

    address : <0x0002df22> { ___alloc_pages_internal + 0x18a }

    address : <0x0002df4e> { ___alloc_pages_internal + 0x1b6 }

    address : <0x0002e072> { ___get_free_pages + 0x1e }

    address : <0x00035488> { _do_mmap_pgoff + 0x3a4 }

   frame  1 : <0x00035696> { _do_mmap_pgoff + 0x5b2 }

    address : <0x000038f0> { _sys_mmap2 + 0x48 }

    address : <0x0060f5d8> [ /usr/bin/vlc + 0x1755d8 ]

    address : <0x0017ac68> { _ip_rt_init + 0x80 }

 

Mem-Info:

DMA per-cpu:

CPU    0: hi:    0, btch:   1 usd:   0

 

Active_anon:0 active_file:3 inactive_anon:0

 

inactive_file:8 dirty:2 writeback:0 unstable:0

 

free:423 slab:286 mapped:0 pagetables:0 bounce:0

 

DMA free:1692kB min:420kB low:524kB high:628kB active_anon:0kB inactive_anon:0kB active_file:12kB inactive_file:32kB present:11176kB pages_scanned:0 all_unreclo

 

lowmem_reserve[]: 0 0 0

 

DMA: 45*4kB 37*8kB 20*16kB 10*32kB 3*64kB 1*128kB 1*256kB 0*512kB 0*1024kB 0*2048kB 0*4096kB 0*8192kB 0*16384kB 0*32768kB = 1692kB

 

11 total pagecache pages

2816 pages RAM

429 pages reserved

9 pages shared

1940 pages non-shared

Allocation of length 483328 from process 33 failed

 

The entire output is much bigger than this, but it seems that it's trying to make several allocations, all failing. You can see the complete output in the attached vlc_output.txt

 

It seems that even if the board has 32Mb of RAM, the uClinux kernel is only having ~10Mb to work:

 

root:/> cat /proc/meminfo

MemTotal:           9548 kB

MemFree:            6284 kB

Buffers:              48 kB

Cached:              140 kB

SwapCached:            0 kB

Active:               40 kB

Inactive:            104 kB

Active(anon):          0 kB

Inactive(anon):        0 kB

Active(file):         40 kB

Inactive(file):      104 kB

SwapTotal:             0 kB

SwapFree:              0 kB

Dirty:                 0 kB

Writeback:             0 kB

AnonPages:             0 kB

Mapped:                0 kB

Slab:               1060 kB

SReclaimable:        616 kB

SUnreclaim:          444 kB

PageTables:            0 kB

NFS_Unstable:          0 kB

Bounce:                0 kB

WritebackTmp:          0 kB

CommitLimit:        4772 kB

Committed_AS:          0 kB

VmallocTotal:          0 kB

VmallocUsed:           0 kB

VmallocChunk:          0 kB

 

The stock Bluetechnix kernel showed ~25Mb of free memory, which makes me think that something is wrong with my kernel configuration.

 

I also attached the output from the boot process (please see the attached boot_output.txt).

 

Can someone help me?

 

Thanks in advance,

 

Rafael

 

boot_output.txt

vlc_output.txt

QuoteReplyEditDelete

 

 

2009-10-07 00:25:47     Re: BF537 Bluetechnix wrong memory display

Mike Frysinger (UNITED STATES)

Message: 80915   

 

read the memory map shown at boot:

  available = 0x00186000-0x00b00000

 

that is all the free memory you've configured your system for.  if you read further you see you've told the system to reserve quite a bit for your ext2 root via the uClinux MTD:

  rootfs    = 0x00b00000-0x01f00000

 

you probably want to pick a rootfs that doesnt suck up the memory

Attachments

    Outcomes