Giter VIP home page Giter VIP logo

hzcx998 / xbook2 Goto Github PK

View Code? Open in Web Editor NEW
457.0 27.0 70.0 117.39 MB

xbook2是一个基于x86处理器的32位操作系统,实现了大量的基础功能,可以拿来学习操作系统知识。

Home Page: http://www.book-os.org

License: MIT License

Makefile 1.29% Assembly 0.26% C 95.92% C++ 0.24% Shell 0.15% M4 0.30% Yacc 1.49% Awk 0.01% CSS 0.03% HTML 0.25% JavaScript 0.06% Perl 0.01%
os kernel x86 xbook

xbook2's People

Contributors

d1y avatar guee-gui avatar huloves avatar hzcx998 avatar nightfalldm avatar steveyuowo avatar zhuyu1997 avatar ziyao233 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

xbook2's Issues

So, the kernel do not support SMP now,right? :-)

Maybe add the MultiProcessor support for xbook2 is feasible, but i find it's also difficult,because should conversion the "pic" to "apic" contain the interrupt.And also will influence the process and switch :-)
There May be more problems

A problem about full screen

So fast! I am happy to see a new gui
There are three buttons In the upper left corner of each window,I clicked each one
But it seems that the application "bosh" cannot be full screen,when I click the button,desktop seems to be crashed
Should we add a new argument to g_new_window() ? Let us call it flags.Application can use it to tell the OS if it supports full screen.

错字吧

README.md中 并为完全分离出来应该是 并未完全分离出来。

README中有错别字

  • 点赞,老兄!不明觉厉!
  • README作为一个项目的门面,里面有错别字一只一来,希望能修改下。

在执行命令make qemudbg时系统出错

gcc 版本 9.2.1 20200130 (Arch Linux 9.2.1+20200130-2)
NASM version 2.15.05
qemu-i386 version 4.2.0

执行make qemudbg命令时,虚拟机屏幕显示:Guest has not initialized the display (yet).
截取部分log如下:

/root/usr/socket_server size=36648
/root/usr/tests size=97644
/root/usr/bosh size=83956
/root/usr/freeterm size=80904
/root/usr/lv size=876180
/root/usr/c4 size=46376
[fs]: init done.
video info: w:1024 h:768 bpp:16
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!
intr_general_handler: touch TRIGHW trigger because a expection 6 occur!

`make run` failed in centos!

2844 bytes (2.8 kB) copied, 0.00013241 s, 21.5 MB/s
dd if=src/kernel.elf of=develop/image/a.img bs=512 seek=100 count=1024		 conv=notrunc
1003+1 records in
1003+1 records out
513560 bytes (514 kB) copied, 0.0180234 s, 28.5 MB/s
tools/fatfs/fatfs develop/image/d.img develop/rom 0
fatfs: write rom files success.
/home/lee/Desktop/Computer_Systems/qemu/build/qemu-system-x86_64 -m 512M -name "XBOOK Development Platform for x86" -fda develop/image/a.img -hda develop/image/c.img -hdb develop/image/d.img -boot a -serial stdio -soundhw sb16 -soundhw pcspk
WARNING: Image format was not specified for 'develop/image/a.img' and probing guessed raw.
         Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
         Specify the 'raw' format explicitly to remove the restrictions.
WARNING: Image format was not specified for 'develop/image/c.img' and probing guessed raw.
         Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
         Specify the 'raw' format explicitly to remove the restrictions.
WARNING: Image format was not specified for 'develop/image/d.img' and probing guessed raw.
         Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
         Specify the 'raw' format explicitly to remove the restrictions.
qemu-system-x86_64: warning: '-soundhw sb16' is deprecated, please use '-device sb16' instead
qemu-system-x86_64: warning: '-soundhw pcspk' is deprecated, please set a backend using '-machine pcspk-audiodev=<name>' instead
VNC server running on ::1:5901
[arch]: init debug ok.
[arch]: init segment ok.
[arch]: init gate ok.
[arch]: init tss ok.
memory total:1ffe0000 byte 511 MB
[arch]: init pmem ok.
[arch]: init pic ok.
[pci]: begin sacn device.
init_pci: pci type device found 6.
[arch]: init tss pci.
welcome to xbook kernel.
time:9:43:16 date:2021/1/10
week day:0 Sunday year day:10
[task]: init done
[clock] init done
CPU info:
vendor: AuthenticAMD brand: QEMU Virtual CPU version 2.5+
family: Unknown AMD Processer model: Unknown
type: 0x0 stepping: 0x0
max cpuid: 0xd max cpuid ext: 0x8000000a
ide_enter: found 2 hard disks.
IDE:- Reads Nothing
     - [Primary Master]
[arch]: init debug ok.
[arch]: init segment ok.
[arch]: init gate ok.
[arch]: init tss ok.
memory total:1ffe0000 byte 511 MB
[arch]: init pmem ok.
[arch]: init pic ok.
[pci]: begin sacn device.
init_pci: pci type device found 6.
[arch]: init tss pci.
welcome to xbook kernel.
time:9:43:28 date:2021/1/10
week day:0 Sunday year day:10
[task]: init done
[clock] init done
CPU info:
vendor: AuthenticAMD brand: QEMU Virtual CPU version 2.5+
family: Unknown AMD Processer model: Unknown
type: 0x0 stepping: 0x0
max cpuid: 0xd max cpuid ext: 0x8000000a
ide_enter: found 2 hard disks.
IDE:- Reads Nothing
     - [Primary Master]
