kernel: print spurious interrupt message with increasing interval.
[minix.git] / include / arch / i386 / archtypes.h
blob3300a2ebb85a73b0a5716302963a20fa3c005a52
2 #ifndef _I386_TYPES_H
3 #define _I386_TYPES_H
5 #include <minix/sys_config.h>
6 #include <machine/stackframe.h>
7 #include <machine/fpu.h>
9 struct segdesc_s { /* segment descriptor for protected mode */
10 u16_t limit_low;
11 u16_t base_low;
12 u8_t base_middle;
13 u8_t access; /* |P|DL|1|X|E|R|A| */
14 u8_t granularity; /* |G|X|0|A|LIMT| */
15 u8_t base_high;
18 #define LDT_SIZE (2 + NR_REMOTE_SEGS) /* CS, DS and remote segments */
20 /* Fixed local descriptors. */
21 #define CS_LDT_INDEX 0 /* process CS */
22 #define DS_LDT_INDEX 1 /* process DS=ES=FS=GS=SS */
23 #define EXTRA_LDT_INDEX 2 /* first of the extra LDT entries */
25 typedef struct segframe {
26 reg_t p_ldt_sel; /* selector in gdt with ldt base and limit */
27 reg_t p_cr3; /* page table root */
28 struct segdesc_s p_ldt[LDT_SIZE]; /* CS, DS and remote */
29 } segframe_t;
31 /* fpu_state_s is used in kernel proc table.
32 * Any changes in this structure requires changes in sconst.h,
33 * since this structure is used in proc structure. */
34 struct fpu_state_s {
35 union fpu_state_u *fpu_save_area_p; /* 16-aligned fpu_save_area */
36 /* fpu_image includes 512 bytes of image itself and
37 * additional 15 bytes required for manual 16-byte alignment. */
38 char fpu_image[527];
41 #define INMEMORY(p) (!p->p_seg.p_cr3 || ptproc == p)
43 #endif /* #ifndef _I386_TYPES_H */