[SeaBIOS] Question about the relationship between bios.bin and vgabios.bin
kevin at koconnor.net
Wed May 14 17:48:55 CEST 2014
On Wed, May 14, 2014 at 11:27:16AM +0000, Jaeyong Yoo wrote:
> For me, it looks like seabios (bios.bin) calls a function, vga_post,
> that is supposed be in vgabios.bin. It makes me thinking that
> vgabios.bin is somehow embedded in bios.bin. But, in my case I use
> both bios.bin and vgabios.bin to booting up my guest OS (I'm using
> qemu). Apparently, I'm not clearly understanding the difference
> between vgabios inside bios.bin and vgabios-stdvga.bin. Could you
> tell me the difference?
The vga bios is separate from the main bios. They are separate
binaries and are placed in separate areas of memory. The main bios
code is in the SeaBIOS src/ directory, while the vga bios code is
(mainly) in the vgasrc/ directory.
QEMU places the vgabios in a PCI rom, and SeaBIOS copies it to memory
(almost always 0xc0000).
> And, I'm trying to debug a vgabios.bin by examining with
> qemu+gdb. Especially, I'm trying to set the break-point to the entry
> point of vgabios.bin and I'm not quite sure how to do this since I
> don't know the address where vgabios.bin is loaded. I would
> appreciate if you give me some hint about this.
There is some info on using gdb with qemu in the SeaBIOS README file.
To use it with SeaVGABIOS, replace "gdb out/rom16.o" with "gdb
out/vgarom.o" and instead of adding 0xf0000 to your break points, add
Also, I find this command quite useful for inspecting the vga bios
assembler, and finding break points:
objdump -m i386 -M i8086 -M suffix -ldr out/vgarom.o | less
More information about the SeaBIOS