这是一个不到2000行的操作系统,巧妙地利用ARM9 CPU的内存管理单元(MMU)实现进程的切换。ARM9的4G虚拟地址可分成128个进程空间,每个32M。虽...
代码说明:
这是一个不到2000行的操作系统,巧妙地利用ARM9 CPU的内存管理单元(MMU)实现进程的切换。ARM9的4G虚拟地址可分成128个进程空间,每个32M。虽然它们的虚拟地址(VA)都是0-(32M-1),但是对应的MVA(Modified vitual address,由虚拟地址VA和进程号PID组合而来)不一样,设置MVA对应的页表指向不同物理地址就可以很方便地让各进程运行空间相互隔开。代码很少,注释丰富,希望能对想理解操作系统、了解ARM体系结构的朋友有所帮助。 -This is a trip of less than 2000 operating system, cleverly using ARM9 CPU memory management unit (MMU) to achieve the switching process. ARM9 4G virtual address can be divided into 128 process space, each 32M. While their virtual address (VA) are 0- (32M-1), but the corresponding MVA (Modified Virtual address, and by the virtual address VA and the process of portfolio from PID) not the same, set MVA corresponding page table at the different physical address can be very easy to let the the process of separating the mutual operation of space. Code rarely Notes rich, in hopes of understanding the operating system, understanding the ARM architecture friends help.
下载说明:请别用迅雷下载,失败请重下,重下不扣分!