Subversion Repositories shark

Rev

Rev 41 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1063 tullio 1
 
2
/*
3
 * This program is free software; you can redistribute it and/or modify
4
 * it under the terms of the GNU General Public License as published by
5
 * the Free Software Foundation; either version 2 of the License, or
6
 * (at your option) any later version.
7
 *
8
 * This program is distributed in the hope that it will be useful,
9
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11
 * GNU General Public License for more details.
12
 *
13
 * You should have received a copy of the GNU General Public License
14
 * along with this program; if not, write to the Free Software
15
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
16
 *
17
 */
18
 
41 pj 19
#include <ll/i386/hw-data.h>
20
#include <ll/i386/hw-func.h>
21
 
22
/* ll hardware interrupt hooks  */
23
extern void h0(void);
24
extern void h1(void);
25
extern void h2(void);
26
extern void h3(void);
27
extern void h4(void);
28
extern void h5(void);
29
extern void h6(void);
30
extern void exc7(void);
31
extern void h8(void);
32
extern void h9(void);
33
extern void h10(void);
34
extern void h11(void);
35
extern void h12(void);
36
extern void h13(void);
37
extern void h14(void);
38
extern void h15(void);
39
extern void h16(void);
40
extern void h17(void);
41
extern void h18(void);
42
extern void h19(void);
43
extern void h20(void);
44
extern void h21(void);
45
extern void h22(void);
46
extern void h23(void);
47
extern void h24(void);
48
extern void h25(void);
49
extern void h26(void);
50
extern void h27(void);
51
extern void h28(void);
52
extern void h29(void);
53
extern void h30(void);
54
extern void h31(void);
55
extern void h32(void);
56
extern void h33(void);
57
extern void h34(void);
58
extern void h35(void);
59
extern void h36(void);
60
extern void h37(void);
61
extern void h38(void);
62
extern void h39(void);
63
extern void h40(void);
64
extern void h41(void);
65
extern void h42(void);
66
extern void h43(void);
67
extern void h44(void);
68
extern void h45(void);
69
extern void h46(void);
70
extern void h47(void);
71
extern void h48(void);
72
extern void h49(void);
73
extern void h50(void);
74
extern void h51(void);
75
extern void h52(void);
76
extern void h53(void);
77
extern void h54(void);
78
extern void h55(void);
79
extern void h56(void);
80
extern void h57(void);
81
extern void h58(void);
82
extern void h59(void);
83
extern void h60(void);
84
extern void h61(void);
85
extern void h62(void);
86
extern void h63(void);
87
extern void h64(void);
88
extern void h65(void);
89
extern void h66(void);
90
extern void h67(void);
91
extern void h68(void);
92
extern void h69(void);
93
extern void h70(void);
94
extern void h71(void);
95
extern void h72(void);
96
extern void h73(void);
97
extern void h74(void);
98
extern void h75(void);
99
extern void h76(void);
100
extern void h77(void);
101
extern void h78(void);
102
extern void h79(void);
103
extern void h80(void);
104
extern void h81(void);
105
extern void h82(void);
106
extern void h83(void);
107
extern void h84(void);
108
extern void h85(void);
109
extern void h86(void);
110
extern void h87(void);
111
extern void h88(void);
112
extern void h89(void);
113
extern void h90(void);
114
extern void h91(void);
115
extern void h92(void);
116
extern void h93(void);
117
extern void h94(void);
118
extern void h95(void);
119
extern void h96(void);
120
extern void h97(void);
121
extern void h98(void);
122
extern void h99(void);
123
extern void h100(void);
124
extern void h101(void);
125
extern void h102(void);
126
extern void h103(void);
127
extern void h104(void);
128
extern void h105(void);
129
extern void h106(void);
130
extern void h107(void);
131
extern void h108(void);
132
extern void h109(void);
133
extern void h110(void);
134
extern void h111(void);
135
extern void h112(void);
136
extern void h113(void);
137
extern void h114(void);
138
extern void h115(void);
139
extern void h116(void);
140
extern void h117(void);
141
extern void h118(void);
142
extern void h119(void);
143
extern void h120(void);
144
extern void h121(void);
145
extern void h122(void);
146
extern void h123(void);
147
extern void h124(void);
148
extern void h125(void);
149
extern void h126(void);
150
extern void h127(void);
151
extern void h128(void);
152
extern void h129(void);
153
extern void h130(void);
154
extern void h131(void);
155
extern void h132(void);
156
extern void h133(void);
157
extern void h134(void);
158
extern void h135(void);
159
extern void h136(void);
160
extern void h137(void);
161
extern void h138(void);
162
extern void h139(void);
163
extern void h140(void);
164
extern void h141(void);
165
extern void h142(void);
166
extern void h143(void);
167
extern void h144(void);
168
extern void h145(void);
169
extern void h146(void);
170
extern void h147(void);
171
extern void h148(void);
172
extern void h149(void);
173
extern void h150(void);
174
extern void h151(void);
175
extern void h152(void);
176
extern void h153(void);
177
extern void h154(void);
178
extern void h155(void);
179
extern void h156(void);
180
extern void h157(void);
181
extern void h158(void);
182
extern void h159(void);
183
extern void h160(void);
184
extern void h161(void);
185
extern void h162(void);
186
extern void h163(void);
187
extern void h164(void);
188
extern void h165(void);
189
extern void h166(void);
190
extern void h167(void);
191
extern void h168(void);
192
extern void h169(void);
193
extern void h170(void);
194
extern void h171(void);
195
extern void h172(void);
196
extern void h173(void);
197
extern void h174(void);
198
extern void h175(void);
199
extern void h176(void);
200
extern void h177(void);
201
extern void h178(void);
202
extern void h179(void);
203
extern void h180(void);
204
extern void h181(void);
205
extern void h182(void);
206
extern void h183(void);
207
extern void h184(void);
208
extern void h185(void);
209
extern void h186(void);
210
extern void h187(void);
211
extern void h188(void);
212
extern void h189(void);
213
extern void h190(void);
214
extern void h191(void);
215
extern void h192(void);
216
extern void h193(void);
217
extern void h194(void);
218
extern void h195(void);
219
extern void h196(void);
220
extern void h197(void);
221
extern void h198(void);
222
extern void h199(void);
223
extern void h200(void);
224
extern void h201(void);
225
extern void h202(void);
226
extern void h203(void);
227
extern void h204(void);
228
extern void h205(void);
229
extern void h206(void);
230
extern void h207(void);
231
extern void h208(void);
232
extern void h209(void);
233
extern void h210(void);
234
extern void h211(void);
235
extern void h212(void);
236
extern void h213(void);
237
extern void h214(void);
238
extern void h215(void);
239
extern void h216(void);
240
extern void h217(void);
241
extern void h218(void);
242
extern void h219(void);
243
extern void h220(void);
244
extern void h221(void);
245
extern void h222(void);
246
extern void h223(void);
247
extern void h224(void);
248
extern void h225(void);
249
extern void h226(void);
250
extern void h227(void);
251
extern void h228(void);
252
extern void h229(void);
253
extern void h230(void);
254
extern void h231(void);
255
extern void h232(void);
256
extern void h233(void);
257
extern void h234(void);
258
extern void h235(void);
259
extern void h236(void);
260
extern void h237(void);
261
extern void h238(void);
262
extern void h239(void);
263
extern void h240(void);
264
extern void h241(void);
265
extern void h242(void);
266
extern void h243(void);
267
extern void h244(void);
268
extern void h245(void);
269
extern void h246(void);
270
extern void h247(void);
271
extern void h248(void);
272
extern void h249(void);
273
extern void h250(void);
274
extern void h251(void);
275
extern void h252(void);
276
extern void h253(void);
277
extern void h254(void);
278
extern void h255(void);
279
 
