guilt / KOS

A Hobby-OS to experiment with.
4 stars 1 forks source link

could KOS fit on a floppy? #1

Open informer2016 opened 4 years ago

informer2016 commented 4 years ago

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 )_

@guilt , 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)

guilt commented 4 years ago

👍

It would be cool - and it should be able to.

A great way to test this functionality will be using the qemu -L BIOS/ command line. It should be possible to build this as a module into Coreboot, and attach as an entry point to Coreboot as opposed to boot from disk; Call it KOS_main, and then you get all the functionality - and look ma, no disks.

Most commercial ROM chips available on the market have 16+MB chips; That should be able to not just give enough driver room, but also run some useful applications as well.

I estimate that if one builds in a TinyX driver, they should be, in theory, be able to get even something way more usable to most people, within ~2MB, and boots in split seconds. Totally unrelated, I do happen to have a flash programmer + crocodile clips + backup BIOS chips.

informer2016 commented 4 years ago

@guilt Thank you for reply! I'm not aware of any existing ways of adding KOS to coreboot other than creating a KOS floppy which could be easily added and booted with the help of SeaBIOS - coreboot's default payload. Perhaps it could be possible to use a bootable floppy of some other hobby OS like Fiwix ( https://www.fiwix.org/downloads.html , "1.44MB Live Floppy Image v1.0.1+ with initrd using RAMdisk driver" version ), which i.e. has a working bootloader, and replace this hobby OS with your KOS.

Although there are SPI Flash chips of <=16MB for SOIC-8 and higher for SOIC-16, it could be much more difficult to add KOS to a proprietary BIOS/UEFI, simply because they are not designed for it and lots of hacking would be required. Also, compared to coreboot, these proprietary BIOS/UEFI are really bloated and usually occupy the majority of their memory with just a small space left, which could be insufficient.

Do you have any coreboot-supported motherboards? Or maybe some motherboards, which - although not supported yet - theoretically could be ported? If you could share the models of your motherboards, especially the old ones, maybe I could guess if this is possible. Because, if your motherboard is supported or would be supported, there would be a lot more benefit for you to create such a KOS floppy.