Article [#3846] kernel boot message: memory information not reasonable

[#3846] kernel boot message: memory information not reasonable

Submitted By: Yi Li

Open Date

2008-01-22 00:47:07     Close Date

2008-02-01 02:03:36

Priority:

Medium     Assignee:

Yi Li

Status:

Closed     Fixed In Release:

N/A

Found In Release:

N/A     Release:

svn trunk

Category:

Memory     Board:

STAMP

Processor:

N/A     Silicon Revision:

Is this bug repeatable?:

Yes     Resolution:

Fixed

Uboot version or rev.:

    Toolchain version or rev.:

svn trunk

App binary format:

N/A     

Summary: kernel boot message: memory information not reasonable

Details:

Some of the information in kernel boot message is not reasonable.

Follow-ups

--- Mike Frysinger                                           2008-01-22 03:01:39

for example ... ?

--- Yi Li                                                    2008-01-22 03:04:59

bellow is an sample boot message:

bf537> bootm

## Booting image at 02000000 ...

   Image Name:   Linux-2.6.22.16-ADI-2007R2-pre-s

   Created:      2008-01-22   7:51:10 UTC

   Image Type:   Blackfin Linux Kernel Image (gzip compressed)

   Data Size:    3196270 Bytes =  3 MB

   Load Address: 00001000

   Entry Point:  00150000

   Verifying Checksum ... OK

   Uncompressing Kernel Image ... OK

Starting Kernel at = 150000

Linux version 2.6.22.16-ADI-2007R2-pre-svn4131 (adam@adam-ubuntu-desk) (gcc

version 4.1.2 (ADI svn)) #10 Tue Jan 22 15:51:05 CST 2008

Hardware Trace Active and Enabled

Warning: limiting memory to 56MB due to hardware anomaly 05000263

Blackfin support (C) 2004-2007 Analog Devices, Inc.

Compiled for ADSP-BF537 Rev 0.2

Blackfin Linux support by   blackfin.uclinux.org/

Processor Speed: 500 MHz core clock and 100 MHz System Clock

Board Memory: 64MB

Kernel Managed Memory: 64MB

Memory map:

  text      = 0x00001000-0x000f73a0

  rodata    = 0x000f8000-0x0013ef14

  data      = 0x0013f000-0x00150000

    stack   = 0x00140000-0x00142000

  init      = 0x00150000-0x00630000

  bss       = 0x00630000-0x0063ef10

  available = 0x0063ef10-0x037ff000

  DMA Zone  = 0x03f00000-0x04000000

Instruction Cache Enabled

Data Cache Enabled (write-through)

Built 1 zonelists.  Total pages: 14224

Kernel command line: console=ttyBF0,57600

Configuring Blackfin Priority Driven Interrupts

PID hash table entries: 256 (order: 8, 1024 bytes)

bfin-rtc: invalid date; resetting

Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)

Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)

Physical pages: 37ff

Memory available: 50308k/64260k RAM, (4992k init code, 984k kernel code, 59k

data, 1024k dma)

Blackfin Scratchpad data SRAM: 4 KB

Blackfin Data A SRAM: 16 KB (15 KB free)

Blackfin Data B SRAM: 16 KB (16 KB free)

Blackfin Instruction SRAM: 48 KB (39 KB free)

Security Framework v1.0.0 initialized

Mount-cache hash table entries: 512

NET: Registered protocol family 16

Blackfin GPIO Controller

Blackfin DMA Controller

stamp_init(): registering device resources

Generic PHY: Registered new driver

IP route cache hash table entries: 1024 (order: 0, 4096 bytes)

TCP established hash table entries: 2048 (order: 2, 16384 bytes)

TCP bind hash table entries: 2048 (order: 1, 8192 bytes)

TCP: Hash tables configured (established 2048 bind 2048)

TCP reno registered

io scheduler noop registered

io scheduler anticipatory registered (default)

io scheduler cfq registered

Dynamic Power Management Controller Driver v0.1: major=10, minor = 254

bfin-wdt: initialized: timeout=20 sec (nowayout=0)

Serial: Blackfin serial driver

bfin-uart.1: ttyBF0 at MMIO 0xffc00400 (irq = 18) is a BFIN-UART

RAMDISK driver initialized: 16 RAM disks of 4096K size 1024 blocksize

SMSC LAN83C185: Registered new driver

bfin_mac_mdio: probed

bfin_mac: attached PHY driver [SMSC LAN83C185] (mii_bus:phy_addr=0:01, irq=-1,

mdc_clk=2500000Hz(mdc_div=19)@sclk=100MHz)

bfin_mac: Version 1.1, Blackfin BF53[67] BF527 on-chip Ethernet MAC driver

bfin-spi bfin-spi.0: Blackfin BF5xx on-chip SPI Contoller Driver, Version 1.0,

