Giter Club home page Giter Club logo

j-i-os's Introduction

J(i)OS

A 64 bit, amd64 compatible operating system from scratch.

Screenshot:

Build and Run

Prerequisite

You will need - qemu-system-x86_64 - clang - ld.lld - nasm - (optional) clang-format And thats it.

In kernel/Makefile, LD is set to LD = /usr/local/Cellar/llvm/12.0.1/bin/ld.lld Use your path instead.

Build and Run

After the preparation, under some-path/J-i-OS, run make test to run the O/S and get the output from stdout.

Or, run make qemu to run the O/S with a vga buffer, I DO NOT recommend this since all logging and output are currently through uart to stdout.

Run make format to format the codes in GNU style.

Directory

boot -> bootloader, from real mode -> protected mode -> long mode (referenced osdev.org) kernel -> kernel code

Run

make qemu: run in qemu, with display

make test: without display, uart output redirected to stdout

make img: build os.img from bootloader and kernel code

Roadmap

  • bootloader
  • jump to C kernel
  • bigger kernel
  • VGA and uart
  • setup idt
  • sample breakpoint interrupt
  • remap pic
  • keyboard interrupt
  • timer interrupt
  • logger
  • printf
  • logging w/ file name & line number
  • kernel memory allocation
  • mmu
    • switch kernel pgtbl when entered C
    • page table walk
    • page table setup and write to cr3
  • process
    • proc struct
    • proc allocation
    • exec
  • trap
    • serial interrupt control
  • syscall
  • user space
  • scheduling

Not planned to do currently...

  • filesystem
  • inode
  • initramfs
  • image file system

Ji Xinyou

Acknowledgement

I write this OS project mainly for 2 reasons. First is for my personal interest on the bottom-up process of a freestanding operating system. Second is to leave the git log for everyone looking at this repository, to check the developement process of this OS, most commit is bug-free, and being commented relatively clear. During the development, I reference many tutorials and websites, including youtube tutorial by @Poncho, stackoverflow questions, osdev wiki and github repo 64bit-os-tutorial, also borrowed some codes from xv6. I am here to thank every person that help me through the development by any means.

If you have found any bug or have any questions, please feel free to issue them in the github issue section, or email me straight to jerryji0414[at]outlook[dot]com.

j-i-os's People

Contributors

xyjixyjixyji avatar

Stargazers

Bie, Yequan avatar Orogeny Guo avatar  avatar  avatar  avatar Yiming Dou avatar

Watchers

 avatar

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.