flat assembler
Message board for the users of flat assembler.
Index
> Projects and Ideas > Your tiny OS as BIOS replacement |
Author |
|
XVilka 04 May 2011, 02:10
Good day!
I'm one of the coreboot users/developers. This is FOSS alternative to legacy BIOS/EFI. It let boot any elf image, or SeaBIOS (which provide legacy bios services). And it's pretty small. So, as usually modern BIOS flash chips are big, you can place your tiny own OS in ROM. As example, i'm working on booting KolibriOS from coreboot. Now it booting oveer SeaBIOS, but i'm hope exclude SeaBIOS stage from booting. First of all - please, read our wiki http://www.coreboot.org/ Found supported hardware http://www.coreboot.org/Supported_Motherboards and decide which you have to try coreboot, or you can use QEMU. 1. Download&configure&build: Code: svn co svn://coreboot.org/coreboot/trunk coreboot cd coreboot make menuconfig You need to choose: Code: Mainboard -> Mainboard Vendor -> Emulation Mainboard -> Mainboard Model -> QEMU x86 for producing image for qemu. Then run Code: make 2. Output will be in coreboot.rom inside build directory. 3. Download vgabios image for qemu from http://www.coreboot.org/images/0/0d/Vgabios-cirrus.zip 4. You need latest qemu (0.14 or from git) 3. Copy coreboot.rom in working directory, rename it into bios.bin Copy vgabios-cirrus.bin here also. 4. Run qemu with Code: qemu -L . -cdrom kolibri.iso -serial stdio where kolibri.iso is kolibrios image, but can be your own OS image. "-L ." option point qemu to directory where bios.bin and vgabios-cirrus.bin files. here is my example image: Code: coreboot.rom: 4096 kB, bootblocksize 1504, romsize 4194304, offset 0x0 Alignment: 64 bytes Name Offset Type Size cmos_layout.bin 0x0 unknown 1159 fallback/romstage 0x4c0 stage 12720 fallback/coreboot_ram 0x36c0 stage 27797 fallback/payload 0xa3c0 payload 40596 (empty) 0x142c0 null 4110104 Also you can pack OS image in rom: I'm using kolibri.img (floppy image): Code: lzma -zc kolibri.img > kolibri.img.lzma ./build/cbfstool coreboot.rom add kolibri.img.lzma floppyimg/Kolibri.lzma raw where cbfstool in build directory of coreboot tree. you can check now result with: Code: ./build/cbfstool coreboot.rom print Now you can also rename coreboot.rom into bios.bin for your working directory and try boot with qemu. Also, coreboot let you boot:
For additional info, please read first: http://www.coreboot.org/FAQ
For flashing your image you can use flashrom utility (http://www.flashrom.org) - please always use latest (from svn) version!!! For debugging this on real hardware you can use SerialICE http://www.serialice.com/ I'm attaching ready image and some files from libpayload to show how-to work with coreboot specifics
Last edited by XVilka on 08 Aug 2011, 23:59; edited 2 times in total |
|||||||||||||||||||||
04 May 2011, 02:10 |
|
Dex4u 04 May 2011, 21:04
Nice project XVilka, i will try and get DexOS to boot from coreboot.
|
|||
04 May 2011, 21:04 |
|
TmX 25 Jun 2011, 17:36
How to choose targets->QEMU?
I'm on revision 6637. |
|||
25 Jun 2011, 17:36 |
|
XVilka 05 Jul 2011, 20:16
Mainboard -> Mainboard Vendor -> Emulation
Mainboard -> Mainboard Model -> QEMU x86 |
|||
05 Jul 2011, 20:16 |
|
Flat12 03 Jan 2014, 22:48
Floppy image OS support only SeaBIOS. The OS can be also run using the ISA or PCI option rom. In article is PCI Option ROM but this way require use PCI NIC or SCSI card. I made a patch in loader1.asm to possible boot over ISA Option ROM (PnP). Tested on real hardware with AWARD BIOS and coreboot+SeaBIOS, Qemu+SeaBIOS, MS VPC 2007. Code is for NASM not FASM assembler.
P.S. On AWARD 6.00PG bios to run this ISA option rom we need disable all boot devices in CMOS Setup. This works like old IBM PC with IBM-BASIC ROM - if no more boot devices found run BASIC-ROM. On AWARD - if no more boot devices found run ISA PnP Option ROM. Link -> ISA Option ROM on AWARD bios
|
||||||||||||||||||||
03 Jan 2014, 22:48 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.