bugs in arch/i386/kernel/vm86.c (fwd)

Eric A Schweitz (schwea@aur.alcatel.com)
Tue, 15 Aug 1995 15:57:26 -0400 (EDT)

[Disclaimer: I don't run Linux yet and I am not sure this is the
right place to report such bugs; please forward or mail me if it

I was browsing the 1.2.0 kernel and stumbled over handle_vm86_fault()
from the above file. At least two things are wrong:

1. The code should be reorganized so that there is a loop that
collects prefixes (cs/ds/es/fs/gs/ss/rep/repz/repnz/addr32/
op32/?lock?) and then does a switch on the real instruction.
It is perfectly valid to put (e.g.) a segment override on
pushf although the prefix doesn't do anything. The current
code just barfs. For the purposes of this function, most of
the prefixes can in fact be ignored.

2. The iret instruction has a 32-bit counterpart, iretd. This
instruction is not currently handled.

Morten Welinder