]> git.hungrycats.org Git - linux/commitdiff
[PATCH] vm86: set IOPL to 3 on pushf
authorStas Sergeev <stsp@aknet.ru>
Fri, 2 Jul 2004 03:36:25 +0000 (20:36 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Fri, 2 Jul 2004 03:36:25 +0000 (20:36 -0700)
The attached patch fixes the pushf under v86 to always set the IOPL field
to 3, as the Intel CPUs do.

It was in 2.4 for year, but somehow missed 2.6.  It comes from here
(although now a bit shorter):

http://lkml.org/lkml/2003/5/25/81

Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
arch/i386/kernel/vm86.c

index a4f5a20a263f64526269e6d27f73695c6f2e756a..4484e47a77c57506960d4ec3cca23abeed48b669 100644 (file)
@@ -394,6 +394,7 @@ static inline unsigned long get_vflags(struct kernel_vm86_regs * regs)
 
        if (VEFLAGS & VIF_MASK)
                flags |= IF_MASK;
+       flags |= IOPL_MASK;
        return flags | (VEFLAGS & current->thread.v86mask);
 }