280
void IDT_init(void)
281
{
282
  /* Insert the Exceptions handler into IDT */
283
  IDT_place(0x00, h0);
284
  IDT_place(0x01, h1);
285
  IDT_place(0x02, h2);
286
  IDT_place(0x03, h3);
287
  IDT_place(0x04, h4);
288
  IDT_place(0x05, h5);
289
  IDT_place(0x06, h6);
290
  IDT_place(0x07, exc7);
291
  IDT_place(0x08, h8);
292
  IDT_place(0x09, h9);
293
  IDT_place(0x0A, h10);
294
  IDT_place(0x0B, h11);
295
  IDT_place(0x0C, h12);
296
  IDT_place(0x0D, h13);
297
  IDT_place(0x0E, h14);
298
  IDT_place(0x0F, h15);
299
  IDT_place(0x10, h16);
300
  IDT_place(0x11, h17);
301
  IDT_place(0x12, h18);
302
  IDT_place(0x13, h19);
303
  IDT_place(0x14, h20);
304
  IDT_place(0x15, h21);
305
  IDT_place(0x16, h22);
306
  IDT_place(0x17, h23);
307
  IDT_place(0x18, h24);
308
  IDT_place(0x19, h25);
309
  IDT_place(0x1A, h26);
310
  IDT_place(0x1B, h27);
311
  IDT_place(0x1C, h28);
312
  IDT_place(0x1D, h29);
313
  IDT_place(0x1E, h30);
314
  IDT_place(0x1F, h31);
315
 
316
  IDT_place(0x20, h32);
317
  IDT_place(0x21, h33);
318
  IDT_place(0x22, h34);
319
  IDT_place(0x23, h35);
320
  IDT_place(0x24, h36);
321
  IDT_place(0x25, h37);
322
  IDT_place(0x26, h38);
323
  IDT_place(0x27, h39);
324
  IDT_place(0x28, h40);
325
  IDT_place(0x29, h41);
326
  IDT_place(0x2A, h42);
327
  IDT_place(0x2B, h43);
328
  IDT_place(0x2C, h44);
329
  IDT_place(0x2D, h45);
330
  IDT_place(0x2E, h46);
331
  IDT_place(0x2F, h47);
332
  IDT_place(0x30, h48);
333
  IDT_place(0x31, h49);
334
  IDT_place(0x32, h50);
335
  IDT_place(0x33, h51);
336
  IDT_place(0x34, h52);
337
  IDT_place(0x35, h53);
338
  IDT_place(0x36, h54);
339
  IDT_place(0x37, h55);
340
  IDT_place(0x38, h56);
341
  IDT_place(0x39, h57);
342
  IDT_place(0x3A, h58);
343
  IDT_place(0x3B, h59);
344
  IDT_place(0x3C, h60);
345
  IDT_place(0x3D, h61);
346
  IDT_place(0x3E, h62);
347
  IDT_place(0x3F, h63);
348
 
349
  IDT_place(0x40, h64);
350
  IDT_place(0x41, h65);
351
  IDT_place(0x42, h66);
352
  IDT_place(0x43, h67);
353
  IDT_place(0x44, h68);
354
  IDT_place(0x45, h69);
355
  IDT_place(0x46, h70);
356
  IDT_place(0x47, h71);
357
 
358
  IDT_place(0x48, h72);
359
  IDT_place(0x49, h73);
360
  IDT_place(0x4A, h74);
361
  IDT_place(0x4B, h75);
362
  IDT_place(0x4C, h76);
363
  IDT_place(0x4D, h77);
364
  IDT_place(0x4E, h78);
365
  IDT_place(0x4F, h79);
366
  IDT_place(0x50, h80);
367
  IDT_place(0x51, h81);
368
  IDT_place(0x52, h82);
369
  IDT_place(0x53, h83);
370
  IDT_place(0x54, h84);
371
  IDT_place(0x55, h85);
372
  IDT_place(0x56, h86);
373
  IDT_place(0x57, h87);
374
  IDT_place(0x58, h88);
375
  IDT_place(0x59, h89);
376
  IDT_place(0x5A, h90);
377
  IDT_place(0x5B, h91);
378
  IDT_place(0x5C, h92);
379
  IDT_place(0x5D, h93);
380
  IDT_place(0x5E, h94);
381
  IDT_place(0x5F, h95);
382
  IDT_place(0x60, h96);
383
  IDT_place(0x61, h97);
384
  IDT_place(0x62, h98);
385
  IDT_place(0x63, h99);
386
  IDT_place(0x64, h100);
387
  IDT_place(0x65, h101);
388
  IDT_place(0x66, h102);
389
  IDT_place(0x67, h103);
390
  IDT_place(0x68, h104);
391
  IDT_place(0x69, h105);
392
  IDT_place(0x6A, h106);
393
  IDT_place(0x6B, h107);
394
  IDT_place(0x6C, h108);
395
  IDT_place(0x6D, h109);
396
  IDT_place(0x6E, h110);
397
  IDT_place(0x6F, h111);
398
 
399
  IDT_place(0x70, h112);
400
  IDT_place(0x71, h113);
401
  IDT_place(0x72, h114);
402
  IDT_place(0x73, h115);
403
  IDT_place(0x74, h116);
404
  IDT_place(0x75, h117);
405
  IDT_place(0x76, h118);
406
  IDT_place(0x77, h119);
407
 
408
  IDT_place(0x78, h120);
409
  IDT_place(0x79, h121);
410
  IDT_place(0x7A, h122);
411
  IDT_place(0x7B, h123);
412
  IDT_place(0x7C, h124);
413
  IDT_place(0x7D, h125);
414
  IDT_place(0x7E, h127);
415
  IDT_place(0x7F, h127);
416
  IDT_place(0x80, h128);
417
  IDT_place(0x81, h129);
418
  IDT_place(0x82, h130);
419
  IDT_place(0x83, h131);
420
  IDT_place(0x84, h132);
421
  IDT_place(0x85, h133);
422
  IDT_place(0x86, h134);
423
  IDT_place(0x87, h135);
424
  IDT_place(0x88, h136);
425
  IDT_place(0x89, h137);
426
  IDT_place(0x8A, h138);
427
  IDT_place(0x8B, h139);
428
  IDT_place(0x8C, h140);
429
  IDT_place(0x8D, h141);
430
  IDT_place(0x8E, h142);
431
  IDT_place(0x8F, h143);
432
  IDT_place(0x90, h144);
433
  IDT_place(0x91, h145);
434
  IDT_place(0x92, h146);
435
  IDT_place(0x93, h147);
436
  IDT_place(0x94, h148);
437
  IDT_place(0x95, h149);
438
  IDT_place(0x96, h150);
439
  IDT_place(0x97, h151);
440
  IDT_place(0x98, h152);
441
  IDT_place(0x99, h153);
442
  IDT_place(0x9A, h154);
443
  IDT_place(0x9B, h155);
444
  IDT_place(0x9C, h156);
445
  IDT_place(0x9D, h157);
446
  IDT_place(0x9E, h158);
447
  IDT_place(0x9F, h159);
448
  IDT_place(0xA0, h160);
449
  IDT_place(0xA1, h161);
450
  IDT_place(0xA2, h162);
451
  IDT_place(0xA3, h163);
452
  IDT_place(0xA4, h164);
453
  IDT_place(0xA5, h165);
454
  IDT_place(0xA6, h166);
455
  IDT_place(0xA7, h167);
456
  IDT_place(0xA8, h168);
457
  IDT_place(0xA9, h169);
458
  IDT_place(0xAA, h170);
459
  IDT_place(0xAB, h171);
460
  IDT_place(0xAC, h172);
461
  IDT_place(0xAD, h173);
462
  IDT_place(0xAE, h174);
463
  IDT_place(0xAF, h175);
464
  IDT_place(0xB0, h176);
465
  IDT_place(0xB1, h177);
466
  IDT_place(0xB2, h178);
467
  IDT_place(0xB3, h179);
468
  IDT_place(0xB4, h180);
469
  IDT_place(0xB5, h181);
470
  IDT_place(0xB6, h182);
471
  IDT_place(0xB7, h183);
472
  IDT_place(0xB8, h184);
473
  IDT_place(0xB9, h185);
474
  IDT_place(0xBA, h186);
475
  IDT_place(0xBB, h187);
476
  IDT_place(0xBC, h188);
477
  IDT_place(0xBD, h189);
478
  IDT_place(0xBE, h190);
479
  IDT_place(0xBF, h191);
480
  IDT_place(0xC0, h192);
481
  IDT_place(0xC1, h193);
482
  IDT_place(0xC2, h194);
483
  IDT_place(0xC3, h195);
484
  IDT_place(0xC4, h196);
485
  IDT_place(0xC5, h197);
486
  IDT_place(0xC6, h198);
487
  IDT_place(0xC7, h199);
488
  IDT_place(0xC8, h200);
489
  IDT_place(0xC9, h201);
490
  IDT_place(0xCA, h202);
491
  IDT_place(0xCB, h203);
492
  IDT_place(0xCC, h204);
493
  IDT_place(0xCD, h205);
494
  IDT_place(0xCE, h206);
495
  IDT_place(0xCF, h207);
496
  IDT_place(0xD0, h208);
497
  IDT_place(0xD1, h209);
498
  IDT_place(0xD2, h210);
499
  IDT_place(0xD3, h211);
500
  IDT_place(0xD4, h212);
501
  IDT_place(0xD5, h213);
502
  IDT_place(0xD6, h214);
503
  IDT_place(0xD7, h215);
504
  IDT_place(0xD8, h216);
505
  IDT_place(0xD9, h217);
506
  IDT_place(0xDA, h218);
507
  IDT_place(0xDB, h219);
508
  IDT_place(0xDC, h220);
509
  IDT_place(0xDD, h221);
510
  IDT_place(0xDE, h222);
511
  IDT_place(0xDF, h223);
512
  IDT_place(0xE0, h224);
513
  IDT_place(0xE1, h225);
514
  IDT_place(0xE2, h226);
515
  IDT_place(0xE3, h227);
516
  IDT_place(0xE4, h228);
517
  IDT_place(0xE5, h229);
518
  IDT_place(0xE6, h230);
519
  IDT_place(0xE7, h231);
520
  IDT_place(0xE8, h232);
521
  IDT_place(0xE9, h233);
522
  IDT_place(0xEA, h234);
523
  IDT_place(0xEB, h235);
524
  IDT_place(0xEC, h236);
525
  IDT_place(0xED, h237);
526
  IDT_place(0xEE, h238);
527
  IDT_place(0xEF, h239);
528
  IDT_place(0xF0, h240);
529
  IDT_place(0xF1, h241);
530
  IDT_place(0xF2, h242);
531
  IDT_place(0xF3, h243);
532
  IDT_place(0xF4, h244);
533
  IDT_place(0xF5, h245);
534
  IDT_place(0xF6, h246);
535
  IDT_place(0xF7, h247);
536
  IDT_place(0xF8, h248);
537
  IDT_place(0xF9, h249);
538
  IDT_place(0xFA, h250);
539
  IDT_place(0xFB, h251);
540
  IDT_place(0xFC, h252);
541
  IDT_place(0xFD, h253);
542
  IDT_place(0xFE, h254);
543
  IDT_place(0xFF, h255);
544
}