Forums

Reducing Boot-up time (Removing unnecessary start-up items)

This question is not answered

My Leopardboard 368 with default Ridgerun SDk takes about 22 seconds to boot up. 

This time is the interval between the first message appearing on the serial port: "Starting NAND Copy... " to the last one: "Please press Enter to activate this console."

I would like to reduce the start-up time.  So first we need to know the time each items takes.

I have used Grabserial tool (http://elinux.org/Grabserial) to add a time-stamp to every line of the boot log.
Here is a few lines of the log to make things more clear:

[0.000000 0.000000] NAND
[0.674233 0.674233] Starting NAND Copy...
[0.674466 0.000233] Valid magicnum, 0xA1ACED66, found in block 0x00000019.
[0.771117 0.096651]
[0.771162 0.000045]
[0.771177 0.000015] U-Boot 2010.12-rc2 (May 27 2012 - 14:09:05)
[0.779266 0.008089]
[0.779287 0.000021] Cores: ARM 446 MHz
[0.779476 0.000189] DDR: 351 MHz
[0.779627 0.000151] I2C: ready
[0.835012 0.055385] DRAM: 128 MiB
[0.855120 0.020108] NAND: 256 MiB
[0.855295 0.000175] MMC: davinci: 0, davinci: 1
[1.135183 0.279888] Net: Ethernet PHY: GENERIC @ 0x00
[1.155282 0.020099] DaVinci-EMAC
[1.155421 0.000139] Hit any key to stop autoboot: 3 2 1 0
[4.310546 3.155125]
[4.310571 0.000025] Loading from nand0, offset 0x400000
[4.310925 0.000354] Image Name: "RR Linux Kernel"
[4.995616 0.003991] Load Address: 80008000
[4.999388 0.003772] Entry Point: 80008000
[4.999650 0.000262] Verifying Checksum ... OK
[5.865063 0.865413] Loading Kernel Image ... OK
[6.865122 1.000059] OK
[6.865177 0.000055]
[6.865192 0.000015] Starting kernel ...
[6.875130 0.009938]
[8.239525 1.364395] Linux version 2.6.32-17-ridgerun (moza@moza-pc) (gcc version 4.3.3 (Sourcery G++ Lite 2009q1-203) ) #26 [8.259768 0.004052] Machine: DM365 Leopard
[8.263579 0.003811] Memory policy: ECC disabled, Data cache writeback
[8.267600 0.004021] DaVinci dm36x_rev1.2 variant 0x8
[8.271475 0.003875] Built 1 zonelists in Zone order, mobility grouping off. Total pages: 17526
[8.325535 0.006006] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[8.363702 0.003029] CPU: Testing write buffer coherency: ok
[8.399849 0.000278] LogicPD encoder initialized
[8.483827 0.004246] davincifb davincifb.0: dm_vid1_fb: 0x0x16@0,0 with framebuffer size 1020KB
[8.499905 0.000314] Serial: 8250/16550 driver, 2 ports, IRQ sharing disabled
[8.507585 0.007680] serial8250.0: ttyS0 at MMIO 0x1c20000 (irq = 40) is a 16550A
[8.552007 0.000292] NAND device: Manufacturer ID: 0x2c, Chip ID: 0xda (Micron NAND 256MiB 3,3V 8-bit)
[8.553122 0.001115] Scanning device for bad blocks
[8.687679 0.004042] vpfe-capture vpfe-capture: video device registered
[8.695470 0.007791] tvp514x 1-005d: tvp514x 1-005d decoder driver registered !!
[8.699934 0.004464] vpfe-capture vpfe-capture: v4l2 sub device tvp5146 registered
[8.784880 0.000370] No device for DAI davinci-i2s
[8.791539 0.006659] asoc: tlv320aic3x <-> davinci-i2s mapping ok
[8.831552 0.003783] Clocks: disable unused spi1
[8.847760 0.003852] Clocks: disable unused pwm3
[8.851617 0.003857] Clocks: disable unused timer1
[8.915489 0.007640] mmcblk0: mmc0:b368 NCard 7.47 GiB
[8.919984 0.004495] mmcblk0:
[10.399958 1.479974] Sending DHCP requests ., OK
[10.995675 0.595717] IP-Config: Got DHCP answer from 192.168.0.1, my address is 192.168.0.100
[11.003629 0.007954] IP-Config: Complete:
[11.089905 0.005063] Freeing init memory: 136K
[11.584862 0.045022] starting pid 954, tty '': '/etc/rcS'
[13.064810 1.479948] Starting System
[19.889681 6.824871] done.
[20.040065 0.150384] Welcome to
....
[20.673148 0.462614] Loading coprocessors modules...
[20.961297 0.288149] Loading cmem from 0x84e00000 to 0x88000000
[21.039581 0.078284] CMEMK module: built on Dec 10 2011 at 16:05:15
[21.759550 0.156407] Starting Dropbear SSH server: dropbear.
[22.363426 0.000066] Please press Enter to activate this console.

I have highlighted bulky items in the list above.

As you can see, the most expensive one is between "Starting System." and "Welcome to". I do not know what is happening during that period. 

How can we reduce the startup time? Any suggestions?

Morteza

All Replies
  • I have also tried disabling unused programs, setting boot from JFFS2, but boot-up time is still around 22 seconds.

    Any tip?

    Anyone? :)

  • Hi everyone!

    Is it possible to list the Items which run after the "Starting System" phase? I really need to know the time, each item takes.

    Morteza