32 #include <linux/types.h>
36 unsigned char modeno,
unsigned char rateindex);
40 int *htotal,
int *vtotal,
unsigned char rateindex);
44 unsigned short *ModeIdIndex);
50 unsigned char rateindex)
52 unsigned short ModeNo = modeno;
53 unsigned short ModeIdIndex = 0, ClockIndex = 0;
54 unsigned short RRTI = 0;
59 if(rateindex > 0) rateindex--;
61 #ifdef CONFIG_FB_SIS_315
63 case 0x5a: ModeNo = 0x50;
break;
64 case 0x5b: ModeNo = 0x56;
78 ClockIndex = SiS_Pr->
SiS_RefIndex[RRTI].Ext_CRTVCLK_WIDE;
81 ClockIndex = SiS_Pr->
SiS_RefIndex[RRTI].Ext_CRTVCLK_NORM;
97 unsigned short ModeNo = modeno;
98 unsigned short ModeIdIndex = 0,
index = 0, RRTI = 0;
103 if(rateindex > 0) rateindex--;
105 #ifdef CONFIG_FB_SIS_315
107 case 0x5a: ModeNo = 0x50;
break;
108 case 0x5b: ModeNo = 0x56;
178 int *vtotal,
unsigned char rateindex)
180 unsigned short ModeNo = modeno;
181 unsigned short ModeIdIndex = 0, CRT1Index = 0;
182 unsigned short RRTI = 0;
183 unsigned char sr_data, cr_data, cr_data2;
187 if(rateindex > 0) rateindex--;
189 #ifdef CONFIG_FB_SIS_315
191 case 0x5a: ModeNo = 0x50;
break;
192 case 0x5b: ModeNo = 0x56;
202 CRT1Index = SiS_Pr->
SiS_RefIndex[RRTI].Ext_CRT1CRTC_WIDE;
205 CRT1Index = SiS_Pr->
SiS_RefIndex[RRTI].Ext_CRT1CRTC_NORM;
214 *htotal = (((cr_data & 0xff) | ((
unsigned short) (sr_data & 0x03) << 8)) + 5) * 8;
219 *vtotal = ((cr_data & 0xFF) |
220 ((
unsigned short)(cr_data2 & 0x01) << 8) |
221 ((
unsigned short)(cr_data2 & 0x20) << 4) |
222 ((
unsigned short)(sr_data & 0x01) << 10)) + 2;