• Please review our updated Terms and Rules here

Linux to disable virtual 8086 mode support by default

I don't know if that will pass muster. A lot of people still use DOSEMU and even more, VirtualBox.

When they tried something similar before by disabling 16-bit segments, there was quite a bit of screaming, so they added:

Code:
echo 1 > /proc/sys/abi/ldt16

I wonder what Linus thinks of the proposal--looks like he's not in favor of it.

These yoyos broke floppy support in x86 and then replied "who cares?". Someone needs an attitude adjustment.
 
Virtual Box gets a full virtual machine, not an 8086 virtual mode machine. Within that virtual machine 8086 virtual mode is still available, if that guest OS supports it.
 
Something doesn't sound right. When 16-bit segment support was disabled in x64 Linux, VB WinXP was no longer able to support 16 bit applications. Why would this be any different with VirtualBox OSes using VMM86 (say, Win98 )? Something's not sinking in on this side.
 
Anybody who says with a straight face "this code is messy and I don't think it's important, let's break the functionality completely instead of fixing it!" needs the mother of all swift kicks in the ass.

Christ, I remember when the Lunix zealots made it a point of pride to support any piece of hardware they could lay their grubby paws on the reference manual for.
 
That proposal is to eliminate support for the Virtual 8086 mode from the kernel. Virtual 8086 mode was introduced with the 80386 and allows the running of virtual 8086 machines. See https://en.wikipedia.org/wiki/Virtual_8086_mode

Programs like VirtualBox and VMWare don't use that to run guest operating systems. VirtualBox and VMWare use either Intel VT-X or AMD AMD-V. See https://en.wikipedia.org/wiki/X86_virtualization

Removing Virtual 8086 mode from the Linux kernel is not going to affect VirtualBox or VMWare - they don't use it.
 
Please bear with me, Mike--but I'm not getting it. Win9x running under VirtualBox still uses Virtual 8086 mode to run DOS applications under its GUI. You're saying that elimination of VM86 support in the kernel doesn't matter--that Win98 will still run in VB just it always has? But that it will break DOSEMU. I use DOSEMU quite a bit and DOSBOX doesn't allow the same level of integration of of DOS and DOS 32-bit applications. FWIW, I tried using Wine with the option for running 16-bit code in DOSBOX and to be blunt, it sucks. It's much easier to use HXDOS to run 32-bit applications under DOSEMU.
 
Last edited:
If Linux removes VM86 mode, then Linux can't start Virtual 8086 machines.

If you choose to run Virtual Box under Linux then you are going to run some operating system in the virtual machine created by Virtual Box. That operating system can have it's own VM86 code and create its own Virtual 8086 machines. That's completely private to the guest operating system in Virtual Box; the Linux host operating system does not know or care.

More concrete examples:

  • Linux running DOSEmu directly will break; Linux will not have VM86 mode
  • Linux running VirtualBox running Win 95 will be fine - Win 95 can do whatever it wants inside of it's little sandbox
  • Linux running VirtualBox running Win XP will be fine - same thing.
  • A future version of Linux running VirtualBox running an old version of Linux running DOSEmu - no problem. The old Linux is in it's own sandbox and still has the VM86 code
 
I don't know if that will pass muster. A lot of people still use DOSEMU and even more, VirtualBox.

When they tried something similar before by disabling 16-bit segments, there was quite a bit of screaming, so they added:

Code:
echo 1 > /proc/sys/abi/ldt16

I wonder what Linus thinks of the proposal--looks like he's not in favor of it.

These yoyos broke floppy support in x86 and then replied "who cares?". Someone needs an attitude adjustment.

I agree! Since when are the kernel devs hell-bent on taking out base-functionality? And before the "who cares about VM86" crowd dismisses this as crank luddite drool, just think about what you are breaking...it is like throwing out the baby with the bathwater.

And WHY is this so important NOW??? Can we get a coherent answer to that ?, Pls?
 
Ah, thanks Mike for the explanation. I suppose someone could rewrite DOSEMU to simulate the switch to VM86 mode, but I suspect that won't happen. 16-bit DOS is purely the domain of fossils, it seems.

I take it that the same rules apply for QEMU also?
 
QEMU is a very different beast - it emulates full machines, even ones that are not the same architecture as the host. It can use hardware virtualization if it is available, but if not it will just brute force the emulation of the entire virtual machine.

Needless to say, being on the same architecture and being able to use the processor virtualization tricks is much faster.
 
A future version of Linux running VirtualBox running an old version of Linux running DOSEmu - no problem. The old Linux is in it's own sandbox and still has the VM86 code

Gives me flashbacks of Windows 7 x64 with its XP mode. The XP mode was 32-bit, and you could still run 16-bit Windows and DOS processes in there, even though no x64 version of Windows ever had the NTVDM for running any 16-bit code.
 
Ah, thanks Mike for the explanation. I suppose someone could rewrite DOSEMU to simulate the switch to VM86 mode, but I suspect that won't happen. 16-bit DOS is purely the domain of fossils, it seems.

Already done it seems. From https://lkml.org/lkml/2015/7/9/548

+ Some very old versions of X and/or vbetool require this option
+ for user mode setting. Similarly, DOSEMU will use it if
+ available to accelerate real mode DOS programs. However, any
+ recent version of DOSEMU, X, or vbetool should be fully
+ functional even without kernel VM86 support, as they will all
+ fall back to software emulation.
+
+ Anything that works on a 64-bit kernel is unlikely to need
+ this option, as 64-bit kernels don't, and can't, support V8086
+ mode.
 
If they were pulling it from both the 32 and 64 bit versions I'd be concerned.
But since it's already a non-feature on 64 bit - not too fussed. I use VirtualBox, VMWare, DOSBox, lots of other tools.
 
Okay, my mind is a more at ease. I still had flashbacks of what happened when 16-bit segment support was disabled in the kernel--and few people were informed about it.
 
Back
Top