Linux 3.4.39內核編譯配置選項介紹

    工程項目使用了全志H3平臺,make menuconfig配置內核爲Linux 3.4.39版本:


    在網上參考了一些配置選項,但是每個版本都有一些差異,在總結網友提供的資料的基礎上面,對3.4x版本進行歸納總結如下。

—————————————————————————————————————————————————————————————————————————————

注:內容太多,可能一兩天無法寫完,但是會陸續更新,如果有的地方不確定我會表上自己翻譯,等待後續理解後再更新。

General setup--->

-常規設置

    prompt for development and/or incomplete code/drivers

    -顯示尚在開發中或尚未完成的代碼與驅動,請慎重選擇此項

    Cross-comiler tool prefix 

    -交叉編譯工具前綴

    Local Version - append to kernel release 

    -在內核版本後面加上自定義的版本字符串(小於64字符),可以使用uname -a 命令查看

    Automatically append version information to the version string Kernel compression mode(Gzip) --->

    -自動在版本字符串後面添加版本信息並附到內核壓縮模式(自己組織的語言~),編譯時需要有perl以及git倉庫支持

        Gzip

        Bzip2

        LZMA

        XZ

        LZO

    (sun8i) Default hostname   默認主機名sun8i

    Support for paging of anonymous memory (swap)

    -使用交換分區或者交換文件夾來作爲虛擬內存

    System V IPC

    -System V進程間通信(IPC)支持,許多程序需要這個功能,必選擇項,除非自己很清楚要做的任務

    POSIX Message Queues

    -POSIX消息隊列,這是POSIX IPC中的一部分

    BSD Process Accounting

    -將進程的統計信息寫入文件的用戶級系統調用,主要包括進程的創建時間/創建者/內存佔用等信息

    open by fhandle syscalls

    -通過fhandle 系統調用打開(自己翻譯)

    Export task/process statistics through netlink (EXPERIMENTAL)

    -通過netlink接口向用戶空間到處任務/進程的統計信息,與BSD Process Accounting的不同之處在於這些在整個任務/進程生存起都是可用的

    Auditing support 

    -審計支持,某些內核模塊(例如SELinux)需要他,只有同時選擇其子項才能對系統調用進行審計

        Enable system-call auditing support

        -(使能)系統調用的審計支持

        Make audit loginuid immutable

        - 使審計loginuid不可變(自己翻譯)

    IRQ subsystem -->  無二級選項

    -IRQ 子系統

    RCU Subsystem --->

    -RCU子系統

        RCU Implementation (Preemptible tree-based hierarchical  RCU) --->

        -RCU實現(可搶佔的基於樹的分級RCU)

            Preemptible tree-based hierarchical RCU

            -可搶佔的基於樹的分級RCU

        Tree-based hierarchical RCU fanout value 

        -基於樹的分級分級RCU “fanout" 值 (fanout是什麼?)

        Disable tree-based hierarchical RCU auto-balancing

        -禁用基於樹的分級RCU自動平衡

        Accelerate last non-dyntick-idle CPU's grace periods

        -加速最後一個非合成空閒CPU的寬限期(自己翻譯)

        Enable RCU priority boosting 

        -啓用RCU優先級提升

    Kernel .config supprot 

    -內核.config支持

    Kernel log buffer size (16 => 64 KB, 17 => 128 KB)

    -內核log的緩存大小(前面選項寫16則64kb,17則對應128kb)

    Control Group / support --->

    -控制 組/支持選項

        Example debug cgroup subsystem

        -調試cgroup子系統示例(cgroup是什麼?)

        Freezer cgroup subsystem

        -凍結cgroup子系統

        Device controller for cgroups

        -cgroup的設備控制器

        Cpuset support 

        -只含有大量CPU(大於16個)的SMP系統或NUMA(非一致內存訪問)系統才需要此項

        Simple CPU accounting cgroup subsystem

        -簡單的 CPU統計(cgroup的)子系統(自己翻譯)

        Resource counters 

        -資源計數器

             Memort Resource Controller for Control Groups 

             -控制組的內存資源控制器

        Enable perf_event per-cpu per-container group (cgroup) monitoring

        -使能 perf_event per-cpu per-container的監視器( perf_event per-cpu per-container是什麼東西)

        Group CPU scheduler --->

        -CPU組調度程序

            Group scheduling for SCHED_OTHER

            -SCHED_OTHER的調度程序

                CPU bandwidth provisioning for FAIR_GROUP_SCHED

                -FAIR_GROUP_SCHED的CPU帶寬配置

            Group scheduling for SCHED_RR/FIFO

            -SCHED_RR/FIFO的調度

         Block IO conrtoller 

         -IO區塊控制器

    Checkpoint / restore support 

    -檢查/恢復點支持(自己翻譯)

    Namespaces support --->

    -命名空間支持

        UTS namespace 

        -UTS命名空間支持,若不確定可以不選擇

        IPC namespace 

        -~~~

        User namespace (EXPERIMENTAL)

        -用戶命名空間(是還在實驗使用階段嗎?)

        PID Namespaces

        -~~~

        Network namespace 

        -網絡命名空間

    Automatic process group scheduling 

    -自動進程組的調度

    Enable deprecated sysfs features to support old userspace tools 

    -啓用不推薦的sysfs功能用以支持舊的用戶空間工具

    Kernel -> user space relay support (formerly relayfs)

    -內核---用戶空間中繼支持(之前的relayfs)

    Initial RAM filesystem and RAM disk (initramfs/initrd) support (選中此項則會有如下6項 )

    -初始化RAM文件系統和RAM磁盤(如果啓動計算機所必需的模塊都在內核裏的話可以不選擇此項)

        Initramfs source file(s)

        Support initial ramdisks compressed using gzip

        -支持使用gzip壓縮的出事ramdisks

        Support initial ramdisks compressed using bzip2

        -~~

        Support initial ramdisks compressed using LZMA

        -~~

        Support initial ramdisks compressed using XZ

        -~~

        Support initial ramdisks compressed using LZO

        -~~

    Optimize for size 

    -優化size(是指內存大小嗎?)

    Default panic timeout

    -默認的超時(時限)

    Configure standard kernel features (expert users) --- >

    -配置標準內核功能(專家用戶)

        Systl syscall support

        -systl系統調用支持

        Load all symbols for debugging/ksymoops

        -加載調試/ksymoops的所有符號

            Include all symbols in kallsyms

            -包括在kallsyms的所有符號

        Support for hot-pluggable devices

        -支持熱插拔設備,比如USB與pc卡等,Udev也需要此選項

        Enable support for printk 

        -(使能)支持printk(printk是內核打印方法,類似於print函數,也就是支持內核調試打印輸出了)

        BUG() suport 

        -bug支持

        Enable ELF core dumps

        -內存轉儲支持,可以幫助調試ELF格式的程序

        Enable PC-Speaker support (NEW)

        -(使能)PC-Speaker 支持(新功能哦)

    Enable full-sized data structures for core 

    -在內核當中使用全尺寸的數據結構(禁用它將會使得某些內核的數據結構減小以節約內存,但是會將性能降低)

    Enable futex support 

    -快速用戶空間互斥體可是使線程串行化以避免競爭態條件,也提高了響應速度,禁用將導致內黑不能夠正確的運行基於glibc的程序

    Enable eventpoll support 

    -支持時間輪訓的系統調用

    Enable signalfd() system call 

    -支持signalfd的系統調用

    Enable timerfd() system call

    -~~

    Enable eventfd() system call 

    -~~

    Use full shmem filesystem

    -完全使用shmem文件系統來代替ramfs.shmem是基於共享內存的文件系統(可能用到swap),在啓用TMPFS後可以掛載爲tmpfs供用戶空間使用,它比簡單的ramfs先進很多。

    Enabel AIO support

    -使能AIO的支持

    Embedded system

    -嵌入式系統

    Kernel Performance Event And Counters --->

    -內核性能事件和計數器

        Kernel performance counters (old config option)

        -內核性能計數器(舊配置選項)

        Debug:use vmalloc to back perf mmap() buffers 

        -調試:使用vmalloc來返回perf mmap()緩衝區(數據)

    Enable VM event counters for /proc/vmstat 

    -允許在/proc/vmstat中包含虛擬內存事件計數器

    Enable PCI quirk workarounds (NEW)

    -(使能)PCI quirk解決方法(新功能)

    Disable  heap randomization

    -禁用堆隨機

    Choose SLAB allocator (SLAB) --->

    -選擇SLAB分配器(SLAB)

        SLAB

        SLUB (Unqueued Allocator)

        SLOB (Simple Allocator)

    Profiling support 

    -對系統的活動進行分析,供內核開發者使用

    OProfile system profiling

    -OProfile 系統分析

    Kprobes

    -供內核開發者使用

    Optimize very unlikely/ likely branches

    -優化不太可能/可能的分支

    GCOV-based kernel profiling --->

    -基於GCOV的內核分析

        Enable gcov-based kernel profiling

        -(使能)基於gcov的內核分析




發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章