<뼭>,<>,<>,<ۿ>,<>,<> /<â> |
2Ⱓ ڵ м, 1Ⱓ ʷ 뼺 ARM Ŀ м!
Ŀ ڵ м Ѵ!
Ŀ ڵ м ǿ ħ!
å ڵ 3Ⱓ Ŀ м ڷḦ ʵǾ. å ٷ ʾҴ , ӱ ˾ƺҴ 뿡 öϰ Լ 帧 мϰ ִ. ̷ ڵ line by line м̶ ºν ̷м ڵ鿡 谨 Ȱ ̴.
̷м ARM Ŀ ٷ ִ å Ŀΰ ARM Ȯ ֵ ڵ м dz Ͽ, ڴ å ֱ Ǵ ֽ Ŀ м ִ ȿ ڿ ̴.
å Ŀ ۿ ϰ ־ Ŀ Ŀ ҽ ڵ带 мغ ϴ ڿ ϴ. ڵ带 мغ ;µ ظ ǥ θ ô , ñϼ̴ , OS Ŀ Ͻô , ̷ ڵ鿡 å ұݰ 簡 DZ⸦ ٶ.
å ٷ ֿ .
- Ŀ ҽ ý
- ARM μ
- ȿ м ȯ
-
- Ŀ м Ǵ API, ARM ɾ, GAS Ű
- ͷƮ ڵ鷯 ȣDZ ڼ
PART I ARM Ŀ - Ŀ м غ ʿұ?Chapter 1 Ŀο Ұ 2.6 3.2 0021.1 Ŀ ź 0021.1.1 ź 0021.1.2 پ ý ϴ 븮 Ŀ 0031.1.3 迡 ü 0051.2 Ŀ 2.6 3.2 006Chapter 2 Ŀ ý 0082.1 Ŀ ʱȭ 0082.2 Ŀ 0092.3 Ŀ 0112.4 Ŀ ġ 019Chapter 3 ARM μ ˾ƺ 0213.1 μ Ư¡ 0213.2 μ Űó ھ 0223.3 μ 0233.4 μ 0243.5 μ 0263.6 μ ͼ 0283.7 ϵ Ȯ 0303.7.1 ij 0303.7.2 ġ 0313.7.3 μ 031Chapter 4 м ȯ ϱ 0324.1 Ŀ ҽ ٿεϿ ġϱ 0324.1.1 Ŀ ҽ ٿεϱ 0324.1.2 ҽ ġϱ 0344.2 ctags + cscope ġϱ 0354.2.1 ctags ҽ ڵ ± 0354.2.2 cscope ± ͺ̽ 0374.3 vim ÷ ٿε ȯ漳 0384.3.1 vim ÷ ٿεϱ 0394.3.2 vim + plugin ȯ汸 0434.3.3 vim ȯ漳ϱ 0444.4 ҽ м ȯ ѷ 047PART II Ŀ - start_kernel ȣɱ?Chapter 5 Ŀ غϱ 0565.1 Ʈδ ̾ ù ŸƮ - start ̺ 0575.2 BSS ʱȭϱ - not_relocated ̺ 0595.3 ij Ȱȭϱ - cache_on ̺ 0625.4 Ʈ ʱȭϱ - _ _setup_mmu ̺ 0655.5 I-Cache Ȱȭ ij å ϱ - _ _common_mmu_cache_on ̺ 069Chapter 6 Ŀ ̹ zImageκ Ŀ ̹ ϱ 0706.1 ʰ Ŀ Ǯ - wont_overwrite, decompress_kernel ̺ 0716.2 Ŀ ȣϱ - call_kernel ̺ 0726.3 ijŬ ÷ - cache_clean_flush ̺ 0736.4 ij Ȱȭϱ - cache_off ̺ 075Chapter 7 start_kernel() ȣϱ 0767.1 ʱȭ ϱ - stext ̺ 0767.2 μ ã - _ _look_processor_type 0817.2.1 _ _lookup_processor_type ̺ 0817.2.2 _ _proc_info_begin _ _proc_info_end 0837.2.3 MMU Ȱȭ ¿ ּҸ ּҷ ϱ 0857.2.4 proc_info_list ü ã μ ϱ 0877.3 ӽ Ÿ ã - _ _lookup_machine_type 0887.3.1 _ _lookup_machine_type ̺ 0887.3.2 _ _arch_info_begin _ _arch_info_end machine_desc 0907.3.3 machine_desc ü ã ӽ ϱ 0917.4 Ʈδ atags - _ _vet_atags ̺ 0927.5 ϱ ϱ - _ _create_page_table ̺ 0957.6 ھ - v6_setup ̺ 1017.7 MMU Ѱ ּ ϱ - _ _enable_mmu / _ _turn_mmu_on ̺ 1027.8 start_kernel - _ _mmap_switched ̺ 107PART III Ŀ - Ŀ ۰ ΰ?Chapter 8 smp_setup_processor_id() ~ lock_kernel() 1128.1 smp_setup_processor_id(), lockdep_init(), debug_objects_early_init() 1138.1.1 smp_setup_processor_id() 1138.1.2 lockdep_init() 1138.1.3 debug_objects_early_init() 1158.2 ÷ο ϱ - boot_init_stack_canary() 1178.3 μ ȭϴ ϴ cgroup ʱȭϱ ? cgroup_init_early() 1188.3.1 cgroupfs_root cgroup ʱȭϱ - init_cgroup_root() 1238.3.2 ý ʱȭϱ - cgroup_init_subsys() 1238.4 irq Ȱȭϱ - local_irq_disable() 1258.5 early_boot_irqs_off(), early_init_irq_lock_class() 1258.6 Ŀ - lock_kernel() 127Chapter 9 Ŭ ̺Ʈ ڵ鷯 ϱ 1349.1 Լ - tick_init() 1349.2 ̺Ʈ ó ڵ鷯 ϱ - clockevents_register_notifier() 1369.2.1 clockevents_lock ɱ 1379.2.2 clockevents_chain Ǵ 1399.2.3 clockevents_chain tick_notifier ϴ 1409.2.4 clockevents_lock ϴ 142Chapter 10 CPU Ʈʿ CPU ϰ HIGHMEM ʱȭ 14410.1 ÷ ִ Ʈʿ init_task ϴ CPU ߰ϱ - boot_cpu_init() 14410.2 ϱ - page_address_init() 146Chapter 11 ü ϱ - setup_arch() 149Chapter 12 unwind_init() ~ early_trap_init() 15212.1 ϱ - unwind_init() 15212.2 ӽ ִ machine_desc ü ϱ - setup_machine() 15312.3 ATAG óϱ ? setup_arch() 15412.4 Ķ óϱ - parse_cmdline() 15612.5 ҽ Ʈ ϱ - request_standard_resources() 15812.6 cpu possible Ʈ ʱȭϱ - smp_init_cpus() 16412.7 ARM 帶 ֱ - cpu_init() 16512.8 ͼ ڵ鸵 ʱȭϱ - early_trap_init() 16712.9 ͷƮ ڵ鷯 Լ 캸 17412.9.1 IRQ ڵ鷯 ȣϱ - asm_do_IRQ() 17712.9.2 ͷƮ ư - ret_to_user ̺ 179Chapter 13 μ ¾ϱ ? setup_processor() 18113.1 setup_processor() ˾ƺ 18113.2 CPU ID ã - read_cpuid_id() 18313.3 μ ã - lookup_processor_type() 18413.4 μ Űó ã - cpu_architecture() 18513.5 μ ij Ÿ ã - cacheid_init() 18913.6 μ ʱȭ Լ ȣϱ - cpu_proc_init() 193Chapter 14 ¡ غϱ - paging_init() 19614.1 paging_init() ü 캸 19614.2 Ÿ ̺ ֱ - build_mem_type_table() 19814.3 ϱ ? sanity_check_meminfo() 20114.4 ̺ غϱ - prepare_page_table() 20314.4.1 prepare_page_table() 20314.4.2 ¡ 20514.4.3 Ʈ ϱ 20614.4.4 pmd_clear() 20814.5 ̽ غϱ - devicemaps_init() 21014.6 غϱ - kmap_init() 21514.7 ʱȭϱ 21614.7.1 Ҵϱ - _ _ alloc_bootmem_nopanic() 21714.7.2 忡 fallback Ͽ Ҵޱ - alloc_bootmem_core() 21814.7.3 ּҸ page ü ȯϱ - virt_to_page() 22014.8 D-Cache ϰ ϱ ? flush_dcache_page() 221Chapter 15 Ʈ Ÿ Ҵ ʱȭϱ - bootmem_init() 22315.1 bootmem Լ 帧 ڷᱸ 22415.2 bootmem_init() ˾ƺ 22915.3 ũ ġ ã - check_initrd() 23015.4 ũ ݿϱ - bootmem_init_node() 23115.4.1 map_memory_bank() 23315.4.2 bootmem_bootmap_pages() 23615.4.3 find_bootmap_pfn() 23815.4.4 node_set_online() 23915.4.5 NODE_DATA() ũ 24015.4.6 init_bootmem_node() 24215.4.7 free_bootmem_node() 24415.4.8 reserve_bootmem_node() 24515.5 0 ܽŰ - reserve_node_zero() 24615.6 ũ ܽŰ - bootmem_reserve_initrd() 24815.7 ٰ ϱ - bootmem_free_node() 24815.8 free_area ʱȭ 25115.8.1 free_area ü 25115.8.2 free_area_init_node() 25315.8.3 free_area_init_core() 25415.8.4 init_currently_empty_zone() 25615.8.5 memmap_init() 257Chapter 16 mm_init_owner() ~ preempt_disable() 26416.1 ϱ ? mm_init_owner() 26416.2 ɾ صα ? setup_command_line() 26516.3 per-cpu ʱȭϱ - setup_per_cpu_areas() 26616.4 CPU ϱ - setup_nr_cpu_ids() 26916.5 SMP μ ϱ - smp_prepare_boot_cpu() 27016.6 ٷ ϱ ڷᱸ ʱȭϱ ? sched_init() 27216.6.1 ٸ Ǵ task_group sched_entity ü runqueue ü Ҵ 27316.6.2 root_domain, rt_bandwidth, task_group ڷᱸ ʱȭ 27616.6.3 ý possible cpu ť ʱȭ 27816.6.4 ½ũ ٸ ʱȭ ε뷱 ͷƮ ڵ鷯 28016.7 Ŀ ϱ ? preempt_enable()/preempt_disable() 281Chapter 17 Ŀ ϱ 28317.1 build_all_zonelists() ٷ ڷᱸ 28317.2 build_all_zonelists() ˾ƺ 28517.3 Ʈ ϱ - set_zonelist_order() 28717.4 Ʈ Ʈ ϱ - _ _build_all_zonelists() 29017.4.1 build_zonelists() 29117.4.2 build_zonelists_in_node_order() 29317.4.3 build_zonelists_in_zone_order() 29617.4.4 build_thisnode_zonelists() 29717.4.5 build_zonelist_cache() 29717.5 Ʈ ϱ - mminit_verify_zonelist() 29917.6 Ҵ û ó ϱ - cpuset_init_current_mems_allowed() 30017.7 ϱ - nr_free_pagecache_pages() 30017.8 Ƽ 304Chapter 18 page_alloc_init() ~ pidhash_init() 30818.1 ÷ CPU page óϱ - page_alloc_init() 30918.2 console Ķ óϱ - parse_early_param() 31118.3 Ư Ķ óϱ - parse_args() 31318.4 ͷƮ Ȱȭ Ȯϱ - irqs_disabled() 31718.5 Ŀ ̺ ϱ - sort_main_extable() 31818.6 RCU Ŀ ʱȭϱ - rcu_init() 32018.7 IRQ ϱ غϱ - early_irq_init() 32318.8 ͷƮ ʱȭϱ - init_IRQ() 32818.9 μ ã ? pidhash_init() 331Chapter 19 init_timers() ~ page_cgroup_init() 33319.1 Ÿ̸ ʱȭϱ ? init_timers() 33419.1.1 timer_cpu_notify() 33519.1.2 register_cpu_notifier() 33619.1.3 open_softirq() 33719.2 High Resolution Ÿ̸ ʱȭϱ ? hrtimers_init() 33819.3 softirq ݹ Լ ϱ - softirq_init() 34119.4 xtime ϱ - timekeeping_init() 34519.5 ϵ Ÿ̸ ʱȭϱ - time_init() 34819.6 clock Ÿ ʱȭϱ - sched_clock_init() 35019.7 CPU ͷƮ Ȱȭϱ - local_irq_enable() 35219.8 Ʈ Ͻý Ǵ init ũ ˻ϱ 35319.9 Ҵ ʱȭ ۾ϱ - vmalloc_init() 35319.10 Ʈ ̳ ijÿ ʱȭ ̸ ϱ - vfs_caches_init_early() 35519.11 cpuset ý ʱȭϱ - cpuset_init_early() 35819.12 memory ý ʱȭϱ - page_cgroup_init() 360Chapter 20 bootmem Ҵڸ ϰ ý ü 36320.1 mem_init() Լ ȣ ڷᱸ 36320.2 mem_init() ˾ƺ 36420.3 ʴ Ʈʿ ϱ - free_unused_memmap_node() 36620.4 Ϲ ý ̰ϱ - free_all_bootmem_node() 36820.4.1 register_page_bootmem_info_node() 36820.4.2 free_all_bootmem_core() 37020.4.3 _ _free_pages_bootmem() 37220.4.4 _ _free_pages() 37620.4.5 free_hot_cold_page() 37620.4.6 _ _free_pages_ok() 37820.5 ý ̰ϱ - free_area() 383Chapter 21 CPU ÷ ʱȭ 38521.1 cpu_hotplug ʱȭϱ - cpu_hotplug_init() 38521.2 CPU ¶ ó 386Chapter 22 Ҵ Ȱȭϱ - kmem_cache_init() 38922.1 Ҵ ü 38922.2 Ҵ ߿ ü - kmem_cache kmem_list3 39122.3 kmem_cache_init() ˾ƺ 39422.4 initkmem_list3[ ], cache_cache.nodelists[ ] ʱȭ 39922.5 kmem_list3 迭 ϰ cache ҽð ϱ - set_up_list3s() 40122.6 cache Ȯ ҿ ϱ - cache_estimate() 40222.7 malloc_sizes cache_names 40622.8 cache ϱ - kmem_cache_create() 40822.8.1 kmem_cache_zalloc() 41022.8.2 calculate_slab_order() 41122.8.3 setup_cpu_cache() 41222.8.4 enable_cpucache() 41422.9 arraycache_init, kmem_list3 cache 41422.10 Ҵ kmalloc() Ҵ üϱ 417Chapter 23 kmem_trace_init() ~ security_init() 42023.1 ID allocator ij ϱ ? idr_init_cache() 42123.2 pageset ʱȭϱ - setup_per_cpu_pageset() 42123.3 ϱ - numa_policy_init() 42723.4 Ÿ̸ ʱȭ ϱ - late_time_init() 43123.5 BogoMIPS ϱ - calibrate_delay() 43123.6 μ ĺ(ID) Ҵ Ʈ - pidmap_init() 43323.7 켱 Ʈ ڷᱸ ʱȭϱ - prio_tree_init() 43523.8 anon_vma ij ϱ - anon_vma_init() 43523.9 ü ں ڰ οϱ ? cred_init() 43723.10 fork() ְ ڷᱸ ʱȭϱ - fork_init() 43823.11 μ ij ʱȭϱ - proc_caches_init() 43923.12 ij ʱȭϱ - buffer_init() 44223.13 Ű غϱ ? key_init() 445Chapter 24 VFS Ǵ پ ijõ ʱȭϱ - vfs_caches_init() 449Chapter 25 radix_tree_init() ~ ftrace_init() 46825.1 Ʈ õ ڷᱸ ʱȭϱ - radix_tree_init() 46925.2 ñ׳ غϱ ? signals_init() 47025.3 proc Ͻý ϰ Ʈϱ - proc_root_init() 47125.4 ʱȭ ý ϱ - cgroup_init() 47225.5 top_cpuset 缳ϰ cpuset Ͻý ϱ - cpuset_init() 47425.6 ½ũ ̽ ʱȭϱ - taskstats_init_early() 47525.7 غ - delayacct_init() 47725.7.1 ī 47725.7.2 dealyacct_init() 47725.7.3 task_delay_info ü delayacct_tsk_init() 47825.8 ϰ ˻ϱ - check_bugs() 481Chapter 26 ŷ ũϱ - Ʈ 48326.1 Ʈ Ŀ 48426.2 Ʈ Ȱȭϱ - pdflush_init() 48526.3 pdflush 48726.4 Ʈ Լ ϱ - pdflush_operation() 48926.5 ֱ Ʈ, Ʈ ݹ Լ ȣdz? 49026.5.1 ֱ Ʈ Լ - wb_kupdate() 49026.5.2 Ʈ Լ - background_writeout() 49326.6 ֱ Ʈ ʱȭϱ - page_writeback_init() 494Chapter 27 Ŀ Լ ˾ƺ - rest_init() 496Chapter 28 Լ Ŀ ϱ - kernel_thread() 49928.1 kernel_thread() ˾ƺ 49928.2 μ ϴ Ʈ - do_fork() 50028.3 θ μ ϱ - copy_process() 504Chapter 29 ½ũ 51429.1 wake_up_new_task() ˾ƺ 51429.2 ½ũ ť - task_rq_lock() 51729.3 ½ũ 켱 ϱ - effective_prio() 518Chapter 30 Ŀ غϱ - kernel_init() 52230.1 μ ٸ CPU ֽŰ - sched_init_smp() 52330.2 ý ʱȭ ϱ - do_basic_setup() 52630.2.1 rcu_sched_grace_period() ϱ - rcu_init_sched() 52730.2.2 events ũ ť ϱ - init_workqueues() 52830.2.3 cpuset ý top_cpuset ʱȭϱ - cpuset_init_smp() 53530.2.4 khelper ũ ť ϱ - usermodehelper_init() 53630.2.5 ̽ ʱȭϱ - driver_init() 53830.2.6 irq proc Ͻýۿ ϱ - init_irq_proc() 54830.2.7 Ŀ ý ȣϱ - do_initcalls() 54930.3 ʱȭ غϱ ? init_post() 554Chapter 31 Ŀ 55631.1 Ŀ - kthreadd() 55631.2 ñ׳ ϱ - ignore_signals() 55931.3 ̽ ϱ - set_user_nice() 56231.4 ½ũ ų CPU ã - set_cpus_allowed_ptr() 56731.5 Ʈ ϰ ִ ü ġ ã - list_entry() 56931.6 Ŀ ϱ - create_kthread() 572Chapter 32 find_task_by_pid_ns() ~ cpu_idle() 57532.1 PID ½ũ ã - find_task_by_pid_ns() 57632.2 BKL ϱ - unlock_kernel() 57932.3 ٸ Ŭ idle ϱ - init_idle_bootup_task() 58032.4 RCU Ŀ ȰȭǾ ˸ - rcu_scheduler_starting() 58032.5 Ŀ Ȱȭϱ - preempt_enable_no_resched() 58132.6 μ ٸ ϱ - schedule() 58232.6.1 schedule() ¥ ˸ - _ _schedule() 58232.7 - cpu_idle() 584Appendix A , gas Ű 588A.1 ARM ɾ ⺻ 588A.1.1 б ɾ 588A.1.2 ɾ 588A.1.3 ɾ 588A.1.4 ɾ 589A.1.5 ɾ 589A.1.6 ɾ 589A.1.7 μ ɾ 590A.1.8 Ÿ ɾ 591A.2 Ǻ 591A.3 gas þ 592Appendix B Ŀ м API 594B.1 Ʈ 594B.2 Ʈ API 595Appendix C ˾ƺ ext2 Ͻý 596C.1 Ÿ : inode 596C.2 i_mode ʵ带 ̷ Ʈ 597C.3 ִ ʵ - i_block[] 598C.4 ũ Ǵ 600C.4.1 Ƽ 600C.4.2 Block Group 601C.4.3 Inode Table 603C.4.4 , , Inode Table, Data Block 604Appendix D 608D.1 608D.2 609Appendix E Ŀ ũƮ 612E.1 ARM Ŀ ũƮ 613E.2 Ŀ ũƮ 615Appendix F ڵ Ʈ 623Appendix G Ʈ 632Appendix H ˾ƺô! Ʈ 639ãƺ 642