Debian Codegraph @

upstream/debian-unstable/man2/vm86.2

raw
1 .\" Copyright 1993, Rickard E. Faith <[email protected]>
2 .\" Copyright 1997, Andries E. Brouwer <[email protected]>
3 .\" Copyright, the authors of the Linux man-pages project
4 .\"
5 .\" SPDX-License-Identifier: Linux-man-pages-copyleft
6 .\"
7 .TH vm86 2 2026-02-08 "Linux man-pages 6.18"
8 .SH NAME
9 vm86old, vm86 \- enter virtual 8086 mode
10 .SH LIBRARY
11 Standard C library
12 .RI ( libc ,\~ \-lc )
13 .SH SYNOPSIS
14 .nf
15 .B #include <sys/vm86.h>
16 .P
17 .BI "int vm86old(struct vm86_struct *" info );
18 .BI "int vm86(unsigned long " fn ", struct vm86plus_struct *" v86 );
19 .fi
20 .SH DESCRIPTION
21 The system call
22 .BR vm86 ()
23 was introduced in Linux 0.97p2.
24 In Linux 2.1.15 and 2.0.28, it was renamed to
25 .BR vm86old (),
26 and a new
27 .BR vm86 ()
28 was introduced.
29 The definition of
30 .I struct vm86_struct
31 was changed
32 in 1.1.8 and 1.1.9.
33 .P
34 These calls cause the process to enter VM86 mode (virtual-8086 in Intel
35 literature), and are used by
36 .BR dosemu .
37 .P
38 VM86 mode is an emulation of real mode within a protected mode task.
39 .SH RETURN VALUE
40 On success, zero is returned.
41 On error, \-1 is returned, and
42 .I errno
43 is set to indicate the error.
44 .SH ERRORS
45 .TP
46 .B EFAULT
47 This return value is specific to i386 and indicates a problem with getting
48 user-space data.
49 .TP
50 .B ENOSYS
51 This return value indicates the call is not implemented on the present
52 architecture.
53 .TP
54 .B EPERM
55 Saved kernel stack exists.
56 (This is a kernel sanity check;
57 the saved stack
58 should exist only within vm86 mode itself.)
59 .SH STANDARDS
60 Linux on 32-bit Intel processors.