GRUB does this for you. See this thread from a few years ago: https://news.ycombinator.com/item?id=7590790
Either that applies only to multiboot v2 or there was a bug in qemu loader since I had a non-zero value in .bss.
Either that applies only to multiboot v2 or there was a bug in qemu loader since I had a non-zero value in .bss.