Disable the vnc CopyRect encoding
[qemu-kvm/fedora.git] / tests / test-i386-vm86.S
blob3bb96c99277798cdc562ab22453c26f896e875c0
1         .code16
2         .globl vm86_code_start
3         .globl vm86_code_end
5 #define GET_OFFSET(x) ((x) - vm86_code_start + 0x100)
7 vm86_code_start:
8         movw $GET_OFFSET(hello_world), %dx
9         movb $0x09, %ah
10         int $0x21
12         /* prepare int 0x90 vector */
13         xorw %ax, %ax
14         movw %ax, %es
15         es movw $GET_OFFSET(int90_test), 0x90 * 4
16         es movw %cs, 0x90 * 4 + 2
18         /* launch int 0x90 */
20         int $0x90
22         /* test IF support */
23         movw $GET_OFFSET(IF_msg), %dx
24         movb $0x09, %ah
25         int $0x21
27         pushf
28         popw %dx
29         movb $0xff, %ah
30         int $0x21
32         cli
33         pushf
34         popw %dx
35         movb $0xff, %ah
36         int $0x21
38         sti
39         pushfl
40         popl %edx
41         movb $0xff, %ah
42         int $0x21
44 #if 0
45         movw $GET_OFFSET(IF_msg1), %dx
46         movb $0x09, %ah
47         int $0x21
49         pushf
50         movw %sp, %bx
51         andw $~0x200, (%bx)
52         popf
53 #else
54         cli
55 #endif
57         pushf
58         popw %dx
59         movb $0xff, %ah
60         int $0x21
62         pushfl
63         movw %sp, %bx
64         orw $0x200, (%bx)
65         popfl
67         pushfl
68         popl %edx
69         movb $0xff, %ah
70         int $0x21
72         movb $0x00, %ah
73         int $0x21
75 int90_test:
76         pushf
77         pop %dx
78         movb $0xff, %ah
79         int $0x21
81         movw %sp, %bx
82         movw 4(%bx), %dx
83         movb $0xff, %ah
84         int $0x21
86         movw $GET_OFFSET(int90_msg), %dx
87         movb $0x09, %ah
88         int $0x21
89         iret
91 int90_msg:
92         .string "INT90 started\n$"
94 hello_world:
95         .string "Hello VM86 world\n$"
97 IF_msg:
98         .string "VM86 IF test\n$"
100 IF_msg1:
101         .string "If you see a diff here, your Linux kernel is buggy, please update to 2.4.20 kernel\n$"
103 vm86_code_end: