1vuio0pswjnm7 2 days ago
6SixTy 2 days ago

Kind of cool, but being exclusively for BIOS/MBR kind of kills my excitement.

  • nine_k 2 days ago

    Yes. BIOS. Real mode. Not that I've been missing them these 30 years, and they are still in place. It gives a weird feeling.

    I mean, if you target ancient baroque hardware like e.g. ZX Spectrum, you specifically target an ancient machine. But this is expected to work on any modern x86 hardware, while it feels like code for a 80286, and likely would run there. And this ancient stuff is still supported and actively used.

    • musicale 2 days ago

      > this ancient stuff is still supported and actively used.

      It sort of warms my heart that code for the IBM 360 (now IBM Z) and the IBM PC (now x86 PC) can still run on modern hardware decades later.

      On one hand, we're stuck with the legacy of the past. But on the other hand, we can build on things and don't need to reinvent them unnecessarily.

      • msla 2 days ago

        How much emulation is required to get System/360 code running on a modern IBM mainframe? Can the CPUs still run the original 32-bit code? Do CCWs and whatever other peripheral code still work?

    • raxxorraxor a day ago

      > Yes. BIOS. Real mode.

        ; 0x20000 - 0x2fdff temporal space to load ; size: 63.5Kb is the max.
      
      wasn't there an inofficial unreal mode that increased the adressable space? Otherwise there aren't too many options as to stay minimal in the first place.
micw 2 days ago

Do I see it right that I need to recompile and reinstall it on each new kernel?

  • paulannesley a day ago

    Yeah it looks like it needs to be assembled and written any time the kernel file's position on disk changes (`current_lba`), or different kernel cmdline is required.

    I seem to remember having to do something similar with lilo… not hand-editing assembly, but running a command to rewrite the boot sector when the kernel moves on disk.

gitroom a day ago

yeah im always low key impressed this old boot stuff still works now - makes messing with it feel kinda worth it

M95D 2 days ago

I don't see how this is better than lilo.

  • 6SixTy 2 days ago

    It's not supposed to be better than lilo, just code golf. Limine is pretty much the only serious bootloader gunning for the spot lilo/elilo was going for.

  • WalterGR 2 days ago

    It’s not meant to be full-featured. It shows how to write a bootloader that’s smaller than 512 bytes.