chillancezen / ZeldaOS

32bit OS/kernel built from scratch with POSIX.1 compliance
BSD 3-Clause "New" or "Revised" License
28 stars 2 forks source link

Could ZeldaOS fit on a 1.44MB or 2.88MB floppy? #1

Open informer2016 opened 5 years ago

informer2016 commented 5 years ago

Good day, @chillancezen . Please tell, could ZeldaOS fit on a 1.44MB or 2.88MB floppy? Even today the floppies are still being used, for example - as virtual floppies inside the coreboot open source BIOS. Just imagine: your wonderful OS could be a part of someone's BIOS build! _(for coreboot supported motherboard, maybe you have or could get one - see https://www.coreboot.org/Supported_Motherboards )_

If you already have a coreboot-supported motherboard, or a real chance to get one, - wouldn't it be cool to be able to launch your own OS straight from the BIOS chip? ;) With one simple command its possible to add any floppy to coreboot BIOS build - and then you see it as a boot entry! Multiple floppies could be added this way (as long as you have enough space left inside the BIOS flash chip, luckily LZMA compression could be used for the stored floppies to reduce their occupied size)

P.S. Also it would be nice if there would be some build instructions, I am really interested about your ZeldaOS project but don't know how to correctly build it

chillancezen commented 5 years ago

Hi, I am so glad you opened the issue.

ZeldaOS is my hobby OS/Kernel project, which is designed to conform to POSIX.1 interface standard, and major in networking functions such as fully fledged L3/L2 in a virtualized setup(because I am going to only realize virtio-net and vmxnet3 paravirtualized ethernet devices). even I did burn the bootable Zelda.iso into the udisk drive and made it booted, a physical setup benefits nothing from ZeldaOS's networking functions.

as I never saw a floppy drive before, I am not sure whether it fits on that floppy drive. the raw Zelda.bin(without a bootloader) image is about 797K large. if I strip the debuginfo, it gets a little smaller, but not too much. there is no ramdisk, I package all userland applications into ZeldaDrive, further into Zelda.bin,

#ls -lh
total 11M
drwxr-xr-x. 6 root root   66 Nov 30 09:26 application
drwxr-xr-x. 3 root root  265 Dec 10 19:57 device
drwxr-xr-x. 3 root root 4.0K Dec 10 19:57 filesystem
drwxr-xr-x. 3 root root   18 Oct  5 03:31 iso
drwxr-xr-x. 3 root root 4.0K Dec 10 19:57 kernel
drwxr-xr-x. 3 root root 4.0K Dec 10 19:57 lib
-rw-r--r--. 1 root root  810 Dec  1 22:05 Makefile
drwxr-xr-x. 3 root root  219 Dec 10 19:57 memory
drwxr-xr-x. 2 root root  110 Dec  1 22:05 mk
drwxr-xr-x. 3 root root  101 Dec 10 19:57 network
-rwxr-xr-x. 1 root root  360 Dec 10 21:00 qemu.sh
-rw-r--r--. 1 root root   28 Oct  5 03:31 README.md
drwxr-xr-x. 4 root root 4.0K Dec 10 19:57 runtime
drwxr-xr-x. 3 root root  259 Dec 10 19:57 x86
-rwxr-xr-x. 1 root root 797K Dec 10 19:57 Zelda.bin
-rw-r--r--. 1 root root 3.3K Dec 10 19:56 zelda_config.h
-rw-r--r--. 1 root root 487K Dec 10 19:57 Zelda.drive
drwxr-xr-x. 3 root root   51 Oct  5 03:31 ZeldaDrive
-rw-r--r--. 1 root root 9.5M Dec 10 19:57 Zelda.iso
-rw-r--r--. 1 root root  83K Dec 10 19:57 Zelda.map

btw, the way to build is given in recent README.md, I will give the feature inventory(including those that have been realized and those that are on the roadmap).

thanks Jie

informer2016 commented 5 years ago

@chillancezen Thank you very much for your reply! I see that ZeldaOS could fit (since ~800K is much smaller than floppy 1440K or 2880K) , but maybe it could be indeed difficult to find a real world usage scenario for a physical setup at the moment... Please tell, what would be the final purpose of ZeldaOS, do you plan to use it for some advanced networking purposes like a resource efficient webserver?

chillancezen commented 5 years ago

hi the utimate vision of zeldaos I imagined before is that zeldaos is a L3 router with overlay support.

I did intend to support bare betal setup in networking because I thought realizing a physical ethernet device driver is more complicated than paravirtualized ethernet device driver. L7 web server is not my utilmate goal, to support that, I would port a user land protocol stack LWIP

Thanks Jie

informer2016 commented 5 years ago

@chillancezen Thank you for reply! I'll be following your ZeldaOS project, and if there'll ever be a floppy and potential benefit of running at the real hardware, I'll test it as a part of coreboot+SeaBIOS :wink: