162306a36Sopenharmony_ci/* $XFree86$ */ 262306a36Sopenharmony_ci/* $XdotOrg$ */ 362306a36Sopenharmony_ci/* 462306a36Sopenharmony_ci * General structure definitions for universal mode switching modules 562306a36Sopenharmony_ci * 662306a36Sopenharmony_ci * Copyright (C) 2001-2005 by Thomas Winischhofer, Vienna, Austria 762306a36Sopenharmony_ci * 862306a36Sopenharmony_ci * If distributed as part of the Linux kernel, the following license terms 962306a36Sopenharmony_ci * apply: 1062306a36Sopenharmony_ci * 1162306a36Sopenharmony_ci * * This program is free software; you can redistribute it and/or modify 1262306a36Sopenharmony_ci * * it under the terms of the GNU General Public License as published by 1362306a36Sopenharmony_ci * * the Free Software Foundation; either version 2 of the named License, 1462306a36Sopenharmony_ci * * or any later version. 1562306a36Sopenharmony_ci * * 1662306a36Sopenharmony_ci * * This program is distributed in the hope that it will be useful, 1762306a36Sopenharmony_ci * * but WITHOUT ANY WARRANTY; without even the implied warranty of 1862306a36Sopenharmony_ci * * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 1962306a36Sopenharmony_ci * * GNU General Public License for more details. 2062306a36Sopenharmony_ci * * 2162306a36Sopenharmony_ci * * You should have received a copy of the GNU General Public License 2262306a36Sopenharmony_ci * * along with this program; if not, write to the Free Software 2362306a36Sopenharmony_ci * * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA 2462306a36Sopenharmony_ci * 2562306a36Sopenharmony_ci * Otherwise, the following license terms apply: 2662306a36Sopenharmony_ci * 2762306a36Sopenharmony_ci * * Redistribution and use in source and binary forms, with or without 2862306a36Sopenharmony_ci * * modification, are permitted provided that the following conditions 2962306a36Sopenharmony_ci * * are met: 3062306a36Sopenharmony_ci * * 1) Redistributions of source code must retain the above copyright 3162306a36Sopenharmony_ci * * notice, this list of conditions and the following disclaimer. 3262306a36Sopenharmony_ci * * 2) Redistributions in binary form must reproduce the above copyright 3362306a36Sopenharmony_ci * * notice, this list of conditions and the following disclaimer in the 3462306a36Sopenharmony_ci * * documentation and/or other materials provided with the distribution. 3562306a36Sopenharmony_ci * * 3) The name of the author may not be used to endorse or promote products 3662306a36Sopenharmony_ci * * derived from this software without specific prior written permission. 3762306a36Sopenharmony_ci * * 3862306a36Sopenharmony_ci * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 3962306a36Sopenharmony_ci * * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 4062306a36Sopenharmony_ci * * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 4162306a36Sopenharmony_ci * * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 4262306a36Sopenharmony_ci * * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 4362306a36Sopenharmony_ci * * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 4462306a36Sopenharmony_ci * * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 4562306a36Sopenharmony_ci * * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 4662306a36Sopenharmony_ci * * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 4762306a36Sopenharmony_ci * * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 4862306a36Sopenharmony_ci * 4962306a36Sopenharmony_ci * Author: Thomas Winischhofer <thomas@winischhofer.net> 5062306a36Sopenharmony_ci * 5162306a36Sopenharmony_ci */ 5262306a36Sopenharmony_ci 5362306a36Sopenharmony_ci#ifndef _VSTRUCT_H_ 5462306a36Sopenharmony_ci#define _VSTRUCT_H_ 5562306a36Sopenharmony_ci 5662306a36Sopenharmony_cistruct SiS_PanelDelayTbl { 5762306a36Sopenharmony_ci unsigned char timer[2]; 5862306a36Sopenharmony_ci}; 5962306a36Sopenharmony_ci 6062306a36Sopenharmony_cistruct SiS_LCDData { 6162306a36Sopenharmony_ci unsigned short RVBHCMAX; 6262306a36Sopenharmony_ci unsigned short RVBHCFACT; 6362306a36Sopenharmony_ci unsigned short VGAHT; 6462306a36Sopenharmony_ci unsigned short VGAVT; 6562306a36Sopenharmony_ci unsigned short LCDHT; 6662306a36Sopenharmony_ci unsigned short LCDVT; 6762306a36Sopenharmony_ci}; 6862306a36Sopenharmony_ci 6962306a36Sopenharmony_cistruct SiS_TVData { 7062306a36Sopenharmony_ci unsigned short RVBHCMAX; 7162306a36Sopenharmony_ci unsigned short RVBHCFACT; 7262306a36Sopenharmony_ci unsigned short VGAHT; 7362306a36Sopenharmony_ci unsigned short VGAVT; 7462306a36Sopenharmony_ci unsigned short TVHDE; 7562306a36Sopenharmony_ci unsigned short TVVDE; 7662306a36Sopenharmony_ci unsigned short RVBHRS; 7762306a36Sopenharmony_ci unsigned char FlickerMode; 7862306a36Sopenharmony_ci unsigned short HALFRVBHRS; 7962306a36Sopenharmony_ci unsigned short RVBHRS2; 8062306a36Sopenharmony_ci unsigned char RY1COE; 8162306a36Sopenharmony_ci unsigned char RY2COE; 8262306a36Sopenharmony_ci unsigned char RY3COE; 8362306a36Sopenharmony_ci unsigned char RY4COE; 8462306a36Sopenharmony_ci}; 8562306a36Sopenharmony_ci 8662306a36Sopenharmony_cistruct SiS_LVDSData { 8762306a36Sopenharmony_ci unsigned short VGAHT; 8862306a36Sopenharmony_ci unsigned short VGAVT; 8962306a36Sopenharmony_ci unsigned short LCDHT; 9062306a36Sopenharmony_ci unsigned short LCDVT; 9162306a36Sopenharmony_ci}; 9262306a36Sopenharmony_ci 9362306a36Sopenharmony_cistruct SiS_LVDSDes { 9462306a36Sopenharmony_ci unsigned short LCDHDES; 9562306a36Sopenharmony_ci unsigned short LCDVDES; 9662306a36Sopenharmony_ci}; 9762306a36Sopenharmony_ci 9862306a36Sopenharmony_cistruct SiS_LVDSCRT1Data { 9962306a36Sopenharmony_ci unsigned char CR[15]; 10062306a36Sopenharmony_ci}; 10162306a36Sopenharmony_ci 10262306a36Sopenharmony_cistruct SiS_CHTVRegData { 10362306a36Sopenharmony_ci unsigned char Reg[16]; 10462306a36Sopenharmony_ci}; 10562306a36Sopenharmony_ci 10662306a36Sopenharmony_cistruct SiS_St { 10762306a36Sopenharmony_ci unsigned char St_ModeID; 10862306a36Sopenharmony_ci unsigned short St_ModeFlag; 10962306a36Sopenharmony_ci unsigned char St_StTableIndex; 11062306a36Sopenharmony_ci unsigned char St_CRT2CRTC; 11162306a36Sopenharmony_ci unsigned char St_ResInfo; 11262306a36Sopenharmony_ci unsigned char VB_StTVFlickerIndex; 11362306a36Sopenharmony_ci unsigned char VB_StTVEdgeIndex; 11462306a36Sopenharmony_ci unsigned char VB_StTVYFilterIndex; 11562306a36Sopenharmony_ci unsigned char St_PDC; 11662306a36Sopenharmony_ci}; 11762306a36Sopenharmony_ci 11862306a36Sopenharmony_cistruct SiS_VBMode { 11962306a36Sopenharmony_ci unsigned char ModeID; 12062306a36Sopenharmony_ci unsigned char VB_TVDelayIndex; 12162306a36Sopenharmony_ci unsigned char VB_TVFlickerIndex; 12262306a36Sopenharmony_ci unsigned char VB_TVPhaseIndex; 12362306a36Sopenharmony_ci unsigned char VB_TVYFilterIndex; 12462306a36Sopenharmony_ci unsigned char VB_LCDDelayIndex; 12562306a36Sopenharmony_ci unsigned char _VB_LCDHIndex; 12662306a36Sopenharmony_ci unsigned char _VB_LCDVIndex; 12762306a36Sopenharmony_ci}; 12862306a36Sopenharmony_ci 12962306a36Sopenharmony_cistruct SiS_StandTable_S { 13062306a36Sopenharmony_ci unsigned char CRT_COLS; 13162306a36Sopenharmony_ci unsigned char ROWS; 13262306a36Sopenharmony_ci unsigned char CHAR_HEIGHT; 13362306a36Sopenharmony_ci unsigned short CRT_LEN; 13462306a36Sopenharmony_ci unsigned char SR[4]; 13562306a36Sopenharmony_ci unsigned char MISC; 13662306a36Sopenharmony_ci unsigned char CRTC[0x19]; 13762306a36Sopenharmony_ci unsigned char ATTR[0x14]; 13862306a36Sopenharmony_ci unsigned char GRC[9]; 13962306a36Sopenharmony_ci}; 14062306a36Sopenharmony_ci 14162306a36Sopenharmony_cistruct SiS_Ext { 14262306a36Sopenharmony_ci unsigned char Ext_ModeID; 14362306a36Sopenharmony_ci unsigned short Ext_ModeFlag; 14462306a36Sopenharmony_ci unsigned short Ext_VESAID; 14562306a36Sopenharmony_ci unsigned char Ext_RESINFO; 14662306a36Sopenharmony_ci unsigned char VB_ExtTVFlickerIndex; 14762306a36Sopenharmony_ci unsigned char VB_ExtTVEdgeIndex; 14862306a36Sopenharmony_ci unsigned char VB_ExtTVYFilterIndex; 14962306a36Sopenharmony_ci unsigned char VB_ExtTVYFilterIndexROM661; 15062306a36Sopenharmony_ci unsigned char REFindex; 15162306a36Sopenharmony_ci signed char ROMMODEIDX661; 15262306a36Sopenharmony_ci}; 15362306a36Sopenharmony_ci 15462306a36Sopenharmony_cistruct SiS_Ext2 { 15562306a36Sopenharmony_ci unsigned short Ext_InfoFlag; 15662306a36Sopenharmony_ci unsigned char Ext_CRT1CRTC; 15762306a36Sopenharmony_ci unsigned char Ext_CRTVCLK; 15862306a36Sopenharmony_ci unsigned char Ext_CRT2CRTC; 15962306a36Sopenharmony_ci unsigned char Ext_CRT2CRTC_NS; 16062306a36Sopenharmony_ci unsigned char ModeID; 16162306a36Sopenharmony_ci unsigned short XRes; 16262306a36Sopenharmony_ci unsigned short YRes; 16362306a36Sopenharmony_ci unsigned char Ext_PDC; 16462306a36Sopenharmony_ci unsigned char Ext_FakeCRT2CRTC; 16562306a36Sopenharmony_ci unsigned char Ext_FakeCRT2Clk; 16662306a36Sopenharmony_ci unsigned char Ext_CRT1CRTC_NORM; 16762306a36Sopenharmony_ci unsigned char Ext_CRTVCLK_NORM; 16862306a36Sopenharmony_ci unsigned char Ext_CRT1CRTC_WIDE; 16962306a36Sopenharmony_ci unsigned char Ext_CRTVCLK_WIDE; 17062306a36Sopenharmony_ci}; 17162306a36Sopenharmony_ci 17262306a36Sopenharmony_cistruct SiS_Part2PortTbl { 17362306a36Sopenharmony_ci unsigned char CR[12]; 17462306a36Sopenharmony_ci}; 17562306a36Sopenharmony_ci 17662306a36Sopenharmony_cistruct SiS_CRT1Table { 17762306a36Sopenharmony_ci unsigned char CR[17]; 17862306a36Sopenharmony_ci}; 17962306a36Sopenharmony_ci 18062306a36Sopenharmony_cistruct SiS_MCLKData { 18162306a36Sopenharmony_ci unsigned char SR28,SR29,SR2A; 18262306a36Sopenharmony_ci unsigned short CLOCK; 18362306a36Sopenharmony_ci}; 18462306a36Sopenharmony_ci 18562306a36Sopenharmony_cistruct SiS_VCLKData { 18662306a36Sopenharmony_ci unsigned char SR2B,SR2C; 18762306a36Sopenharmony_ci unsigned short CLOCK; 18862306a36Sopenharmony_ci}; 18962306a36Sopenharmony_ci 19062306a36Sopenharmony_cistruct SiS_VBVCLKData { 19162306a36Sopenharmony_ci unsigned char Part4_A,Part4_B; 19262306a36Sopenharmony_ci unsigned short CLOCK; 19362306a36Sopenharmony_ci}; 19462306a36Sopenharmony_ci 19562306a36Sopenharmony_cistruct SiS_StResInfo_S { 19662306a36Sopenharmony_ci unsigned short HTotal; 19762306a36Sopenharmony_ci unsigned short VTotal; 19862306a36Sopenharmony_ci}; 19962306a36Sopenharmony_ci 20062306a36Sopenharmony_cistruct SiS_ModeResInfo_S { 20162306a36Sopenharmony_ci unsigned short HTotal; 20262306a36Sopenharmony_ci unsigned short VTotal; 20362306a36Sopenharmony_ci unsigned char XChar; 20462306a36Sopenharmony_ci unsigned char YChar; 20562306a36Sopenharmony_ci}; 20662306a36Sopenharmony_ci 20762306a36Sopenharmony_ci/* Defines for SiS_CustomT */ 20862306a36Sopenharmony_ci/* Never change these for sisfb compatibility */ 20962306a36Sopenharmony_ci#define CUT_NONE 0 21062306a36Sopenharmony_ci#define CUT_FORCENONE 1 21162306a36Sopenharmony_ci#define CUT_BARCO1366 2 21262306a36Sopenharmony_ci#define CUT_BARCO1024 3 21362306a36Sopenharmony_ci#define CUT_COMPAQ1280 4 21462306a36Sopenharmony_ci#define CUT_COMPAQ12802 5 21562306a36Sopenharmony_ci#define CUT_PANEL848 6 21662306a36Sopenharmony_ci#define CUT_CLEVO1024 7 21762306a36Sopenharmony_ci#define CUT_CLEVO10242 8 21862306a36Sopenharmony_ci#define CUT_CLEVO1400 9 21962306a36Sopenharmony_ci#define CUT_CLEVO14002 10 22062306a36Sopenharmony_ci#define CUT_UNIWILL1024 11 22162306a36Sopenharmony_ci#define CUT_ASUSL3000D 12 22262306a36Sopenharmony_ci#define CUT_UNIWILL10242 13 22362306a36Sopenharmony_ci#define CUT_ACER1280 14 22462306a36Sopenharmony_ci#define CUT_COMPAL1400_1 15 22562306a36Sopenharmony_ci#define CUT_COMPAL1400_2 16 22662306a36Sopenharmony_ci#define CUT_ASUSA2H_1 17 22762306a36Sopenharmony_ci#define CUT_ASUSA2H_2 18 22862306a36Sopenharmony_ci#define CUT_UNKNOWNLCD 19 22962306a36Sopenharmony_ci#define CUT_AOP8060 20 23062306a36Sopenharmony_ci#define CUT_PANEL856 21 23162306a36Sopenharmony_ci 23262306a36Sopenharmony_cistruct SiS_Private 23362306a36Sopenharmony_ci{ 23462306a36Sopenharmony_ci unsigned char ChipType; 23562306a36Sopenharmony_ci unsigned char ChipRevision; 23662306a36Sopenharmony_ci void *ivideo; 23762306a36Sopenharmony_ci unsigned char *VirtualRomBase; 23862306a36Sopenharmony_ci bool UseROM; 23962306a36Sopenharmony_ci unsigned char SISIOMEMTYPE *VideoMemoryAddress; 24062306a36Sopenharmony_ci unsigned int VideoMemorySize; 24162306a36Sopenharmony_ci SISIOADDRESS IOAddress; 24262306a36Sopenharmony_ci SISIOADDRESS IOAddress2; /* For dual chip XGI volari */ 24362306a36Sopenharmony_ci 24462306a36Sopenharmony_ci SISIOADDRESS RelIO; 24562306a36Sopenharmony_ci SISIOADDRESS SiS_P3c4; 24662306a36Sopenharmony_ci SISIOADDRESS SiS_P3d4; 24762306a36Sopenharmony_ci SISIOADDRESS SiS_P3c0; 24862306a36Sopenharmony_ci SISIOADDRESS SiS_P3ce; 24962306a36Sopenharmony_ci SISIOADDRESS SiS_P3c2; 25062306a36Sopenharmony_ci SISIOADDRESS SiS_P3ca; 25162306a36Sopenharmony_ci SISIOADDRESS SiS_P3c6; 25262306a36Sopenharmony_ci SISIOADDRESS SiS_P3c7; 25362306a36Sopenharmony_ci SISIOADDRESS SiS_P3c8; 25462306a36Sopenharmony_ci SISIOADDRESS SiS_P3c9; 25562306a36Sopenharmony_ci SISIOADDRESS SiS_P3cb; 25662306a36Sopenharmony_ci SISIOADDRESS SiS_P3cc; 25762306a36Sopenharmony_ci SISIOADDRESS SiS_P3cd; 25862306a36Sopenharmony_ci SISIOADDRESS SiS_P3da; 25962306a36Sopenharmony_ci SISIOADDRESS SiS_Part1Port; 26062306a36Sopenharmony_ci SISIOADDRESS SiS_Part2Port; 26162306a36Sopenharmony_ci SISIOADDRESS SiS_Part3Port; 26262306a36Sopenharmony_ci SISIOADDRESS SiS_Part4Port; 26362306a36Sopenharmony_ci SISIOADDRESS SiS_Part5Port; 26462306a36Sopenharmony_ci SISIOADDRESS SiS_VidCapt; 26562306a36Sopenharmony_ci SISIOADDRESS SiS_VidPlay; 26662306a36Sopenharmony_ci unsigned short SiS_IF_DEF_LVDS; 26762306a36Sopenharmony_ci unsigned short SiS_IF_DEF_CH70xx; 26862306a36Sopenharmony_ci unsigned short SiS_IF_DEF_CONEX; 26962306a36Sopenharmony_ci unsigned short SiS_IF_DEF_TRUMPION; 27062306a36Sopenharmony_ci unsigned short SiS_IF_DEF_DSTN; 27162306a36Sopenharmony_ci unsigned short SiS_IF_DEF_FSTN; 27262306a36Sopenharmony_ci unsigned short SiS_SysFlags; 27362306a36Sopenharmony_ci unsigned char SiS_VGAINFO; 27462306a36Sopenharmony_ci bool SiS_UseROM; 27562306a36Sopenharmony_ci bool SiS_ROMNew; 27662306a36Sopenharmony_ci bool SiS_XGIROM; 27762306a36Sopenharmony_ci bool SiS_NeedRomModeData; 27862306a36Sopenharmony_ci bool PanelSelfDetected; 27962306a36Sopenharmony_ci bool DDCPortMixup; 28062306a36Sopenharmony_ci int SiS_CHOverScan; 28162306a36Sopenharmony_ci bool SiS_CHSOverScan; 28262306a36Sopenharmony_ci bool SiS_ChSW; 28362306a36Sopenharmony_ci bool SiS_UseLCDA; 28462306a36Sopenharmony_ci int SiS_UseOEM; 28562306a36Sopenharmony_ci unsigned int SiS_CustomT; 28662306a36Sopenharmony_ci int SiS_UseWide, SiS_UseWideCRT2; 28762306a36Sopenharmony_ci int SiS_TVBlue; 28862306a36Sopenharmony_ci unsigned short SiS_Backup70xx; 28962306a36Sopenharmony_ci bool HaveEMI; 29062306a36Sopenharmony_ci bool HaveEMILCD; 29162306a36Sopenharmony_ci bool OverruleEMI; 29262306a36Sopenharmony_ci unsigned char EMI_30,EMI_31,EMI_32,EMI_33; 29362306a36Sopenharmony_ci unsigned short SiS_EMIOffset; 29462306a36Sopenharmony_ci unsigned short SiS_PWDOffset; 29562306a36Sopenharmony_ci short PDC, PDCA; 29662306a36Sopenharmony_ci unsigned char SiS_MyCR63; 29762306a36Sopenharmony_ci unsigned short SiS_CRT1Mode; 29862306a36Sopenharmony_ci unsigned short SiS_flag_clearbuffer; 29962306a36Sopenharmony_ci int SiS_RAMType; 30062306a36Sopenharmony_ci unsigned char SiS_ChannelAB; 30162306a36Sopenharmony_ci unsigned char SiS_DataBusWidth; 30262306a36Sopenharmony_ci unsigned short SiS_ModeType; 30362306a36Sopenharmony_ci unsigned short SiS_VBInfo; 30462306a36Sopenharmony_ci unsigned short SiS_TVMode; 30562306a36Sopenharmony_ci unsigned short SiS_LCDResInfo; 30662306a36Sopenharmony_ci unsigned short SiS_LCDTypeInfo; 30762306a36Sopenharmony_ci unsigned short SiS_LCDInfo; 30862306a36Sopenharmony_ci unsigned short SiS_LCDInfo661; 30962306a36Sopenharmony_ci unsigned short SiS_VBType; 31062306a36Sopenharmony_ci unsigned short SiS_VBExtInfo; 31162306a36Sopenharmony_ci unsigned short SiS_YPbPr; 31262306a36Sopenharmony_ci unsigned short SiS_SelectCRT2Rate; 31362306a36Sopenharmony_ci unsigned short SiS_SetFlag; 31462306a36Sopenharmony_ci unsigned short SiS_RVBHCFACT; 31562306a36Sopenharmony_ci unsigned short SiS_RVBHCMAX; 31662306a36Sopenharmony_ci unsigned short SiS_RVBHRS; 31762306a36Sopenharmony_ci unsigned short SiS_RVBHRS2; 31862306a36Sopenharmony_ci unsigned short SiS_VGAVT; 31962306a36Sopenharmony_ci unsigned short SiS_VGAHT; 32062306a36Sopenharmony_ci unsigned short SiS_VT; 32162306a36Sopenharmony_ci unsigned short SiS_HT; 32262306a36Sopenharmony_ci unsigned short SiS_VGAVDE; 32362306a36Sopenharmony_ci unsigned short SiS_VGAHDE; 32462306a36Sopenharmony_ci unsigned short SiS_VDE; 32562306a36Sopenharmony_ci unsigned short SiS_HDE; 32662306a36Sopenharmony_ci unsigned short SiS_NewFlickerMode; 32762306a36Sopenharmony_ci unsigned short SiS_RY1COE; 32862306a36Sopenharmony_ci unsigned short SiS_RY2COE; 32962306a36Sopenharmony_ci unsigned short SiS_RY3COE; 33062306a36Sopenharmony_ci unsigned short SiS_RY4COE; 33162306a36Sopenharmony_ci unsigned short SiS_LCDHDES; 33262306a36Sopenharmony_ci unsigned short SiS_LCDVDES; 33362306a36Sopenharmony_ci SISIOADDRESS SiS_DDC_Port; 33462306a36Sopenharmony_ci unsigned short SiS_DDC_Index; 33562306a36Sopenharmony_ci unsigned short SiS_DDC_Data; 33662306a36Sopenharmony_ci unsigned short SiS_DDC_NData; 33762306a36Sopenharmony_ci unsigned short SiS_DDC_Clk; 33862306a36Sopenharmony_ci unsigned short SiS_DDC_NClk; 33962306a36Sopenharmony_ci unsigned short SiS_DDC_DeviceAddr; 34062306a36Sopenharmony_ci unsigned short SiS_DDC_ReadAddr; 34162306a36Sopenharmony_ci unsigned short SiS_DDC_SecAddr; 34262306a36Sopenharmony_ci unsigned short SiS_ChrontelInit; 34362306a36Sopenharmony_ci bool SiS_SensibleSR11; 34462306a36Sopenharmony_ci unsigned short SiS661LCD2TableSize; 34562306a36Sopenharmony_ci 34662306a36Sopenharmony_ci unsigned short SiS_PanelMinLVDS; 34762306a36Sopenharmony_ci unsigned short SiS_PanelMin301; 34862306a36Sopenharmony_ci 34962306a36Sopenharmony_ci const struct SiS_St *SiS_SModeIDTable; 35062306a36Sopenharmony_ci const struct SiS_StandTable_S *SiS_StandTable; 35162306a36Sopenharmony_ci const struct SiS_Ext *SiS_EModeIDTable; 35262306a36Sopenharmony_ci const struct SiS_Ext2 *SiS_RefIndex; 35362306a36Sopenharmony_ci const struct SiS_VBMode *SiS_VBModeIDTable; 35462306a36Sopenharmony_ci const struct SiS_CRT1Table *SiS_CRT1Table; 35562306a36Sopenharmony_ci const struct SiS_MCLKData *SiS_MCLKData_0; 35662306a36Sopenharmony_ci const struct SiS_MCLKData *SiS_MCLKData_1; 35762306a36Sopenharmony_ci struct SiS_VCLKData *SiS_VCLKData; 35862306a36Sopenharmony_ci struct SiS_VBVCLKData *SiS_VBVCLKData; 35962306a36Sopenharmony_ci const struct SiS_StResInfo_S *SiS_StResInfo; 36062306a36Sopenharmony_ci const struct SiS_ModeResInfo_S *SiS_ModeResInfo; 36162306a36Sopenharmony_ci 36262306a36Sopenharmony_ci const unsigned char *pSiS_OutputSelect; 36362306a36Sopenharmony_ci const unsigned char *pSiS_SoftSetting; 36462306a36Sopenharmony_ci 36562306a36Sopenharmony_ci const unsigned char *SiS_SR15; 36662306a36Sopenharmony_ci 36762306a36Sopenharmony_ci const struct SiS_PanelDelayTbl *SiS_PanelDelayTbl; 36862306a36Sopenharmony_ci const struct SiS_PanelDelayTbl *SiS_PanelDelayTblLVDS; 36962306a36Sopenharmony_ci 37062306a36Sopenharmony_ci /* SiS bridge */ 37162306a36Sopenharmony_ci 37262306a36Sopenharmony_ci const struct SiS_LCDData *SiS_ExtLCD1024x768Data; 37362306a36Sopenharmony_ci const struct SiS_LCDData *SiS_St2LCD1024x768Data; 37462306a36Sopenharmony_ci const struct SiS_LCDData *SiS_LCD1280x720Data; 37562306a36Sopenharmony_ci const struct SiS_LCDData *SiS_StLCD1280x768_2Data; 37662306a36Sopenharmony_ci const struct SiS_LCDData *SiS_ExtLCD1280x768_2Data; 37762306a36Sopenharmony_ci const struct SiS_LCDData *SiS_LCD1280x800Data; 37862306a36Sopenharmony_ci const struct SiS_LCDData *SiS_LCD1280x800_2Data; 37962306a36Sopenharmony_ci const struct SiS_LCDData *SiS_LCD1280x854Data; 38062306a36Sopenharmony_ci const struct SiS_LCDData *SiS_LCD1280x960Data; 38162306a36Sopenharmony_ci const struct SiS_LCDData *SiS_ExtLCD1280x1024Data; 38262306a36Sopenharmony_ci const struct SiS_LCDData *SiS_St2LCD1280x1024Data; 38362306a36Sopenharmony_ci const struct SiS_LCDData *SiS_StLCD1400x1050Data; 38462306a36Sopenharmony_ci const struct SiS_LCDData *SiS_ExtLCD1400x1050Data; 38562306a36Sopenharmony_ci const struct SiS_LCDData *SiS_StLCD1600x1200Data; 38662306a36Sopenharmony_ci const struct SiS_LCDData *SiS_ExtLCD1600x1200Data; 38762306a36Sopenharmony_ci const struct SiS_LCDData *SiS_LCD1680x1050Data; 38862306a36Sopenharmony_ci const struct SiS_LCDData *SiS_NoScaleData; 38962306a36Sopenharmony_ci const struct SiS_TVData *SiS_StPALData; 39062306a36Sopenharmony_ci const struct SiS_TVData *SiS_ExtPALData; 39162306a36Sopenharmony_ci const struct SiS_TVData *SiS_StNTSCData; 39262306a36Sopenharmony_ci const struct SiS_TVData *SiS_ExtNTSCData; 39362306a36Sopenharmony_ci const struct SiS_TVData *SiS_St1HiTVData; 39462306a36Sopenharmony_ci const struct SiS_TVData *SiS_St2HiTVData; 39562306a36Sopenharmony_ci const struct SiS_TVData *SiS_ExtHiTVData; 39662306a36Sopenharmony_ci const struct SiS_TVData *SiS_St525iData; 39762306a36Sopenharmony_ci const struct SiS_TVData *SiS_St525pData; 39862306a36Sopenharmony_ci const struct SiS_TVData *SiS_St750pData; 39962306a36Sopenharmony_ci const struct SiS_TVData *SiS_Ext525iData; 40062306a36Sopenharmony_ci const struct SiS_TVData *SiS_Ext525pData; 40162306a36Sopenharmony_ci const struct SiS_TVData *SiS_Ext750pData; 40262306a36Sopenharmony_ci const unsigned char *SiS_NTSCTiming; 40362306a36Sopenharmony_ci const unsigned char *SiS_PALTiming; 40462306a36Sopenharmony_ci const unsigned char *SiS_HiTVExtTiming; 40562306a36Sopenharmony_ci const unsigned char *SiS_HiTVSt1Timing; 40662306a36Sopenharmony_ci const unsigned char *SiS_HiTVSt2Timing; 40762306a36Sopenharmony_ci const unsigned char *SiS_HiTVGroup3Data; 40862306a36Sopenharmony_ci const unsigned char *SiS_HiTVGroup3Simu; 40962306a36Sopenharmony_ci#if 0 41062306a36Sopenharmony_ci const unsigned char *SiS_HiTVTextTiming; 41162306a36Sopenharmony_ci const unsigned char *SiS_HiTVGroup3Text; 41262306a36Sopenharmony_ci#endif 41362306a36Sopenharmony_ci 41462306a36Sopenharmony_ci const struct SiS_Part2PortTbl *SiS_CRT2Part2_1024x768_1; 41562306a36Sopenharmony_ci const struct SiS_Part2PortTbl *SiS_CRT2Part2_1024x768_2; 41662306a36Sopenharmony_ci const struct SiS_Part2PortTbl *SiS_CRT2Part2_1024x768_3; 41762306a36Sopenharmony_ci 41862306a36Sopenharmony_ci /* LVDS, Chrontel */ 41962306a36Sopenharmony_ci 42062306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDS320x240Data_1; 42162306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDS320x240Data_2; 42262306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDS640x480Data_1; 42362306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDS800x600Data_1; 42462306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDS1024x600Data_1; 42562306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDS1024x768Data_1; 42662306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDSBARCO1366Data_1; 42762306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDSBARCO1366Data_2; 42862306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDSBARCO1024Data_1; 42962306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDS848x480Data_1; 43062306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_LVDS848x480Data_2; 43162306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_CHTVUNTSCData; 43262306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_CHTVONTSCData; 43362306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_CHTVUPALData; 43462306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_CHTVOPALData; 43562306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_CHTVUPALMData; 43662306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_CHTVOPALMData; 43762306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_CHTVUPALNData; 43862306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_CHTVOPALNData; 43962306a36Sopenharmony_ci const struct SiS_LVDSData *SiS_CHTVSOPALData; 44062306a36Sopenharmony_ci 44162306a36Sopenharmony_ci const struct SiS_LVDSDes *SiS_PanelType04_1a; 44262306a36Sopenharmony_ci const struct SiS_LVDSDes *SiS_PanelType04_2a; 44362306a36Sopenharmony_ci const struct SiS_LVDSDes *SiS_PanelType04_1b; 44462306a36Sopenharmony_ci const struct SiS_LVDSDes *SiS_PanelType04_2b; 44562306a36Sopenharmony_ci 44662306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_LVDSCRT1320x240_1; 44762306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_LVDSCRT1320x240_2; 44862306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_LVDSCRT1320x240_2_H; 44962306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_LVDSCRT1320x240_3; 45062306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_LVDSCRT1320x240_3_H; 45162306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_LVDSCRT1640x480_1; 45262306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_LVDSCRT1640x480_1_H; 45362306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_CHTVCRT1UNTSC; 45462306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_CHTVCRT1ONTSC; 45562306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_CHTVCRT1UPAL; 45662306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_CHTVCRT1OPAL; 45762306a36Sopenharmony_ci const struct SiS_LVDSCRT1Data *SiS_CHTVCRT1SOPAL; 45862306a36Sopenharmony_ci 45962306a36Sopenharmony_ci const struct SiS_CHTVRegData *SiS_CHTVReg_UNTSC; 46062306a36Sopenharmony_ci const struct SiS_CHTVRegData *SiS_CHTVReg_ONTSC; 46162306a36Sopenharmony_ci const struct SiS_CHTVRegData *SiS_CHTVReg_UPAL; 46262306a36Sopenharmony_ci const struct SiS_CHTVRegData *SiS_CHTVReg_OPAL; 46362306a36Sopenharmony_ci const struct SiS_CHTVRegData *SiS_CHTVReg_UPALM; 46462306a36Sopenharmony_ci const struct SiS_CHTVRegData *SiS_CHTVReg_OPALM; 46562306a36Sopenharmony_ci const struct SiS_CHTVRegData *SiS_CHTVReg_UPALN; 46662306a36Sopenharmony_ci const struct SiS_CHTVRegData *SiS_CHTVReg_OPALN; 46762306a36Sopenharmony_ci const struct SiS_CHTVRegData *SiS_CHTVReg_SOPAL; 46862306a36Sopenharmony_ci 46962306a36Sopenharmony_ci const unsigned char *SiS_CHTVVCLKUNTSC; 47062306a36Sopenharmony_ci const unsigned char *SiS_CHTVVCLKONTSC; 47162306a36Sopenharmony_ci const unsigned char *SiS_CHTVVCLKUPAL; 47262306a36Sopenharmony_ci const unsigned char *SiS_CHTVVCLKOPAL; 47362306a36Sopenharmony_ci const unsigned char *SiS_CHTVVCLKUPALM; 47462306a36Sopenharmony_ci const unsigned char *SiS_CHTVVCLKOPALM; 47562306a36Sopenharmony_ci const unsigned char *SiS_CHTVVCLKUPALN; 47662306a36Sopenharmony_ci const unsigned char *SiS_CHTVVCLKOPALN; 47762306a36Sopenharmony_ci const unsigned char *SiS_CHTVVCLKSOPAL; 47862306a36Sopenharmony_ci 47962306a36Sopenharmony_ci unsigned short PanelXRes, PanelHT; 48062306a36Sopenharmony_ci unsigned short PanelYRes, PanelVT; 48162306a36Sopenharmony_ci unsigned short PanelHRS, PanelHRE; 48262306a36Sopenharmony_ci unsigned short PanelVRS, PanelVRE; 48362306a36Sopenharmony_ci unsigned short PanelVCLKIdx300; 48462306a36Sopenharmony_ci unsigned short PanelVCLKIdx315; 48562306a36Sopenharmony_ci bool Alternate1600x1200; 48662306a36Sopenharmony_ci 48762306a36Sopenharmony_ci bool UseCustomMode; 48862306a36Sopenharmony_ci bool CRT1UsesCustomMode; 48962306a36Sopenharmony_ci unsigned short CHDisplay; 49062306a36Sopenharmony_ci unsigned short CHSyncStart; 49162306a36Sopenharmony_ci unsigned short CHSyncEnd; 49262306a36Sopenharmony_ci unsigned short CHTotal; 49362306a36Sopenharmony_ci unsigned short CHBlankStart; 49462306a36Sopenharmony_ci unsigned short CHBlankEnd; 49562306a36Sopenharmony_ci unsigned short CVDisplay; 49662306a36Sopenharmony_ci unsigned short CVSyncStart; 49762306a36Sopenharmony_ci unsigned short CVSyncEnd; 49862306a36Sopenharmony_ci unsigned short CVTotal; 49962306a36Sopenharmony_ci unsigned short CVBlankStart; 50062306a36Sopenharmony_ci unsigned short CVBlankEnd; 50162306a36Sopenharmony_ci unsigned int CDClock; 50262306a36Sopenharmony_ci unsigned int CFlags; 50362306a36Sopenharmony_ci unsigned char CCRT1CRTC[17]; 50462306a36Sopenharmony_ci unsigned char CSR2B; 50562306a36Sopenharmony_ci unsigned char CSR2C; 50662306a36Sopenharmony_ci unsigned short CSRClock; 50762306a36Sopenharmony_ci unsigned short CSRClock_CRT1; 50862306a36Sopenharmony_ci unsigned short CModeFlag; 50962306a36Sopenharmony_ci unsigned short CModeFlag_CRT1; 51062306a36Sopenharmony_ci unsigned short CInfoFlag; 51162306a36Sopenharmony_ci 51262306a36Sopenharmony_ci int LVDSHL; 51362306a36Sopenharmony_ci 51462306a36Sopenharmony_ci bool Backup; 51562306a36Sopenharmony_ci unsigned char Backup_Mode; 51662306a36Sopenharmony_ci unsigned char Backup_14; 51762306a36Sopenharmony_ci unsigned char Backup_15; 51862306a36Sopenharmony_ci unsigned char Backup_16; 51962306a36Sopenharmony_ci unsigned char Backup_17; 52062306a36Sopenharmony_ci unsigned char Backup_18; 52162306a36Sopenharmony_ci unsigned char Backup_19; 52262306a36Sopenharmony_ci unsigned char Backup_1a; 52362306a36Sopenharmony_ci unsigned char Backup_1b; 52462306a36Sopenharmony_ci unsigned char Backup_1c; 52562306a36Sopenharmony_ci unsigned char Backup_1d; 52662306a36Sopenharmony_ci 52762306a36Sopenharmony_ci unsigned char Init_P4_0E; 52862306a36Sopenharmony_ci 52962306a36Sopenharmony_ci int UsePanelScaler; 53062306a36Sopenharmony_ci int CenterScreen; 53162306a36Sopenharmony_ci 53262306a36Sopenharmony_ci unsigned short CP_Vendor, CP_Product; 53362306a36Sopenharmony_ci bool CP_HaveCustomData; 53462306a36Sopenharmony_ci int CP_PreferredX, CP_PreferredY, CP_PreferredIndex; 53562306a36Sopenharmony_ci int CP_MaxX, CP_MaxY, CP_MaxClock; 53662306a36Sopenharmony_ci unsigned char CP_PrefSR2B, CP_PrefSR2C; 53762306a36Sopenharmony_ci unsigned short CP_PrefClock; 53862306a36Sopenharmony_ci bool CP_Supports64048075; 53962306a36Sopenharmony_ci int CP_HDisplay[7], CP_VDisplay[7]; /* For Custom LCD panel dimensions */ 54062306a36Sopenharmony_ci int CP_HTotal[7], CP_VTotal[7]; 54162306a36Sopenharmony_ci int CP_HSyncStart[7], CP_VSyncStart[7]; 54262306a36Sopenharmony_ci int CP_HSyncEnd[7], CP_VSyncEnd[7]; 54362306a36Sopenharmony_ci int CP_HBlankStart[7], CP_VBlankStart[7]; 54462306a36Sopenharmony_ci int CP_HBlankEnd[7], CP_VBlankEnd[7]; 54562306a36Sopenharmony_ci int CP_Clock[7]; 54662306a36Sopenharmony_ci bool CP_DataValid[7]; 54762306a36Sopenharmony_ci bool CP_HSync_P[7], CP_VSync_P[7], CP_SyncValid[7]; 54862306a36Sopenharmony_ci}; 54962306a36Sopenharmony_ci 55062306a36Sopenharmony_ci#endif 55162306a36Sopenharmony_ci 552