Minos2是一个全新的面向嵌入式和汽车领域的微内核架构操作系统。一个绝佳的实战机会,既可以学习到操作系统原理,又可以学习到ARMv8架构知识(包括内存管理,中断管理,虚拟化等),还可以锻炼自己的编程技巧。一个项目能掌握这么多东西,还要啥自行车。
当前Minos2还有许多模块和功能需要完善,我们的初期目标是支持大部分Posix原语,代码可以在Github下载:
https://github.com/minosproject/minos2
Minos2 is a micro-kernel OS for ARMv8-a.
- Multi-process
- SMP
- Multi-thread
- Virtual memory management
- Libc (based on musl-libc)
- IPC
- VFS
- Ext4 (based on lwext4)
- Virtio-blk driver
- Qemu
- ARM FVP
- Virtualization
Build Minos2
Below command tested on Ubuntu-18.04.
-
Create a working directory
# mkdir ~/minos2-workspace # cd ~/minos2-workspace
-
Install AARCH64 GCC cross compilation tool (Other GCC version is also work fine)
# wget https://releases.linaro.org/components/toolchain/binaries/7.2-2017.11/aarch64-linux-gnu/gcc-linaro-7.2.1-2017.11-x86_64_aarch64-linux-gnu.tar.xz # tar xjf gcc-linaro-7.2.1-2017.11-x86_64_aarch64-linux-gnu.tar.xz # sudo mv gcc-linaro-7.2.1-2017.11-x86_64_aarch64-linux-gnu /opt # echo "export PATH=/opt/gcc-linaro-7.2.1-2017.11-x86_64_aarch64-linux-gnu/bin:$PATH" >> ~/.bashrc # source ~/.bashrc
-
Install device-tree tool
# sudo apt-get install device-tree-compiler
-
Download minos2 source code
# git clone https://github.com/minosproject/minos2.git
-
Compile minos2
# make PLATFORM=xxx prepare (platform can be fvp or qemu_arm64) # make ramdisk (build kernel, libc, system service, application, ramdisk in out/ directory)
Download Virtio-blk image
Minos2 support Qemu and FVP now, and both use virtio-blk disk with Ext4 filesystem as rootfs, this image can be create by qemu-img tool. If you do not want to create it by self, you can download the example one here.
virtio-sd.img 链接: https://pan.baidu.com/s/1hMaQT20s7n8HNEZ-BqG7XQ 提取码: 9wyh
Run Minos2 on Qemu
-
Install qemu-system-aarch64<