summaryrefslogtreecommitdiffstats
path: root/lib/libc/i386
diff options
context:
space:
mode:
authormdodd <mdodd@FreeBSD.org>2003-04-29 08:35:28 +0000
committermdodd <mdodd@FreeBSD.org>2003-04-29 08:35:28 +0000
commitac3f359209bac4b38ad477c68283e2f558080df1 (patch)
tree38a2b6dfb72f3de189f358feabe890d294bccb27 /lib/libc/i386
parent434086177ff1782e5033d3ef3944a029b263f85b (diff)
downloadFreeBSD-src-ac3f359209bac4b38ad477c68283e2f558080df1.zip
FreeBSD-src-ac3f359209bac4b38ad477c68283e2f558080df1.tar.gz
Document VM86_INTCALL.
Submitted by: Bruce M Simpson
Diffstat (limited to 'lib/libc/i386')
-rw-r--r--lib/libc/i386/sys/i386_vm86.239
1 files changed, 35 insertions, 4 deletions
diff --git a/lib/libc/i386/sys/i386_vm86.2 b/lib/libc/i386/sys/i386_vm86.2
index ab22633..e78c0fc 100644
--- a/lib/libc/i386/sys/i386_vm86.2
+++ b/lib/libc/i386/sys/i386_vm86.2
@@ -79,9 +79,38 @@ in vm86 mode, or reflected back to the process. If the
.Em Nth
bit is set, the interrupt will be reflected to the process, otherwise
it will be dispatched by the vm86 interrupt table.
-.\" .It Dv VM86_SET_VME
-.\" .It Dv VM86_GET_VME
-.\" .It Dv VM86_INTCALL
+.It Dv VM86_INTCALL
+This allows calls to be made to vm86 interrupt handlers by the process. It
+effectively simulates an INT instruction.
+.Fa data
+should point to the following structure:
+.Bd -literal
+struct vm86_intcall_args {
+ int intnum;
+ struct vm86frame vmf;
+};
+.Ed
+.Pp
+.Fa intnum
+specifies the operand of INT for the simulated call. A value of 0x10, for
+example, would often be used to call into the VGA BIOS.
+.Fa vmf
+is used to initialize CPU registers according to the calling convention for
+the interrupt handler.
+.It Dv VM86_GET_VME
+This is used to retrieve the current state of the Pentium(r) processor's
+VME (Virtual-8086 Mode Extensions) flag, which is bit 0 of CR4.
+.Fa data
+should be initialized to point to the following:
+.Bd -literal
+struct vm86_vme_args {
+ int state; /* status */
+};
+.Ed
+.Pp
+.Fa state
+will contain the state of the VME flag on return.
+\" .It Dv VM86_SET_VME
.El
.Pp
vm86 mode is entered by calling
@@ -104,4 +133,6 @@ There is not enough memory to initialize the kernel data structures.
.El
.Sh AUTHORS
This man page was written by
-.An Jonathan Lemon .
+.An Jonathan Lemon ,
+and updated by
+.An Bruce M Simpson .
OpenPOWER on IntegriCloud