[ipxe-devel] 486 with a Realtek 8139

Nikolai Zhubr n-a-zhubr at yandex.ru
Wed May 5 18:53:03 UTC 2021

Hi Michael,

Thanks for mentioning Bochs, I've copied your 486 config commandline and 
was able to build and start testing. Its way more handy than with real 
iron. It is even possible to disable e820 function by hand.

Now as long as 586+ requirement is not really critical for operation, 
maybe put such fragments into conditional ifdefs and introduce some 
config option (say LEGACY486) to allow 486-compatible builds? 486s are 
still not uncommon in production and network boot is quite usefull in 
such environments.

Still no result with my 8139 problem yet, but at least I now have a 
convenient testing environment.

Thank you,


05.05.2021 15:18, Michael Brown:
> A quick test indicates that unlzma.S will still build with ".arch i486".
> AFAICT the only non-i386 instruction in there is "bswap", which should
> exist on a 486.
> I did some quick testing in bochs configured for a 486 using:
> ./configure --enable-a20-pin --disable-x86_64 --enable-cpu-level=4 \
> --enable-pci --enable-e1000 --enable-debugger \
> --disable-debugger-gui --enable-readline \
> --enable-all-optimizations --enable-cdrom --disable-smp
> This showed that iPXE is getting stuck on the "rdtsc" instruction, which
> is an undefined opcode on i486.
> The rdtsc-based timer isn't causing the problem: the code in
> rdtsc_probe() already checks for an invariant TSC (which isn't present
> on i486) and so never issues the rdtsc instruction.
> There are two remaining uses: in undinet_call() where the TSC value gets
> used only for profiling, and in rtc_sample() where the TSC value gets
> used as part of entropy generation.
> Commenting out these instructions (via the attached patch) gave me an
> iPXE binary that worked fine on i486.
> Michael

More information about the ipxe-devel mailing list