regs_base@ffc00500, dma channel@7

rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0

TCP cubic registered

NET: Registered protocol family 1

NET: Registered protocol family 17

rtc-bfin rtc-bfin: setting the system clock to 1970-01-01 00:00:01 (1)

Freeing unused kernel memory: 4992k freed

dma_alloc_init: dma_page @ 0x0062d000 - 256 pages at 0x03f00000

--- Yi Li                                                    2008-01-22 03:29:30

Here are messages not considered reasonable:

- "Physical pages: 37ff"

In other places: "Built 1 zonelists.  Total pages: 14224" and

"256 pages at 0x03f00000". Page number all in Dec format. I think

there is no reason to use Hex format "37ff", and it may be confusing

sometime.

- Memory available: 50308k/64260k RAM

"50308k" is nr_free_pages(). (It looks not including the pages in

per-cpu-page pools).

"64260K" is calculated as: (_ramend - _rambase) >> 10. _rambase

is the start of .data section. It is unreasonable. I am thinking it should be

calculated as "(_memory_end >> 10) = 57340K", or "(_ramend

>> 10)" if counting uncached dma region.

- "(4992k init code, 984k kernel code, 59k data, 1024k dma)"

"59k data" is calculated as "(__bss_stop - __bss_start) >>

10", this is not correct.

--- Yi Li                                                    2008-01-23 01:23:30

This is the boot message after fixing:

Kernel managed physical pages: 14335                                          

                                   

Memory available: 50308k/65536k RAM, (4992k init code, 984k kernel code, 415k

data, 1024k dma, 7748k reserved)

50308 + 4992 + 984 + 415 + 1024 + 7748 = 65471

65536K - 65471K = 65K

I think 65K memory includes the first 4K page for trap null pointer, also the

pages in per-cpu-page cache.

bf537> bootm                                                               

                                      

## Booting image at 02000000 ...                                              

                                   

   Image Name:   Linux-2.6.22.16-ADI-2007R2-pre-s                             

                                   

   Created:      2008-01-23   5:47:16 UTC                                     

                                   

   Image Type:   Blackfin Linux Kernel Image (gzip compressed)                

                                   

   Data Size:    3196270 Bytes =  3 MB                                        

                                   

   Load Address: 00001000                                                     

                                   

   Entry Point:  00150000                                                     

                                   

   Verifying Checksum ... OK                                                  

                                   

   Uncompressing Kernel Image ... OK                                          

                                   

Starting Kernel at = 150000                                                   

                                   

Linux version 2.6.22.16-ADI-2007R2-pre-svn4131 (adam@adam-ubuntu-desk) (gcc

version 4.1.2 (ADI svn)) #25 Wed Jan 238

Hardware Trace Active and Enabled                                             

                                   

Warning: limiting memory to 56MB due to hardware anomaly 05000263             

                                   

Blackfin support (C) 2004-2007 Analog Devices, Inc.                           

                                   

Compiled for ADSP-BF537 Rev 0.2                                               

                                   

Blackfin Linux support by   blackfin.uclinux.org/                        

                                   

Processor Speed: 500 MHz core clock and 100 MHz System Clock                  

                                   

Board Memory: 64MB                                                            

                                   

Kernel Managed Memory: 64MB                                                   

                                   

Memory map:                                                                   

                                   

  text      = 0x00001000-0x000f73a0                                           

                                   

  rodata    = 0x000f8000-0x0013ef34                                           

                                   

  data      = 0x0013f000-0x00150000                                           

                                   

    stack   = 0x00140000-0x00142000                                           

                                   

  init      = 0x00150000-0x00630000                                           

                                   

  bss       = 0x00630000-0x0063ef10                                           

                                   

  available = 0x0063ef10-0x037ff000                                           

                                   

  DMA Zone  = 0x03f00000-0x04000000                                           

                                   

On node 0 totalpages: 14335                                                   

                                   

  DMA zone: 111 pages used for memmap                                         

                                   

  DMA zone: 0 pages reserved                                                  

                                   

  DMA zone: 14224 pages, LIFO batch:3                                         

                                   

  Normal zone: 0 pages used for memmap                                        

                                   

Instruction Cache Enabled                                                     

                                   

Data Cache Enabled (write-through)                                            

                                   

Built 1 zonelists.  Total pages: 14224                                        

                                   

Kernel command line: debug                                                    

                                   

Configuring Blackfin Priority Driven Interrupts                               

                                   

PID hash table entries: 256 (order: 8, 1024 bytes)                            

                                   

Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)                 

                                   

Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)                  

                                   

Kernel managed physical pages: 14335                                          

                                   

Memory available: 50308k/65536k RAM, (4992k init code, 984k kernel code, 415k

data, 1024k dma, 7748k reserved)     

Blackfin Scratchpad data SRAM: 4 KB                                           

                                   

Blackfin Data A SRAM: 16 KB (15 KB free)                                      

                                   

Blackfin Data B SRAM: 16 KB (16 KB free)                                      

                                   

Blackfin Instruction SRAM: 48 KB (39 KB free)                                 

                                   

Calibrating delay loop... 997.37 BogoMIPS (lpj=1994752)                       

                                   

Security Framework v1.0.0 initialized                                         

                                   

Mount-cache hash table entries: 512                                           

                                   

NET: Registered protocol family 16                                            

                                   

Blackfin GPIO Controller                                                      

                                   

Blackfin DMA Controller                                                       

                                   

stamp_init(): registering device resources                                    

                                   

Generic PHY: Registered new driver                                            

                                   

NET: Registered protocol family 2                                             

                                   

IP route cache hash table entries: 1024 (order: 0, 4096 bytes)                

                                   

TCP established hash table entries: 2048 (order: 2, 16384 bytes)              

                                   

TCP bind hash table entries: 2048 (order: 1, 8192 bytes)                      

                                   

TCP: Hash tables configured (established 2048 bind 2048)                      

                                   

TCP reno registered                                                           

                                   

io scheduler noop registered                                                  

                                   

io scheduler anticipatory registered (default)                                

                                   

io scheduler cfq registered                                                   

                                   

Dynamic Power Management Controller Driver v0.1: major=10, minor = 254        

                                   

bfin-wdt: initialized: timeout=20 sec (nowayout=0)                            

                                   

Serial: Blackfin serial driver                                                

                                   

bfin-uart.1: ttyBF0 at MMIO 0xffc00400 (irq = 18) is a BFIN-UART              

                                   

RAMDISK driver initialized: 16 RAM disks of 4096K size 1024 blocksize         

                                   

SMSC LAN83C185: Registered new driver                                         

                                   

bfin_mac_mdio: probed                                                         

                                   

bfin_mac: attached PHY driver [SMSC LAN83C185] (mii_bus:phy_addr=0:01, irq=-1,

mdc_clk=2500000Hz(mdc_div=19)@sclk=1)

bfin_mac: Version 1.1, Blackfin BF53[67] BF527 on-chip Ethernet MAC driver    

                                   

bfin-spi bfin-spi.0: Blackfin BF5xx on-chip SPI Contoller Driver, Version 1.0,

regs_base@ffc00500, dma channel@7   

rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0                      

                                   

TCP cubic registered                                                          

                                   

NET: Registered protocol family 1                                             

                                   

NET: Registered protocol family 17                                            

                                   

Setting up Blackfin MMR debugfs                                               

                                   

rtc-bfin rtc-bfin: setting the system clock to 1970-01-01 03:40:06 (13206)    

                                   

Freeing unused kernel memory: 4992k freed                                     

                                   

dma_alloc_init: dma_page @ 0x0062d000 - 256 pages at 0x03f00000        

--- Yi Li                                                    2008-01-23 05:09:05

after the new fix, the boot message looks like:

Kernel managed physical pages: 14335                                          

                                   

Memory available: 50368k/65536k RAM, (4992k init code, 984k kernel code, 415k

data, 1024k dma, 7756k reserved)     

50368+4992+984+415+1024+7756 = 65539K, given one-page (4K) error, it matches

total memory 65536K.

----------

bf537> bootm                                                               

                                      

## Booting image at 02000000 ...                                              

                                   

   Image Name:   Linux-2.6.22.16-ADI-2007R2-pre-s                             

                                   

   Created:      2008-01-23  10:09:33 UTC                                     

                                   

   Image Type:   Blackfin Linux Kernel Image (gzip compressed)                

                                   

   Data Size:    3196267 Bytes =  3 MB                                        

                                   

   Load Address: 00001000                                                     

                                   

   Entry Point:  00150000                                                     

                                   

   Verifying Checksum ... OK                                                  

                                   

   Uncompressing Kernel Image ... OK                                          

                                   

Starting Kernel at = 150000                                                   

                                   

Linux version 2.6.22.16-ADI-2007R2-pre-svn4131 (adam@adam-ubuntu-desk) (gcc

version 4.1.2 (ADI svn)) #53 Wed Jan 238

Hardware Trace Active and Enabled                                             

                                   

Warning: limiting memory to 56MB due to hardware anomaly 05000263             

                                   

Blackfin support (C) 2004-2007 Analog Devices, Inc.                           

                                   

Compiled for ADSP-BF537 Rev 0.2                                               

                                   

Blackfin Linux support by   blackfin.uclinux.org/                        

                                   

Processor Speed: 500 MHz core clock and 100 MHz System Clock                  

                                   

Board Memory: 64MB                                                            

                                   

Kernel Managed Memory: 64MB                                                   

                                   

