2011-05-17 07:42:56     uclinux Boot Time problem

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

2011-05-17 07:42:56     uclinux Boot Time problem

khushi q (PAKISTAN)

Message: 100693   




I am working on a custom BF537 board. currently the uClinux Boot time exceeds 40 sec on my board ... and i really need to take down to almost 15 - 20 sec  ..Most time is spent on the scanning of Nand for Bad Blocks, which happens every time taking more than 25 secs even though the BBT is updated and present .. somehow it the kernel is unable to find the BBT.


bfin-gpio: GPIO 3 is already reserved as Peripheral by bfin-uart !            

bio: create slab <bio-0> at 0                                                 

bfin-spi bfin-spi.0: Blackfin on-chip SPI Controller Driver, Version 1.0, regs_7

Advanced Linux Sound Architecture Driver Version 1.0.23.                      

Switching to clocksource bfin_cs_cycles                                       

NET: Registered protocol family 2                                             

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

TCP established hash table entries: 4096 (order: 3, 32768 bytes)              

TCP bind hash table entries: 4096 (order: 2, 16384 bytes)                     

TCP: Hash tables configured (established 4096 bind 4096)                      

TCP reno registered                                                           

UDP hash table entries: 256 (order: 0, 4096 bytes)                            

UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)                       

NET: Registered protocol family 1                                             

debug-mmrs: setting up Blackfin MMR debugfs                                   

fuse init (API version 7.16)                                                  

msgmni has been set to 230                                                    

io scheduler noop registered (default)                                        

bfin-uart: Blackfin serial driver                                             

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

bfin-uart.1: ttyBF1 at MMIO 0xffc02000 (irq = 20) is a BFIN-UART              

brd: module loaded                                                            

ONFI flash detected                                                           

ONFI param page 0 valid                                                       

NAND device: Manufacturer ID: 0x2c, Chip ID: 0xda (Micron MT29F2G08AAD)       

Scanning device for bad blocks                                         

RedBoot partition parsing not available                                       

Creating 2 MTD partitions on "gen_nand":                                      

0x000000000000-0x000002000000 : "linux kernel(nand)"                          

0x000002000000-0x000010000000 : "file system(nand)"                           

bfin_mii_bus: probed                                                          

bfin_mac: attached PHY driver [Generic PHY] (mii_bus:phy_addr=0:01, irq=-1, mdc)

bfin_mac bfin_mac.0: eth0: Blackfin on-chip Ethernet MAC driver, Version 1.1  

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

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

SoftDog: cannot register miscdev on minor=130 (err=-16)                       

dma rx:3 tx:4, err irq:45, regs:ffc00800                                      

dma_alloc_init: dma_page @ 0x04ae5000 - 256 pages at 0x07f00000               

asoc: ad73311-hifi <-> bfin-i2s.0 mapping ok                                  

ALSA device list:                                                             

  #0: bf5xx_ad73311




2011-05-17 13:12:46     Re: uclinux Boot Time problem

Mike Frysinger (UNITED STATES)

Message: 100699   


how exactly do you specify the BBT ?  show the exact platform resources you're using with the plat_nand driver.




2011-05-18 01:18:18     Re: uclinux Boot Time problem

khushi q (PAKISTAN)

Message: 100707   


probably my new changes bypasses the BBT made in the nand.. right now i haven't done changes in the nand_bbt.c


to get my nand device detected i changed a few things in the stamp.c


static struct mtd_partition bfin_plat_nand_partitions[] = {


        .name   = "linux kernel(nand)",

        .size   = 0x2000000,

        .offset = 0,

    }, {

        .name   = "file system(nand)",

        .size   = MTDPART_SIZ_FULL,

        .offset = MTDPART_OFS_APPEND,







static struct resource bfin_plat_nand_resources = {

    .start = 0x20000000,

    .end   = 0x20000000 + (1 << MAX(BFIN_NAND_PLAT_CLE, BFIN_NAND_PLAT_ALE)),

    .flags = IORESOURCE_MEM,



am i missing something here ?...




2011-05-18 01:48:20     Re: uclinux Boot Time problem

Mike Frysinger (UNITED STATES)

Message: 100708   


you should be creating your own boards file rather than modifying an existing one


the bf537-stamp file does not tell the nand layer to use a flash based bbt ... this is by design.  if your flash has a bbt in it, then you have to delcare it as such by using NAND_USE_FLASH_BBT in platform_nand_chip.options.