From 30a569d8896de7d4e7f75bf02dc688677ad604b2 Mon Sep 17 00:00:00 2001 From: WangRunji Date: Tue, 7 Aug 2018 16:48:34 +0800 Subject: [PATCH] Update README --- README.md | 62 ++++++++++++++++++++++++------------------------------- 1 file changed, 27 insertions(+), 35 deletions(-) diff --git a/README.md b/README.md index 87fced5..ba04bfb 100644 --- a/README.md +++ b/README.md @@ -1,54 +1,46 @@ # RustOS -## Port to RISCV (WIP) - -2018年THU计算机系统综合实验 - -[Project Wiki](http://os.cs.tsinghua.edu.cn/oscourse/csproject2018/group05) - -[Documents](./docs/RISCV.md) - -### Environment - -[Dockerfile](./riscv-env/Dockerfile) (Can not build directly. Just for reference) - -Available on DockerHub: `wangrunji0408/riscv-rust` +[![Build Status](https://travis-ci.org/wangrunji0408/RustOS.svg?branch=master)](https://travis-ci.org/wangrunji0408/RustOS) -### How to run - -```bash -git clone https://github.com/wangrunji0408/RustOS.git --recursive -cd RustOS -# Pull docker image and enter docker interactive shell -make docker_riscv -# Inside docker ... -cd kernel -# Patch the atomic mod of core lib -make patch-core -make run -``` +Rust port for uCore OS, supporting x86_64 and riscv32i. ## Summary -[![Build Status](https://travis-ci.org/wangrunji0408/RustOS.svg?branch=master)](https://travis-ci.org/wangrunji0408/RustOS) +This is a project of THU Operating System (2018 Spring) && Comprehensive Experiment of Computer System (2018 Summer). -A project of THU OS2018 spring. +Project wiki (internal access only): [OS](http://os.cs.tsinghua.edu.cn/oscourse/OS2018spring/projects/g11), [CECS](http://os.cs.tsinghua.edu.cn/oscourse/csproject2018/group05) -[Project Wiki](http://os.cs.tsinghua.edu.cn/oscourse/OS2018spring/projects/g11) +Reports (in Chinese): [MidReport](./docs/MidReport.md), [FinalReport](./docs/FinalReport.md), [RISCV port note](./docs/RISCV.md) -[MidReport](./docs/MidReport.md) -[FinalReport](./docs/FinalReport.md) -The goal is to write a mini OS in Rust with multicore supporting. +The initial goal is to write a mini OS in Rust with multi-core support. More specifically, it would start from the post of the [Writing an OS in Rust](http://os.phil-opp.com) series, then reimplement [xv6-x86_64](https://github.com/jserv/xv6-x86_64) in Rust style. -It will start from the post of the [Writing an OS in Rust](http://os.phil-opp.com) series. Then reimplement [xv6-x86_64](https://github.com/jserv/xv6-x86_64) in Rust style. +In fact, it's more complicated than we expected to write an OS starting from scratch. So by the end of OS course, we only finished rewriting [ucore_os_lab](https://github.com/chyyuu/ucore_os_lab), without multi-core support. Then as a part of [CECS project](https://github.com/riscv-and-rust-and-decaf), we ported it from x86_64 to RISCV32I, and made it work on our FPGA CPU. ## Building -You need to have `nasm`, `grub-mkrescue`, `xorriso`, `qemu`, a nightly Rust compiler, and `xargo` installed. Then you can run it using `make run`. +### Environment + +* Rust toolchain at nightly-2018-08-03 +* `cargo-xbuild` +* `QEMU` >= 2.12.0 +* riscv32 + * RISCV64 GNU toolchain +* x86_64 + * `nasm` + * `grub-mkrescue` + * `xorriso` -A docker image is available and recommanded. Read [this](docker/README.md) for details. +### How to run + +```bash +git clone https://github.com/wangrunji0408/RustOS.git --recursive +cd RustOS/kernel +make run arch=riscv32|x86_64 +# For FPGA: +# make run arch=riscv32 board=1 +``` ## License