<div dir="ltr">Hello,<br><br>I'm building an image for a i486 based Board booting via BIOS/MBR using GRUB. The resulting disk image works fine in qemu (`qemu-system-i386 -hda disk.img`) but does not work on real hardware. The GRUB menu and shell work but when loading Linux there is just a blinking cursor for a few seconds followed by a reboot. This is definitely a problem with GRUB as the exact same bzImage boots fine via PXELINUX on the same Hardware! It also seems like Linux isn't even loaded since the reboot also happens with `panic=0` and I don't get any output even with `earlyprintk`.<br><br>I used the GRUB shell to confirm that it can access the boot partition and find the bzImage. I also tried to manually boot it from the shell but that fails with the same behavior.<br><br>The disk image is generated with genimage following the advise from `buildroot/boot/grub2/readme.txt` but I also tried the manual way using `grub-bios-setup` described there with the same non-working result.<br><br>At this point I have no clue what the problem could be (I assume it must be a bug in GRUB or how it is built?) and no idea how to debug this further.<br><br>I use a initial RAM filesystem that is directly linked into the kernel and the grub2 package from buildroot.<div><br></div><div>Buildroot version is 2021.02 with Linux 5.10, using a internal toolchain with GCC 10.x and musl as libc.<br><br>This is the `genimage.cfg` used (`grub_boot.img` is just `${HOST_DIR}/lib/grub/i386-pc/boot.img` copied into the `images` dir).<br><br>```<br>image boot.vfat {<br>    vfat {<br>        file boot/grub/grub.cfg { image = "grub.cfg" }<br>        file boot/bzImage { image = "bzImage" }<br>    }<br>    size = 32M<br>}<br><br>image data.img {<br>    ext4{}<br>    size = 32M<br>}<br><br>image disk.img {<br>    hdimage {}<br><br>    partition mbr {<br>        in-partition-table = "no"<br>        image = "grub_boot.img"<br>        offset = 0<br>        size = 512<br>    }<br>    partition grub {<br>        in-partition-table = "no"<br>        image = "grub.img"<br>        offset = 512<br>    }<br><br>    partition boot {<br>        partition-type = 0xC<br>        image = "boot.vfat"<br>        bootable = "true"<br>        offset = 1M<br>    }<br><br>    partition data {<br>        partition-type = 0x83<br>        image = "data.img"<br>    }<br>}<br>```<br><br>This is the `grub.cfg` used:<br><br>```<br>set default="0"<br>set timeout="2"<br><br>menuentry "Buildroot" {<br>    linux /boot/bzImage console=ttyS0,115200 earlyprintk=serial,ttyS0,115200<br>}<br>```<br><br>I use the exact same bzImage file and Linux cmdline when booting via PXELINUX (which works).<br></div></div>