f248ab1d0dd00b5cb83ff637f17d0dd6f3a27c81
[reactos.git] / reactos / ntoskrnl / ke / i386 / irqhand.s
1
2 #include <internal/i386/segment.h>
3 #include <../hal/halx86/include/halirq.h>
4
5 .global _irq_handler_0
6 _irq_handler_0:
7 cld
8 pusha
9 pushl %ds
10 pushl %es
11 pushl %fs
12 pushl %gs
13 movl $0xceafbeef,%eax
14 pushl %eax
15 movw $KERNEL_DS,%ax
16 movw %ax,%ds
17 movw %ax,%es
18 movw %ax,%gs
19 movl $PCR_SELECTOR, %eax
20 movl %eax, %fs
21 pushl %esp
22 pushl $(IRQ_BASE + 0)
23 call _KiInterruptDispatch
24 popl %eax
25 popl %eax
26 popl %eax
27 popl %gs
28 popl %fs
29 popl %es
30 popl %ds
31 popa
32 iret
33
34 .global _irq_handler_1
35 _irq_handler_1:
36 cld
37 pusha
38 pushl %ds
39 pushl %es
40 pushl %fs
41 pushl %gs
42 movl $0xceafbeef,%eax
43 pushl %eax
44 movw $KERNEL_DS,%ax
45 movw %ax,%ds
46 movw %ax,%es
47 movw %ax,%gs
48 movl $PCR_SELECTOR, %eax
49 movl %eax, %fs
50 pushl %esp
51 pushl $(IRQ_BASE + 1)
52 call _KiInterruptDispatch
53 popl %eax
54 popl %eax
55 popl %eax
56 popl %gs
57 popl %fs
58 popl %es
59 popl %ds
60 popa
61 iret
62
63 .global _irq_handler_2
64 _irq_handler_2:
65 cld
66 pusha
67 pushl %ds
68 pushl %es
69 pushl %fs
70 pushl %gs
71 movl $0xceafbeef,%eax
72 pushl %eax
73 movw $KERNEL_DS,%ax
74 movw %ax,%ds
75 movw %ax,%es
76 movw %ax,%gs
77 movl $PCR_SELECTOR, %eax
78 movl %eax, %fs
79 pushl %esp
80 pushl $(IRQ_BASE + 2)
81 call _KiInterruptDispatch
82 popl %eax
83 popl %eax
84 popl %eax
85 popl %gs
86 popl %fs
87 popl %es
88 popl %ds
89 popa
90 iret
91
92 .global _irq_handler_3
93 _irq_handler_3:
94 cld
95 pusha
96 pushl %ds
97 pushl %es
98 pushl %fs
99 pushl %gs
100 movl $0xceafbeef,%eax
101 pushl %eax
102 movw $KERNEL_DS,%ax
103 movw %ax,%ds
104 movw %ax,%es
105 movw %ax,%gs
106 movl $PCR_SELECTOR, %eax
107 movl %eax, %fs
108 pushl %esp
109 pushl $(IRQ_BASE + 3)
110 call _KiInterruptDispatch
111 popl %eax
112 popl %eax
113 popl %eax
114 popl %gs
115 popl %fs
116 popl %es
117 popl %ds
118 popa
119 iret
120
121 .global _irq_handler_4
122 _irq_handler_4:
123 cld
124 pusha
125 pushl %ds
126 pushl %es
127 pushl %fs
128 pushl %gs
129 movl $0xceafbeef,%eax
130 pushl %eax
131 movw $KERNEL_DS,%ax
132 movw %ax,%ds
133 movw %ax,%es
134 movw %ax,%gs
135 movl $PCR_SELECTOR, %eax
136 movl %eax, %fs
137 pushl %esp
138 pushl $(IRQ_BASE + 4)
139 call _KiInterruptDispatch
140 popl %eax
141 popl %eax
142 popl %eax
143 popl %gs
144 popl %fs
145 popl %es
146 popl %ds
147 popa
148 iret
149
150 .global _irq_handler_5
151 _irq_handler_5:
152 cld
153 pusha
154 pushl %ds
155 pushl %es
156 pushl %fs
157 pushl %gs
158 movl $0xceafbeef,%eax
159 pushl %eax
160 movw $KERNEL_DS,%ax
161 movw %ax,%ds
162 movw %ax,%es
163 movw %ax,%gs
164 movl $PCR_SELECTOR, %eax
165 movl %eax, %fs
166 pushl %esp
167 pushl $(IRQ_BASE + 5)
168 call _KiInterruptDispatch
169 popl %eax
170 popl %eax
171 popl %eax
172 popl %gs
173 popl %fs
174 popl %es
175 popl %ds
176 popa
177 iret
178
179 .global _irq_handler_6
180 _irq_handler_6:
181 cld
182 pusha
183 pushl %ds
184 pushl %es
185 pushl %fs
186 pushl %gs
187 movl $0xceafbeef,%eax
188 pushl %eax
189 movw $KERNEL_DS,%ax
190 movw %ax,%ds
191 movw %ax,%es
192 movw %ax,%gs
193 movl $PCR_SELECTOR, %eax
194 movl %eax, %fs
195 pushl %esp
196 pushl $(IRQ_BASE + 6)
197 call _KiInterruptDispatch
198 popl %eax
199 popl %eax
200 popl %eax
201 popl %gs
202 popl %fs
203 popl %es
204 popl %ds
205 popa
206 iret
207
208 .global _irq_handler_7
209 _irq_handler_7:
210 cld
211 pusha
212 pushl %ds
213 pushl %es
214 pushl %fs
215 pushl %gs
216 movl $0xceafbeef,%eax
217 pushl %eax
218 movw $KERNEL_DS,%ax
219 movw %ax,%ds
220 movw %ax,%es
221 movw %ax,%gs
222 movl $PCR_SELECTOR, %eax
223 movl %eax, %fs
224 pushl %esp
225 pushl $(IRQ_BASE + 7)
226 call _KiInterruptDispatch
227 popl %eax
228 popl %eax
229 popl %eax
230 popl %gs
231 popl %fs
232 popl %es
233 popl %ds
234 popa
235 iret
236
237 .global _irq_handler_8
238 _irq_handler_8:
239 cld
240 pusha
241 pushl %ds
242 pushl %es
243 pushl %fs
244 pushl %gs
245 movl $0xceafbeef,%eax
246 pushl %eax
247 movw $KERNEL_DS,%ax
248 movw %ax,%ds
249 movw %ax,%es
250 movw %ax,%gs
251 movl $PCR_SELECTOR, %eax
252 movl %eax, %fs
253 pushl %esp
254 pushl $(IRQ_BASE + 8)
255 call _KiInterruptDispatch
256 popl %eax
257 popl %eax
258 popl %eax
259 popl %gs
260 popl %fs
261 popl %es
262 popl %ds
263 popa
264 iret
265
266 .global _irq_handler_9
267 _irq_handler_9:
268 cld
269 pusha
270 pushl %ds
271 pushl %es
272 pushl %fs
273 pushl %gs
274 movl $0xceafbeef,%eax
275 pushl %eax
276 movw $KERNEL_DS,%ax
277 movw %ax,%ds
278 movw %ax,%es
279 movw %ax,%gs
280 movl $PCR_SELECTOR, %eax
281 movl %eax, %fs
282 pushl %esp
283 pushl $(IRQ_BASE + 9)
284 call _KiInterruptDispatch
285 popl %eax
286 popl %eax
287 popl %eax
288 popl %gs
289 popl %fs
290 popl %es
291 popl %ds
292 popa
293 iret
294
295 .global _irq_handler_10
296 _irq_handler_10:
297 cld
298 pusha
299 pushl %ds
300 pushl %es
301 pushl %fs
302 pushl %gs
303 movl $0xceafbeef,%eax
304 pushl %eax
305 movw $KERNEL_DS,%ax
306 movw %ax,%ds
307 movw %ax,%es
308 movw %ax,%gs
309 movl $PCR_SELECTOR, %eax
310 movl %eax, %fs
311 pushl %esp
312 pushl $(IRQ_BASE + 10)
313 call _KiInterruptDispatch
314 popl %eax
315 popl %eax
316 popl %eax
317 popl %gs
318 popl %fs
319 popl %es
320 popl %ds
321 popa
322 iret
323
324 .global _irq_handler_11
325 _irq_handler_11:
326 cld
327 pusha
328 pushl %ds
329 pushl %es
330 pushl %fs
331 pushl %gs
332 movl $0xceafbeef,%eax
333 pushl %eax
334 movw $KERNEL_DS,%ax
335 movw %ax,%ds
336 movw %ax,%es
337 movw %ax,%gs
338 movl $PCR_SELECTOR, %eax
339 movl %eax, %fs
340 pushl %esp
341 pushl $(IRQ_BASE + 11)
342 call _KiInterruptDispatch
343 popl %eax
344 popl %eax
345 popl %eax
346 popl %gs
347 popl %fs
348 popl %es
349 popl %ds
350 popa
351 iret
352
353 .global _irq_handler_12
354 _irq_handler_12:
355 cld
356 pusha
357 pushl %ds
358 pushl %es
359 pushl %fs
360 pushl %gs
361 movl $0xceafbeef,%eax
362 pushl %eax
363 movw $KERNEL_DS,%ax
364 movw %ax,%ds
365 movw %ax,%es
366 movw %ax,%gs
367 movl $PCR_SELECTOR, %eax
368 movl %eax, %fs
369 pushl %esp
370 pushl $(IRQ_BASE + 12)
371 call _KiInterruptDispatch
372 popl %eax
373 popl %eax
374 popl %eax
375 popl %gs
376 popl %fs
377 popl %es
378 popl %ds
379 popa
380 iret
381
382 .global _irq_handler_13
383 _irq_handler_13:
384 cld
385 pusha
386 pushl %ds
387 pushl %es
388 pushl %fs
389 pushl %gs
390 movl $0xceafbeef,%eax
391 pushl %eax
392 movw $KERNEL_DS,%ax
393 movw %ax,%ds
394 movw %ax,%es
395 movw %ax,%gs
396 movl $PCR_SELECTOR, %eax
397 movl %eax, %fs
398 pushl %esp
399 pushl $(IRQ_BASE + 13)
400 call _KiInterruptDispatch
401 popl %eax
402 popl %eax
403 popl %eax
404 popl %gs
405 popl %fs
406 popl %es
407 popl %ds
408 popa
409 iret
410
411 .global _irq_handler_14
412 _irq_handler_14:
413 cld
414 pusha
415 pushl %ds
416 pushl %es
417 pushl %fs
418 pushl %gs
419 movl $0xceafbeef,%eax
420 pushl %eax
421 movw $KERNEL_DS,%ax
422 movw %ax,%ds
423 movw %ax,%es
424 movw %ax,%gs
425 movl $PCR_SELECTOR, %eax
426 movl %eax, %fs
427 pushl %esp
428 pushl $(IRQ_BASE + 14)
429 call _KiInterruptDispatch
430 popl %eax
431 popl %eax
432 popl %eax
433 popl %gs
434 popl %fs
435 popl %es
436 popl %ds
437 popa
438 iret
439
440 .global _irq_handler_15
441 _irq_handler_15:
442 cld
443 pusha
444 pushl %ds
445 pushl %es
446 pushl %fs
447 pushl %gs
448 movl $0xceafbeef,%eax
449 pushl %eax
450 movw $KERNEL_DS,%ax
451 movw %ax,%ds
452 movw %ax,%es
453 movw %ax,%gs
454 movl $PCR_SELECTOR, %eax
455 movl %eax, %fs
456 pushl %esp
457 pushl $(IRQ_BASE + 15)
458 call _KiInterruptDispatch
459 popl %eax
460 popl %eax
461 popl %eax
462 popl %gs
463 popl %fs
464 popl %es
465 popl %ds
466 popa
467 iret