3 ms·
Oh, sure -- the CPUs themselves can run in 16 bit mode, but after switching to 64 bit long mode I was under the impression you couldn't invoke vm86 mode. But I'
by spijdar 6y ago
Oh, sure -- the CPUs themselves can run in 16 bit mode, but after switching to 64 bit long mode I was under the impression you couldn't invoke vm86 mode. But I've never really played with 16 bit before.
I guess I was confusing it with BSD -- on at least NetBSD and I think OpenBSD, there's an in-kernel (16 bit) x86 emulator used for certain ACPI functions, like calling VGA BIOS code (option ROMs?) when waking from suspend-to-RAM.
There's also an option to just use native real mode, but the man page says "this may result in direct reboots".
- AshamedCaptain 6y agoYes you can switch back to 16bit, and in early x64 Linux there was even support for the vm86plus() API, which allowed stuff such as dosemu to run natively (and even let DOS programs bitbang your IO ports). Eventually this was removed from upstream but there was a patch floating around which I used for some time. Whatever one _wants_ to do it or not is another story. Even on 32-bit kernels I don't think vm86plus is enabled by default (nor is LDT changing from user-space) because of the crazy ways you can use it to break things.
- deleted 6y ago[deleted]