Giter Club home page Giter Club logo

rust-hypervisor-firmware's Introduction

Simple rust uefi core firmware

This project is an experiment and should not be used production workloads.

Building

  1. Install rust (https://www.rust-lang.org/)

  2. Intall xbuild

cargo install cargo-xbuild
  1. Compile the code
cargo xbuild --release --target target.json
  1. The result will be in:

target/target/release/payload-efi

Running

  1. check out https://github.com/jyao1/edk2/tree/minovmf

  2. build MinOvmf64FwPkg.

   build -p MinOvmf64FwPkg\MinOvmf64FwPkg.dsc -a IA32 -a X64 -t VS2015x86

The image is Build\MinOvmf64Fw\DEBUG_VS2015x86\fv\OVMF64Fw.fd.

  1. install qemu (https://www.qemu.org/)

  2. download image. (https://download.clearlinux.org/releases/28660/clear/clear-28660-kvm.img.xz)

  3. run qemu

qemu-system-x86_64.exe -machine q35,smm=on -smp 4 -serial mon:stdio -drive if=pflash,format=raw,unit=0,file=OVMF64Fw.fd -drive if=none,id=virtio-disk0,file=clear-29160-kvm.img -device virtio-blk-pci,drive=virtio-disk0,disable-legacy=on,disable-modern=off
  1. Then a uefi shell command prompt is shown in the command window. It supports some simple commands.

Boot Flow

The payload-efi can be treated as a UEFI payload.

The EDKII SEC loads payload-efi as UEFI core.

Then the payload-efi loads the EDKII UEFI shell.

TODO

  • implement more feature required by UEFI specification.
  • remove the EDKII SEC dependency.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.