• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>

            攀升·Uranus


            Something Different,Something New
            數據加載中……

            Linux Kernel Image: initialize

            1. 編譯kernel  
                  編譯linux時其實會又很多產物,因為android讓我接觸了linux 內核的一些資料。

            貼最后一段make的Log
            $ make ARCH=arm CROSS_COMPILE=/dev/.....
            ...   < many build steps omitted for clarity>
              LD          vmlinux                                                  Kernel proper,EFL format,最原始的kernel
              SYSMAP      System.map                                 
              OBJCOPY     arch/arm/boot/Image                     去掉 symbols, notes, and comments.
              Kernel:     arch/arm/boot/Image is ready                objcopy to generate a binary file, Image   
              AS          arch/arm/boot/compressed/head.o         ARM-specific startup code generic to ARM processors,與arm相關的一些重要的啟動時要用
              GZIP        arch/arm/boot/compressed/piggy.gz      gzip打包
              AS          arch/arm/boot/compressed/piggy.o        加載piggy.S,initializes the processor,required memory regions
              CC          arch/arm/boot/compressed/misc.o        Routines used for decompressing the kernel image 
              AS          arch/arm/boot/compressed/head-xscale.o   
              AS          arch/arm/boot/compressed/big-endian.o
              LD          arch/arm/boot/compressed/vmlinux         這容易搞亂,這個vmlinux和第一個Kernel proper是不一樣的。
              OBJCOPY     arch/arm/boot/zImage                     Final composite kernel image,loaded by bootload.
              Kernel:     arch/arm/boot/zImage is ready
            boot-strap Loader :misc.o head-xscale.o big-endian.o

            2. Initialization
                Power on-> bootloader ->head-xscale.o(boot-strap )-> head.o(vmlinux)->main.o(kernel)

            3. start_kernel();
               啟動Init()process.init初始化之前注冊的函數,最后釋放資源。內核級別啟動常報的錯就是“No init found.  Try passing init= option to kernel”
            這主要是因為通過run_init_process執行系統級別的/init時失敗,返回。如果成功,該函數不會返回。
            if (execute_command) {
            run_init_process(execute_command);
            printk(KERN_WARNING "Failed to execute %s.  Attempting "
            "defaults...\n", execute_command);
            }
            run_init_process("/sbin/init");
            run_init_process("/etc/init");
            run_init_process("/bin/init");
            run_init_process("/bin/sh");
            panic("No init found.  Try passing init= option to kernel.");

            PS:
            start_kernel(): .../init/main.c 
            Most of the Linux kernel initialization takes place in this routine
            setup_arch(&command_line):  start_kernel() function is the call to setup_arch(), .../arch/arm/kernel/setup.c

            posted on 2009-07-11 17:40 攀升 閱讀(1593) 評論(2)  編輯 收藏 引用 所屬分類: Linux

            評論

            # re: Linux Kernel Image: initialize  回復  更多評論   

            bucuo,收藏一下啦
            2009-07-11 18:40 | 99網上書城

            # re: Linux Kernel Image: initialize  回復  更多評論   

            樓上的不要起哄!
            2009-07-12 23:50 | 小米
            久久噜噜电影你懂的| 国产成人无码精品久久久性色| 香蕉久久夜色精品升级完成| 国产精品美女久久久久| 久久夜色撩人精品国产小说| 色综合久久中文字幕无码| 日产精品久久久一区二区| 一本久久综合亚洲鲁鲁五月天| 国产精品久久久久影视不卡| 亚洲精品NV久久久久久久久久| 久久人妻AV中文字幕| 久久精品国产精品亚洲| 亚洲国产二区三区久久| 国产亚洲综合久久系列| 久久激情亚洲精品无码?V| 人妻无码αv中文字幕久久 | 色狠狠久久综合网| 国内精品久久久久影院网站 | 久久婷婷五月综合色奶水99啪| 狠狠色狠狠色综合久久| 99久久精品免费| .精品久久久麻豆国产精品 | 久久久久久综合一区中文字幕| 久久人人爽人人爽人人片AV不 | 久久婷婷色综合一区二区| 777午夜精品久久av蜜臀 | 久久国产成人精品国产成人亚洲| 久久国产精品成人片免费| 久久综合综合久久综合| 久久综合伊人77777麻豆| 久久99精品久久久久久9蜜桃| 无码超乳爆乳中文字幕久久 | 日本强好片久久久久久AAA| 久久人人爽人爽人人爽av| 久久本道综合久久伊人| 久久精品国产精品国产精品污| 91亚洲国产成人久久精品网址| 久久亚洲精品成人AV| 久久久久免费看成人影片| 午夜精品久久久久久毛片| 久久久久久午夜成人影院|