1 /* 2 * 3 * Author: Davor Matic, dmatic@athena.mit.edu 4 * 5 * $XFree86: mit/server/ddx/x386/hga2/hga/hga.h,v 2.3 1993/08/16 14:39:43 dawes Exp $ 6 */ 7 8 #define HGA2_PATCHLEVEL "0" 9 10 #include "X.h" 11 #include "misc.h" 12 #include "x386.h" 13 14 extern Bool hgaProbe(); 15 extern void hgaPrintIdent(); 16 extern Bool hgaScreenInit(); 17 extern void hgaEnterLeaveVT(); 18 19 extern Bool hgaSaveScreen(); 20 extern Bool hgaCloseScreen(); 21 22 extern Bool hgaHWInit(); 23 extern void hgaHWRestore(); 24 extern void * hgaHWSave(); 25 26 extern int hga2ValidTokens[]; 27 28 /* 29 * structure for accessing the video chip`s functions 30 */ 31 typedef struct { 32 Bool (* ChipProbe)(); 33 char * (* ChipIdent)(); 34 void (* ChipEnterLeave)(); 35 Bool (* ChipInit)(); 36 void * (* ChipSave)(); 37 void (* ChipRestore)(); 38 } hgaVideoChipRec, *hgaVideoChipPtr; 39 40 /* 41 * hooks for communicating with the VideoChip on the HGA 42 */ 43 extern Bool (* hgaInitFunc)(); 44 extern void (* hgaEnterLeaveFunc)(); 45 extern void * (* hgaSaveFunc)(); 46 extern void (* hgaRestoreFunc)(); 47 48 extern pointer hgaOrigVideoState; /* buffers for all video information */ 49 extern pointer hgaNewVideoState; 50 extern pointer hgaBase; /* the framebuffer himself */ 51 52 typedef struct { 53 unsigned char conf; /* write only conf register at port 0x3BF */ 54 unsigned char mode; /* write only mode register at port 0x3B8 */ 55 } hgaHWRec, *hgaHWPtr; 56 57 #define BITS_PER_GUN 1 58 #define COLORMAP_SIZE 2 59 60 extern ScrnInfoRec hga2InfoRec; 61 62 /* 63 * List of I/O ports for generic HGA 64 */ 65 extern unsigned HGA_IOPorts[]; 66 extern int Num_HGA_IOPorts; 67