Memory map:                                                                   

                                   

  text      = 0x00001000-0x000f73a0                                           

                                   

  rodata    = 0x000f8000-0x0013ef34                                           

                                   

  data      = 0x0013f000-0x00150000                                           

                                   

    stack   = 0x00140000-0x00142000                                           

                                   

  init      = 0x00150000-0x00630000                                           

                                   

  bss       = 0x00630000-0x0063ef10                                           

                                   

  available = 0x0063ef10-0x037ff000                                           

                                   

  DMA Zone  = 0x03f00000-0x04000000                                           

                                   

On node 0 totalpages: 14335                                                   

                                   

  DMA zone: 111 pages used for memmap                                         

                                   

  DMA zone: 0 pages reserved                                                  

                                   

  DMA zone: 14224 pages, LIFO batch:3                                         

                                   

  Normal zone: 0 pages used for memmap                                        

                                   

Instruction Cache Enabled                                                     

                                   

Data Cache Enabled (write-through)                                            

                                   

Built 1 zonelists.  Total pages: 14224                                        

                                   

Kernel command line: debug                                                    

                                   

Configuring Blackfin Priority Driven Interrupts                               

                                   

PID hash table entries: 256 (order: 8, 1024 bytes)                            

                                   

Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)                 

                                   

Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)                  

                                   

Kernel managed physical pages: 14335                                          

                                   

Memory available: 50368k/65536k RAM, (4992k init code, 984k kernel code, 415k

data, 1024k dma, 7756k reserved)     

Blackfin Scratchpad data SRAM: 4 KB                                           

                                   

Blackfin Data A SRAM: 16 KB (15 KB free)                                      

                                   

Blackfin Data B SRAM: 16 KB (16 KB free)                                      

                                   

Blackfin Instruction SRAM: 48 KB (39 KB free)                                 

                                   

Calibrating delay loop... 997.37 BogoMIPS (lpj=1994752)                       

                                   

Security Framework v1.0.0 initialized                                         

                                   

Mount-cache hash table entries: 512                                           

                                   

NET: Registered protocol family 16                                            

                                   

Blackfin GPIO Controller                                                      

                                   

Blackfin DMA Controller                                                       

                                   

stamp_init(): registering device resources                                    

                                   

Generic PHY: Registered new driver                                            

                                   

NET: Registered protocol family 2                                             

                                   

IP route cache hash table entries: 1024 (order: 0, 4096 bytes)                

                                   

TCP established hash table entries: 2048 (order: 2, 16384 bytes)              

                                   

TCP bind hash table entries: 2048 (order: 1, 8192 bytes)                      

                                   

TCP: Hash tables configured (established 2048 bind 2048)                      

                                   

TCP reno registered                                                           

                                   

io scheduler noop registered                                                  

                                   

io scheduler anticipatory registered (default)                                

                                   

io scheduler cfq registered                                                   

                                   

Dynamic Power Management Controller Driver v0.1: major=10, minor = 254        

                                   

bfin-wdt: initialized: timeout=20 sec (nowayout=0)                            

                                   

Serial: Blackfin serial driver                                                

                                   

bfin-uart.1: ttyBF0 at MMIO 0xffc00400 (irq = 18) is a BFIN-UART              

                                   

RAMDISK driver initialized: 16 RAM disks of 4096K size 1024 blocksize         

                                   

SMSC LAN83C185: Registered new driver                                         

                                   

bfin_mac_mdio: probed                                                         

                                   

bfin_mac: attached PHY driver [SMSC LAN83C185] (mii_bus:phy_addr=0:01, irq=-1,

mdc_clk=2500000Hz(mdc_div=19)@sclk=1)

bfin_mac: Version 1.1, Blackfin BF53[67] BF527 on-chip Ethernet MAC driver    

                                   

bfin-spi bfin-spi.0: Blackfin BF5xx on-chip SPI Contoller Driver, Version 1.0,

regs_base@ffc00500, dma channel@7   

rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0                      

                                   

TCP cubic registered                                                          

                                   

NET: Registered protocol family 1                                             

                                   

NET: Registered protocol family 17                                            

                                   

Setting up Blackfin MMR debugfs                                               

                                   

rtc-bfin rtc-bfin: setting the system clock to 1970-01-01 06:07:20 (22040)    

                                   

Freeing unused kernel memory: 4992k freed                                     

                                   

dma_alloc_init: dma_page @ 0x0062d000 - 256 pages at 0x03f00000        

--- Yi Li                                                    2008-02-01 04:08:59

fixed and patch in both branch and 2008r1 - close.

    Files

    Changes

    Commits

    Dependencies

    Duplicates

    Associations

    Tags

File Name     File Type     File Size     Posted By

No Files Were Found

Before You Switch


Switching languages will make ADI Explorer unavailable. Resume your session by switching back to English and reopening ADI Explorer.