13
2023
11
15:56:07

coreboot & seabios



推荐点击下面图片,通过本站淘宝优惠价购买:

image.png

seabios现在是很多虚拟机的默认启动bios,这跟它的短小精干有很大关系,也跟它提供比较完备的legacy支持有关。


按照以下步骤把seabios制作成coreboot的payload,


下载seabios代码,

http://code.coreboot.org/p/seabios/downloads/


最新的代码是seabios v1.7.3.1

http://code.coreboot.org/p/seabios/downloads/31/


建议先试用seabios v1.7.2,因为下面提供的参考.config文件基于seabios v1.7.2。


解压后在Linux环境下运行“make menuconfig”

如果运行该命令时报错,一般可安装所需的library解决。


对于作为coreboot的payload,最重要的是选择是选择General Features->Build Target->Build from coreboot,并按照所需选择其他选项。


提醒:我曾经因为设置Debugging->Debug Level为9,seabios在运行中死机。如果你遇到类似现象,请试着降低Debug Level到3或者更小值。


提供一个seabios v1.7.2的.config文件作为参考,在这个configure文件里,只初始化了serial port,AHCI controller。该文件已经过实际硬件验证,能启动带Legacy boot支持的的Linux。


Automatically generated make config: don’t edit

SeaBIOS Configuration

Thu Aug 15 00:02:09 2013

General Features

CONFIG_COREBOOT=y


CONFIG_QEMU is not set

CONFIG_THREADS is not set

CONFIG_RELOCATE_INIT is not set

CONFIG_BOOTMENU is not set

CONFIG_BOOTORDER is not set

CONFIG_COREBOOT_FLASH is not set

Hardware support

CONFIG_ATA is not set

CONFIG_AHCI=y


CONFIG_MEGASAS is not set

CONFIG_FLOPPY is not set

CONFIG_USB is not set

CONFIG_SERIAL=y


CONFIG_LPT is not set

BIOS interfaces

CONFIG_DRIVES=y


CONFIG_CDROM_BOOT is not set

CONFIG_PCIBIOS is not set

CONFIG_APMBIOS is not set

CONFIG_PNPBIOS is not set

CONFIG_OPTIONROMS is not set

CONFIG_BOOT=y


CONFIG_KEYBOARD is not set

CONFIG_MOUSE is not set

CONFIG_S3_RESUME is not set

CONFIG_VGAHOOKS is not set

CONFIG_DISABLE_A20 is not set

VGA ROM

CONFIG_NO_VGABIOS=y


CONFIG_VGA_GEODEGX2 is not set

CONFIG_VGA_GEODELX is not set

CONFIG_BUILD_VGABIOS is not set

Debugging

CONFIG_DEBUG_LEVEL=3

CONFIG_DEBUG_SERIAL=y

CONFIG_DEBUG_SERIAL_PORT=0x3f8

复制代码


编译,使用“make”命令

编译完成后,生成的文件在out/目录下,作为payload的文件是bios.bin.elf,而bios.bin是普通意义上的bios文件。


把bios.bin.elf做为payload编译到coreboot中。

注意:在coreboot运行“make menuconfig”,payload中选择An ELF Executable payload(非seabios),然后指定bios.bin.elf的路径与文件名。


外部链接:


coreboot & seabios,

http://www.coreboot.org/SeaBIOS


seabios的wiki:

http://en.wikipedia.org/wiki/SeaBIOS


seabios:

http://www.seabios.org/SeaBIOS

image.png

image.png

image.png



1.seabios编译:make menuconfig ;make;

2.版本一直在更新,最新的2022-0502

3.三种target:可以和edk打包编译csm16.bin;也可以在虚拟机qemu作为单独的启动项bios.bin;把bios.bin.elf做为payload编译到coreboot中


本文链接:http://www.hqyman.cn/post/4528.html 非本站原创文章欢迎转载,原创文章需保留本站地址!

分享到:





休息一下,本站随机推荐观看栏目:


« 上一篇 下一篇 »

发表评论:

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。

您的IP地址是: