summaryrefslogtreecommitdiffstats
path: root/sys/boot/i386/btx/lib/btxv86.h
blob: 70c21879d397a5bb49af64b2e07aa29092e40f86 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
/*
 * Copyright (c) 1998 Robert Nordier
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms are freely
 * permitted provided that the above copyright notice and this
 * paragraph and the following disclaimer are duplicated in all
 * such forms.
 *
 * This software is provided "AS IS" and without any express or
 * implied warranties, including, without limitation, the implied
 * warranties of merchantability and fitness for a particular
 * purpose.
 */

/*
 *	$Id:$
 */

#ifndef _BTXV86_H_
#define _BTXV86_H_

#include <sys/types.h>

#define V86_ADDR   0x10000	/* Segment:offset address */
#define V86_CALLF  0x20000	/* Emulate far call */
#define V86_FLAGS  0x40000	/* Return flags */

struct __v86 {
    uint32_t ctl;		/* Control flags */
    uint32_t addr;		/* Interrupt number or address */
    uint32_t es;		/* V86 ES register */
    uint32_t ds;		/* V86 DS register */
    uint32_t fs;		/* V86 FS register */
    uint32_t gs;		/* V86 GS register */
    uint32_t eax;		/* V86 EAX register */
    uint32_t ecx;		/* V86 ECX register */
    uint32_t edx;		/* V86 EDX register */
    uint32_t ebx;		/* V86 EBX register */
    uint32_t efl;		/* V86 eflags register */
    uint32_t ebp;		/* V86 EBP register */
    uint32_t esi;		/* V86 ESI register */
    uint32_t edi;		/* V86 EDI register */
};

extern struct __v86 __v86;	/* V86 interface structure */

void __exit(int);
void __exec(caddr_t, ...);

void __v86int(void);

#endif /* !_BTXV86_H_ */
OpenPOWER on IntegriCloud