root/include/linux/kd.h

/* [previous][next][first][last][top][bottom][index][help] */

INCLUDED FROM


   1 #ifndef _LINUX_KD_H
   2 #define _LINUX_KD_H
   3 
   4 /* 0x4B is 'K', to avoid collision with termios and vt */
   5 
   6 #define SWAPMONO        0x4B00  /* use mca as output device */
   7 #define SWAPCGA         0x4B01  /* use cga as output device */
   8 #define SWAPEGA         0x4B02  /* use ega as output device */
   9 #define SWAPVGA         0x4B03  /* use vga as output device */
  10 #define CONS_CURRENT    0x4B04  /* return current output device */
  11 #define         MONO            0x01
  12 #define         CGA             0x02
  13 #define         EGA             0x03
  14 
  15 #define SW_B40x25       0x4B05  /* 40x25 mono text (cga/ega) */
  16 #define SW_C40x25       0x4B06  /* 40x24 color text (cga/ega) */
  17 #define SW_B80x25       0x4B07  /* 80x25 mono text (cga/ega) */
  18 #define SW_C80x25       0x4B08  /* 80x25 color text (cga/ega) */
  19 #define SW_BG320        0x4B09  /* 320x200 mono graphics (cga/ega) */
  20 #define SW_CG320        0x4B0A  /* 320x200 color graphics (cga/ega) */
  21 #define SW_BG640        0x4B0B  /* 640x200 mono graphics (cga/ega) */
  22 #define SW_CG320_D      0x4B0C  /* 320x200 graphics (ega mode d) */
  23 #define SW_CG640_E      0x4B0D  /* 640x200 graphics (ega mode e) */
  24 #define SW_EGAMONOAPA   0x4B0E  /* 640x350 graphics (ega mode f) */
  25 #define SW_ENH_MONOAPA2 0x4B0F  /* 640x350 graphics extd mem (ega mode f*) */
  26 #define SW_CG640x350    0x4B10  /* 640x350 graphics (ega mode 10) */
  27 #define SW_ENH_CG640    0x4B11  /* 640x350 graphics extd mem (ega mode 10*) */
  28 #define SW_EGAMONO80x25 0x4B12  /* 80x25 mono text (ega mode 7) */
  29 #define SW_ENHB40x25    0x4B13  /* enhanced 40x25 mono text (ega) */
  30 #define SW_ENHC40x25    0x4B14  /* enhanced 40x25 color text (ega) */
  31 #define SW_ENHB80x25    0x4B15  /* enhanced 80x25 mono text (ega) */
  32 #define SW_ENHC80x25    0x4B16  /* enhanced 80x25 color text (ega) */
  33 #define SW_ENHB80x43    0x4B17  /* enhanced 80x43 mono text (ega) */
  34 #define SW_ENHC80x43    0x4B18  /* enhanced 80x43 color text (ega) */
  35 #define SW_MCAMODE      0x4B19  /* reinit mca */
  36 #define SW_ATT640       0x4B1A  /* 640x400 16color */
  37 /* should add more vga modes, etc */
  38 
  39 #define CONS_GET        0x4B1B  /* get current display mode */
  40 #define         M_B40x25        0       /* 40x25 mono (cga/ega) */
  41 #define         M_C40x25        1       /* 40x25 color (cga/ega) */
  42 #define         M_B80x25        2       /* 80x25 mono (cga/ega) */
  43 #define         M_C80x25        3       /* 80x25 color (cga/ega) */
  44 #define         M_BG320         4       /* 320x200 mono (cga/ega) */
  45 #define         M_CG320         5       /* 320x200 color (cga/ega) */
  46 #define         M_BG640         6       /* 640x200 mono (cga/ega) */
  47 #define         M_EGAMONO80x25  7       /* 80x25 mono (ega) */
  48 #define         M_CG320_D       13      /* ega mode d */
  49 #define         M_CG640_E       14      /* ega mode e */
  50 #define         M_EFAMONOAPA    15      /* ega mode f */
  51 #define         M_CG640x350     16      /* ega mode 10 */
  52 #define         M_ENHMONOAPA2   17      /* ega mode f with ext mem */
  53 #define         M_ENH_CG640     18      /* ega mode 10* */
  54 #define         M_ENH_B40x25    19      /* ega enh 40x25 mono */
  55 #define         M_ENH_C40x25    20      /* ega enh 40x25 color */
  56 #define         M_ENH_B80x25    21      /* ega enh 80x25 mono */
  57 #define         M_ENH_C80x25    22      /* ega enh 80x25 color */
  58 #define         M_ENH_B80x43    0x70    /* ega enh 80x43 mono */
  59 #define         M_ENH_C80x43    0x71    /* ega enh 80x43 color */
  60 #define         M_MCA_MODE      0xff    /* monochrome adapter mode */
  61 #define MCA_GET         0x4B1C  /* get mca display mode */
  62 #define CGA_GET         0x4B1D  /* get cga display mode */
  63 #define EGA_GET         0x4B1E  /* get ega display mode */
  64 
  65 #define MAPCONS         0x4B1F  /* map current video mem into address space */
  66 #define MAPMONO         0x4B20  /* map mca video mem into address space */
  67 #define MAPCGA          0x4B21  /* map cga video mem into address space */
  68 #define MAPEGA          0x4B22  /* map ega video mem into address space */
  69 #define MAPVGA          0x4B23  /* map vga video mem into address space */
  70 
  71 struct port_io_struc {
  72         char dir;                       /* direction in vs out */
  73         unsigned short port;
  74         char data;
  75 };
  76 #define         IN_ON_PORT      0x00
  77 #define         OUT_ON_PORT     0x01
  78 struct port_io_arg {
  79         struct port_io_struc args[4];
  80 };
  81 #define MCAIO           0x4B24  /* i/o to mca video board */
  82 #define CGAIO           0x4B25  /* i/o to cga video board */
  83 #define EGAIO           0x4B26  /* i/o to ega video board */
  84 #define VGAIO           0x4B27  /* i/o to vga video board */
  85 
  86 #define GIO_FONT8x8     0x4B28  /* gets current 8x8 font used */
  87 #define PIO_FONT8x8     0x4B29  /* use supplied 8x8 font */
  88 #define GIO_FONT8x14    0x4B2A  /* gets current 8x14 font used */
  89 #define PIO_FONT8x14    0x4B2B  /* use supplied 8x14 font */
  90 #define GIO_FONT8x16    0x4B2C  /* gets current 8x16 font used */
  91 #define PIO_FONT8x16    0x4B2D  /* use supplied 8x16 font */
  92 
  93 #define MKDIOADDR       32      /* io bitmap size from <linux/sched.h> */
  94 struct kd_disparam {
  95         long type;                      /* type of display */
  96         char *addr;                     /* display mem address */
  97         ushort ioaddr[MKDIOADDR];       /* valid i/o addresses */
  98 };
  99 #define KDDISPTYPE      0x4B2E  /* gets display info */
 100 #define         KD_MONO         0x01
 101 #define         KD_HERCULES     0x02
 102 #define         KD_CGA          0x03
 103 #define         KD_EGA          0x04
 104 
 105 #define KIOCSOUND       0x4B2F  /* start sound generation (0 for off) */
 106 #define KDMKTONE        0x4B30  /* generate tone */
 107 
 108 #define KDGETLED        0x4B31  /* return current led flags */
 109 #define KDSETLED        0x4B32  /* set current led flags */
 110 #define         LED_SCR         0x01    /* scroll lock */
 111 #define         LED_CAP         0x04    /* caps lock */
 112 #define         LED_NUM         0x02    /* num lock */
 113 
 114 #define KDGKBTYPE       0x4B33  /* get keyboard type */
 115 #define         KB_84           0x01
 116 #define         KB_101          0x02
 117 #define         KB_OTHER        0x03
 118 
 119 #define KDADDIO         0x4B34  /* add i/o port as valid */
 120 #define KDDELIO         0x4B35  /* del i/o port as valid */
 121 #define KDENABIO        0x4B36  /* enable i/o to video board */
 122 #define KDDISABIO       0x4B37  /* disable i/o to video board */
 123 
 124 struct kd_quemode {
 125         int qsize;              /* desired # elem in queue */
 126         int signo;              /* signal to send when queue not empty */
 127         char *qaddr;            /* user virt addr of queue */
 128 };
 129 #define KDQUEMODE       0x4B38  /* enable/disable special queue mode */
 130 
 131 #define KDSBORDER       0x4B39  /* set screen boarder in ega text mode */
 132 
 133 #define KDSETMODE       0x4B3A  /* set text/grahics mode */
 134 #define         KD_TEXT         0x00
 135 #define         KD_GRAPHICS     0x01
 136 #define         KD_TEXT0        0x02    /* ? */
 137 #define         KD_TEXT1        0x03    /* ? */
 138 #define KDGETMODE       0x4B3B  /* get current mode */
 139 
 140 struct kd_memloc {
 141         char *vaddr;            /* virt addr to map to */
 142         char *physaddr;         /* phys addr to map from */
 143         long length;            /* number of bytes */
 144         long ioflg;             /* enable i/o if set */
 145 };
 146 #define KDMAPDISP       0x4B3C  /* map display into address space */
 147 #define KDUNMAPDISP     0x4B3D  /* unmap display from address space */
 148 
 149 #define KDVDCTYPE       0x4B3E  /* return vdc controller/display info */
 150 
 151 #define KIOCINFO        0x4B3F  /* tell what the device is */
 152 
 153 typedef char scrnmap_t;
 154 #define         E_TABSZ         256
 155 #define GIO_SCRNMAP     0x4B40  /* get screen mapping from kernel */
 156 #define PIO_SCRNMAP     0x4B41  /* put screen mapping table in kernel */
 157 
 158 #define GIO_ATTR        0x4B42  /* get screen attributes */
 159 #define GIO_COLOR       0x4B43  /* return nonzero if display is color */
 160 
 161 #define         K_RAW           0x00
 162 #define         K_XLATE         0x01
 163 #define         K_MEDIUMRAW     0x02
 164 #define KDGKBMODE       0x4B44  /* gets current keyboard mode */
 165 #define KDSKBMODE       0x4B45  /* sets current keyboard mode */
 166 
 167 struct kbentry {
 168         u_char kb_table;
 169         u_char kb_index;
 170         u_short kb_value;
 171 };
 172 #define         K_NORMTAB       0x00
 173 #define         K_SHIFTTAB      0x01
 174 #define         K_ALTTAB        0x02
 175 #define         K_ALTSHIFTTAB   0x03
 176 #define         K_SRQTAB        0x04
 177 #define KDGKBENT        0x4B46  /* gets one entry in translation table */
 178 #define KDSKBENT        0x4B47  /* sets one entry in translation table */
 179 
 180 struct kbsentry {
 181         u_char kb_func;
 182         u_char kb_string[512];  /* FUNC_BUFSIZE from keyboard.h */
 183 };
 184 #define KDGKBSENT       0x4B48  /* gets one function key string entry */
 185 #define KDSKBSENT       0x4B49  /* sets one function key string entry */
 186 
 187 #endif /* _LINUX_KD_H */

/* [previous][next][first][last][top][bottom][index][help] */