diff options
Diffstat (limited to 'src/typedef.h')
-rw-r--r-- | src/typedef.h | 67 |
1 files changed, 34 insertions, 33 deletions
diff --git a/src/typedef.h b/src/typedef.h index 3bd965b..583f625 100644 --- a/src/typedef.h +++ b/src/typedef.h @@ -19,11 +19,12 @@ */ + #define X_INFO 0 #define X_WARNING 1 #define X_ERROR 2 -/* Verberse level define */ + typedef unsigned char UCHAR; typedef unsigned short USHORT; typedef unsigned long ULONG; @@ -35,22 +36,22 @@ typedef enum _bool }bool; #ifndef ErrorLevel - #define ErrorLevel 0 /* Report Error message */ + #define ErrorLevel 0 #endif #ifndef DefaultLevel - #define DefaultLevel 4 /* Driver entry function */ + #define DefaultLevel 4 #endif #ifndef InfoLevel - #define InfoLevel 5 /* Report information */ + #define InfoLevel 5 #endif #ifndef InternalLevel - #define InternalLevel 6 /* Driver interanl function entry */ + #define InternalLevel 6 #endif -/* Related IO offset */ + #define ATTR_ADDR 0X0040 #define ATTR_DATA_WRITE 0X0040 #define ATTR_DATA_READ 0X0041 @@ -78,7 +79,7 @@ typedef enum _bool #define VBIOSVerNum 0x00000 -/* Scratch registers */ + #define SCRATCH_01 0x81 * 0x100 #define IDX_SCRATCH_01 SCRATCH_01 + 0xFF @@ -194,7 +195,7 @@ typedef enum _bool #define IDX_LCD1_TABLE_INDEX SCRATCH_23 + 0xF0 #define IDX_LCD2_TABLE_INDEX SCRATCH_23 + 0x0F -/* For Bit mask using */ + #define BIT0 0x00000001 #define BIT1 0x00000002 #define BIT2 0x00000004 @@ -228,13 +229,13 @@ typedef enum _bool #define BIT30 0x40000000 #define BIT31 0x80000000 -/* definition of output ports */ + #define CRT_PORT 0 #define DVP1 1 #define DVP2 2 #define DVP12 3 -/* definition of RRATE_TABLE.RRate_ID */ + #define RR60 0 #define RR50I 1 #define RR59_94I 2 @@ -252,7 +253,7 @@ typedef enum _bool #define RR72 14 #define RR65 15 -/* Output Device Index */ + #define LCD_ID 1 #define DVI_ID 2 #define CRT_ID 3 @@ -266,7 +267,7 @@ typedef enum _bool #define HDTV2_ID 12 #define TV2_ID 13 -/* Output Device Combination Bit */ + #define B_LCD BIT0 #define B_DVI BIT1 #define B_CRT BIT2 @@ -282,47 +283,47 @@ typedef enum _bool -/* clock definition */ + #define PLLReferenceClock 14318 #define MaxFCKVCO9003A 810000 #define MinFCKVCO9003A 350000 #define MaxFCKVCO9001A 1600000 #define MinFCKVCO9001A 833000 -/* DPMS State */ + #define DPMS__ON 0 #define DPMS__STANDBY 1 #define DPMS__SUSPEND 2 #define DPMS__OFF 3 -/* definitions only for PANEL_TABLE.Attribute */ -#define SEQ BIT1 /* sequential output format */ -#define TTL BIT6 /* TTL LCD */ -/* _PORT_CONFIG.TX_Enc_ID */ -#define NONE 0x00 /* no TX/encoder */ +#define SEQ BIT1 +#define TTL BIT6 + + +#define NONE 0x00 #define TX_VT1636 0x01 #define TX_SIL1162 0x02 -#define TX_HW 0x03 /* hardwired TX */ +#define TX_HW 0x03 #define ENC_VT1625 0x04 -#define DSTN 0x05 /* DSTN */ +#define DSTN 0x05 -/* _PORT_CONFIG.Attribute */ -#define Dev_SUPPORT BIT0 /* Device Support */ + +#define Dev_SUPPORT BIT0 #define TX_DIT BIT1 #define TX_PS BIT2 -#define DSTN_COLOR BIT3 /* DSTN color */ -#define DSTN_MONO 0 /* DSTN mono */ -#define DSTN_6X4 BIT4 /* DSTN 640x480 */ -#define DSTN_3X2 0 /* DSTN 320x240 */ +#define DSTN_COLOR BIT3 +#define DSTN_MONO 0 +#define DSTN_6X4 BIT4 +#define DSTN_3X2 0 #define TX_MSB BIT5 -/* definitions of display path */ + #define DISP1 1 #define DISP2 2 -/* mode numbers */ + #define MODE_640x480x8 0x101 #define MODE_800x600x8 0x103 @@ -397,7 +398,7 @@ typedef struct _PORT_CONFIG PORT_CONFIG; typedef struct _VESA_TABLE VESA_TABLE; struct _RRATE_TABLE { - ULONG Clock; /* in khz */ + ULONG Clock; UCHAR RRate_ID; USHORT Attribute; USHORT H_Blank_Time; @@ -458,7 +459,7 @@ typedef struct _REG_PACKAGE { UCHAR RegMask; } REG_PACKAGE; #else -/* definitions for SerialLoadTable() */ + #define CR 0x00 #define SR 0x01 #define GR 0x02 @@ -484,7 +485,7 @@ struct _PORT_CONFIG UCHAR Attribute; }__attribute__((packed));; -/* PCI Data Structure */ + #define OFF_VID 0 #define OFF_DID 2 #define OFF_PTR_VPD 4 @@ -499,6 +500,6 @@ struct _PORT_CONFIG #define OFF_LII 17 #define OFF_RESERVED 18 -/* Definition of PCI Data Structure.RESERVED */ + |