USHORT modeflag, tempax, tempbx, VGAHDE = SiS_Pr->SiS_VGAHDE; int i,j; 
unsigned short modeflag, tempax, tempbx = 0, remaining = 0; unsigned short VGAHDE = SiS_Pr->SiS_VGAHDE; int i, j; 
SiS_CalcLCDACRT1Timing(SiS_Private *SiS_Pr,USHORT ModeNo,USHORT ModeIdIndex){   USHORT modeflag, tempax, tempbx, VGAHDE = SiS_Pr->SiS_VGAHDE;   int i,j;   /* 1:1 data: use data set by setcrt1crtc() */   if(SiS_Pr->SiS_LCDInfo & LCDPass11) return;   if(ModeNo <= 0x13) {     modeflag = SiS_Pr->SiS_SModeIDTable[ModeIdIndex].St_ModeFlag;   } else if(SiS_Pr->UseCustomMode) {     modeflag = SiS_Pr->CModeFlag;   } else {     modeflag = SiS_Pr->SiS_EModeIDTable[ModeIdIndex].Ext_ModeFlag;   }   if(modeflag & HalfDCLK) VGAHDE >>= 1;   SiS_Pr->CHDisplay = VGAHDE;   SiS_Pr->CHBlankStart = VGAHDE;   SiS_Pr->CVDisplay = SiS_Pr->SiS_VGAVDE;   SiS_Pr->CVBlankStart = SiS_Pr->SiS_VGAVDE;   tempbx = SiS_Pr->PanelHT - SiS_Pr->PanelXRes;   tempax = SiS_Pr->SiS_VGAHDE;  /* not /2 ! */   if(SiS_Pr->SiS_LCDInfo & DontExpandLCD) {      tempax = SiS_Pr->PanelXRes;   }   tempbx += tempax;   if(modeflag & HalfDCLK) tempbx -= VGAHDE;   SiS_Pr->CHTotal = SiS_Pr->CHBlankEnd = tempbx;   tempax = VGAHDE;   tempbx = SiS_Pr->CHTotal;   if(SiS_Pr->SiS_LCDInfo & DontExpandLCD) {      tempbx = SiS_Pr->PanelXRes;      if(modeflag & HalfDCLK) tempbx >>= 1;      tempax += ((tempbx - tempax) >> 1);   }   tempax += SiS_Pr->PanelHRS;   SiS_Pr->CHSyncStart = tempax;   tempax += SiS_Pr->PanelHRE;   SiS_Pr->CHSyncEnd = tempax;   tempbx = SiS_Pr->PanelVT - SiS_Pr->PanelYRes;   tempax = SiS_Pr->SiS_VGAVDE;   if(SiS_Pr->SiS_LCDInfo & DontExpandLCD) {      tempax = SiS_Pr->PanelYRes;   }   SiS_Pr->CVTotal = SiS_Pr->CVBlankEnd = tempbx + tempax;   tempax = SiS_Pr->SiS_VGAVDE;   if(SiS_Pr->SiS_LCDInfo & DontExpandLCD) {      tempax += (SiS_Pr->PanelYRes - tempax) >> 1;   }   tempax += SiS_Pr->PanelVRS;   SiS_Pr->CVSyncStart = tempax;   tempax += SiS_Pr->PanelVRE;   SiS_Pr->CVSyncEnd = tempax;   SiS_CalcCRRegisters(SiS_Pr, 8);   SiS_Pr->CCRT1CRTC[16] &= ~0xE0;   SiS_SetRegAND(SiS_Pr->SiS_P3d4,0x11,0x7f);   for(i=0,j=0;i<=7;i++,j++) {      SiS_SetReg(SiS_Pr->SiS_P3d4,j,SiS_Pr->CCRT1CRTC[i]);   }   for(j=0x10;i<=10;i++,j++) {      SiS_SetReg(SiS_Pr->SiS_P3d4,j,SiS_Pr->CCRT1CRTC[i]);   }   for(j=0x15;i<=12;i++,j++) {      SiS_SetReg(SiS_Pr->SiS_P3d4,j,SiS_Pr->CCRT1CRTC[i]);   }   for(j=0x0A;i<=15;i++,j++) {      SiS_SetReg(SiS_Pr->SiS_P3c4,j,SiS_Pr->CCRT1CRTC[i]);   }   tempax = SiS_Pr->CCRT1CRTC[16] & 0xE0;   SiS_SetRegANDOR(SiS_Pr->SiS_P3c4,0x0E,0x1F,tempax);   tempax = (SiS_Pr->CCRT1CRTC[16] & 0x01) << 5;   if(modeflag & DoubleScanMode) tempax |= 0x80;   SiS_SetRegANDOR(SiS_Pr->SiS_P3d4,0x09,0x5F,tempax);#ifdef TWDEBUG   xf86DrvMsg(0, X_INFO, "%d %d %d %d  %d %d %d %d  (%d %d %d %d)\n",       	SiS_Pr->CHDisplay, SiS_Pr->CHSyncStart, SiS_Pr->CHSyncEnd, SiS_Pr->CHTotal,	SiS_Pr->CVDisplay, SiS_Pr->CVSyncStart, SiS_Pr->CVSyncEnd, SiS_Pr->CVTotal,	SiS_Pr->CHBlankStart, SiS_Pr->CHBlankEnd, SiS_Pr->CVBlankStart, SiS_Pr->CVBlankEnd);   xf86DrvMsg(0, X_INFO, " {{0x%02x,0x%02x,0x%02x,0x%02x,0x%02x,0x%02x,0x%02x,0x%02x,\n",   	SiS_Pr->CCRT1CRTC[0], SiS_Pr->CCRT1CRTC[1],	SiS_Pr->CCRT1CRTC[2], SiS_Pr->CCRT1CRTC[3],	SiS_Pr->CCRT1CRTC[4], SiS_Pr->CCRT1CRTC[5],	SiS_Pr->CCRT1CRTC[6], SiS_Pr->CCRT1CRTC[7]);   xf86DrvMsg(0, X_INFO, "   0x%02x,0x%02x,0x%02x,0x%02x,0x%02x,0x%02x,0x%02x,0x%02x,\n",   	SiS_Pr->CCRT1CRTC[8], SiS_Pr->CCRT1CRTC[9],	SiS_Pr->CCRT1CRTC[10], SiS_Pr->CCRT1CRTC[11],	SiS_Pr->CCRT1CRTC[12], SiS_Pr->CCRT1CRTC[13],	SiS_Pr->CCRT1CRTC[14], SiS_Pr->CCRT1CRTC[15]);   xf86DrvMsg(0, X_INFO, "   0x%02x}},\n", SiS_Pr->CCRT1CRTC[16]);#endif}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/544393fe584d333480659a4bed30f5295355df11/init.c/clean/drivers/video/sis/init.c