IDE:- Reads Nothing
     - [Primary Slave]
[driver]: ide_driver_entry create driver failed!
[ahci]: initializing ahci driver...
[ahci]: no AHCI controllers present!
[driver]: ahci_driver_entry create driver failed!
RTL8139 init failed: not find pci device.
[driver]: rtl8139_driver_entry create driver failed!
e1000_driver_vim: driver name=net-e1000v0.1
e1000_mac_addr:52-54-0-12-34-56
Intel(R) PRO/1000 Network Connection
ps2mouse: Device detected
ps2mouse: Mouse wheel enabled!
sb16: found version 4.5
do init call done.
[fs]: init start...
[diskman]: probe device:ram0 -> vir:disk0 type:16
[diskman]: probe device:vfloppy -> vir:disk1 type:16
[fsal] __mount: no fs on the disk disk0.
[fsal] __mount: mount fs source disk0 target /root fstype fat32 failed!
[fsal] __mount: no fs on the disk disk1.
[fsal] __mount: mount fs source disk1 target /root fstype fat32 failed!
[fsal] __mount: source disk2 not found!
[fsal] __mount: source disk3 not found!
[fsal] : mount path /root failed!

panic: init fsal failed, service stopped!
qemu-system-x86_64: terminating on signal 2

xbook2-master ❯ make run                                                                                                                 ⏎
dd if=src/arch/x86/boot/boot.bin of=develop/image/a.img bs=512 count=1 conv=notrunc
1+0 records in
1+0 records out
512 bytes (512 B) copied, 0.00542619 s, 94.4 kB/s
dd if=src/arch/x86/boot/loader.bin of=develop/image/a.img bs=512 seek=2 count=8 conv=notrunc
8+0 records in
8+0 records out
4096 bytes (4.1 kB) copied, 0.000571985 s, 7.2 MB/s
dd if=src/arch/x86/boot/setup.bin of=develop/image/a.img bs=512 seek=10 count=90 conv=notrunc
5+1 records in
5+1 records out
2844 bytes (2.8 kB) copied, 0.000379933 s, 7.5 MB/s
dd if=src/kernel.elf of=develop/image/a.img bs=512 seek=100 count=1024		 conv=notrunc
1003+1 records in
1003+1 records out
513560 bytes (514 kB) copied, 0.616513 s, 833 kB/s
tools/fatfs/fatfs develop/image/d.img develop/rom 0
fatfs: write rom files success.
/home/lee/Desktop/Computer_Systems/qemu/build/qemu-system-x86_64 -m 512M -name "XBOOK Development Platform for x86" -fda develop/image/a.img -hda develop/image/c.img -hdb develop/image/d.img -boot a -serial stdio -soundhw sb16 -soundhw pcspk
WARNING: Image format was not specified for 'develop/image/a.img' and probing guessed raw.
         Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
         Specify the 'raw' format explicitly to remove the restrictions.
WARNING: Image format was not specified for 'develop/image/c.img' and probing guessed raw.
         Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
         Specify the 'raw' format explicitly to remove the restrictions.
WARNING: Image format was not specified for 'develop/image/d.img' and probing guessed raw.
         Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted.
         Specify the 'raw' format explicitly to remove the restrictions.
qemu-system-x86_64: warning: '-soundhw sb16' is deprecated, please use '-device sb16' instead
qemu-system-x86_64: warning: '-soundhw pcspk' is deprecated, please set a backend using '-machine pcspk-audiodev=<name>' instead
VNC server running on ::1:5901
[arch]: init debug ok.
[arch]: init segment ok.
[arch]: init gate ok.
[arch]: init tss ok.
memory total:1ffe0000 byte 511 MB
[arch]: init pmem ok.
[arch]: init pic ok.
[pci]: begin sacn device.
init_pci: pci type device found 6.
[arch]: init tss pci.
welcome to xbook kernel.
time:13:27:46 date:2021/1/10
week day:0 Sunday year day:10
[task]: init done
[clock] init done
CPU info:
vendor: AuthenticAMD brand: QEMU Virtual CPU version 2.5+
family: Unknown AMD Processer model: Unknown
type: 0x0 stepping: 0x0
max cpuid: 0xd max cpuid ext: 0x8000000a
ide_enter: found 2 hard disks.
IDE:- Reads Nothing
     - [Primary Master]
IDE:- Reads Nothing
     - [Primary Slave]
[driver]: ide_driver_entry create driver failed!
[ahci]: initializing ahci driver...
[ahci]: no AHCI controllers present!
[driver]: ahci_driver_entry create driver failed!
RTL8139 init failed: not find pci device.
[driver]: rtl8139_driver_entry create driver failed!
e1000_driver_vim: driver name=net-e1000v0.1
e1000_mac_addr:52-54-0-12-34-56
Intel(R) PRO/1000 Network Connection
ps2mouse: Device detected
ps2mouse: Mouse wheel enabled!
sb16: found version 4.5
do init call done.
[fs]: init start...
[diskman]: probe device:ram0 -> vir:disk0 type:16
[diskman]: probe device:vfloppy -> vir:disk1 type:16
[fsal] __mount: no fs on the disk disk0.
[fsal] __mount: mount fs source disk0 target /root fstype fat32 failed!
[fsal] __mount: no fs on the disk disk1.
[fsal] __mount: mount fs source disk1 target /root fstype fat32 failed!
[fsal] __mount: source disk2 not found!
[fsal] __mount: source disk3 not found!
[fsal] : mount path /root failed!

panic: init fsal failed, service stopped!


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.