原创 Linux arm64 bootmem_init 初始化詳細分析之-sparse_init

linux內核版本:linux-4.4.y  基於arm64分析 start_kernel -> setup_arch -> paging_init -> bootmem_init -> sparse_init 推薦文章:https://

原创 __builtin_constant_p(x)

引用自:https://blog.csdn.net/tmkeepgood/article/details/16965931 gcc的內建函數,當x爲常數時返回1, x爲變量時返回0. 不過這並不完全準確。 linux kernel的代碼中

原创 linux arm64 kmem_cache創建slab(slub)靜態對象,調用過程分析

linux4.10  arm64 defconfig 創建靜態slab對象 start_kernel     mm_init         kmem_cache_init             create_boot_cache  

原创 kali linux 無線攻擊——aircrack-ng文章記錄

https://blog.csdn.net/qq_37367124/article/details/79587713 1.airmon-ng check kill 2.airmon-ng start wlan0 3.airodump-ng

原创 linux arm64 early_fixmap_init 分析記錄

Linux4.0,運行環境qemu,arm64平臺 void __init early_fixmap_init(void) // 爲FIXADDR_START建立頁表映射 {

原创 arm64 linux pgd_offset_k 代碼閱讀過程中的疑問記錄

start_kernel -> setup_arch -> early_fixmap_init -> pgd_offset_k     pgd_t *pgd;     unsigned long addr = FIXADDR_START;

原创 arm64 內存佈局整理

VA_BITS = 48

原创 Linux非常好的內存管理文章推薦

【理解Linux內存管理】 https://blog.csdn.net/gatieme/article/details/52384965

原创 armv8 架構arm64 lookup_processor_type分析

文件位置:"arch/arm64/kernel/head.S" kernel版本:4.0.0 ENTRY(lookup_processor_type) adr x1, __lookup_processor_type_data /

原创 arm64 blr指令

子程序調用 指令(BL和BLR) 執行BL的結果是, 將 PC寄存器值的下一個值(也就是PC+8)放到 返回地址(鏈接寄存器), 然後目的子程序的地址放到PC中。 BLR的結果 與 BL類似,但是 新的PC的值,從特定的寄存器取得 因爲A

原创 arm64關於idmap和swapper mapping的理解

在arm中有一個idmap的恆等映射過程,即mmu on 之前建立的物理地址和虛擬地址相等的映射,arch/arm64/kernel/head.S文件中 將整個kernel恆等映射到了idmap區域,實際使用時,只用到mmu_on附近的恆

原创 arm64 __calc_phys_offset

__calc_phys_offset /* * Calculate the start of physical memory. */ __calc_phys_offset: adr x0, 1f ldp x1, x2, [x0]

原创 Linux kexec for arm32 static compile

下載kexec:http://horms.net/projects/kexec/ git clone git://git.kernel.org/pub/scm/utils/kernel/kexec/kexec-tools.git 然後進入

原创 elf可重定位記錄

注:部分引用自https://blog.csdn.net/ylcangel/article/details/18188921 一.相關概念: 重定位條目:當彙編器生成一個目標模塊時,它並不知道數據和代碼最終將存放在存儲器中的什麼位置。它也

原创 linux ARM64四級頁表映射理解

http://www.wowotech.net/memory_management/mm-init-1.html文章來源   假設48 bit的虛擬地址配置,4k的page size,這時候需要4級映射,地址被分成9(level 0 or