Re: V86 BIOS works; but we need an IOPL solution!!

Kendall Bennett (KendallB@scitechsoft.com)
Fri, 17 Jul 1998 11:29:40 -0800


> Kendal, to implement full iopl priviledges for vm86 mode execution, does
> the following test-mini-patch help?
>
> in 2.1.109, arch/i386/kernel/vm86.c, line 233:
>
> case CPU_286:
> tsk->tss.v86mask = 0;
> break;
>
> if you change this to:
>
> case CPU_286:
> tsk->tss.v86mask = IOPL_MASK;
> break;
>
> does the BIOS work now?

I will try this (we just downloaded the 2.1.109 sources), however
IOPL does not affect the V86 task except for the use of the cli/sti
instructions. If IOPL=3 for the V86 code, then these do not fault and
modify the real interrupt flag. However all I/O port accesses will
fault unless the bitmap says otherwise.

I have been reading up on this yesterday, and because of the design
of the CPU the only solultion is to enlarge the bitmap to 8Kb for the
V86 code.

Does Linux use a separate TSS for every task in the system (ie: even
for apps that use multiple threads)? I think the way Win95 and Win32
work is that there is only a single TSS per 'Virtual Machine' and
mutiple apps are multi-tasked within the same VM. All DOS boxes run
in their own VM, however all Win16/Win32 apps run in the main system
VM. On NT I believe all 32-bit apps run in the same VM also (with
separate page tables for private memory), however Win16 apps run in a
separate VM and can be made to run every app in a separate VM for
crash protection (yeah right, like NT is crash proof!).

Regards,

+--------------------------------------------------------------------------+
| SciTech Software - Building Truly Plug'n'Play Software! |
+--------------------------------------------------------------------------+
| Kendall Bennett | Email: KendallB@scitechsoft.com |
| Director of Engineering | Phone: (530) 894 8400 |
| SciTech Software, Inc. | Fax : (530) 894 9069 |
| 505 Wall Street | ftp : ftp.scitechsoft.com |
| Chico, CA 95928, USA | www : http://www.scitechsoft.com |
+--------------------------------------------------------------------------+

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.altern.org/andrebalsa/doc/lkml-faq.html