init.h 80 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469
  1. /* $XFree86$ */
  2. /* $XdotOrg$ */
  3. /*
  4. * Data and prototypes for init.c
  5. *
  6. * Copyright (C) 2001-2004 by Thomas Winischhofer, Vienna, Austria
  7. *
  8. * If distributed as part of the Linux kernel, the following license terms
  9. * apply:
  10. *
  11. * * This program is free software; you can redistribute it and/or modify
  12. * * it under the terms of the GNU General Public License as published by
  13. * * the Free Software Foundation; either version 2 of the named License,
  14. * * or any later version.
  15. * *
  16. * * This program is distributed in the hope that it will be useful,
  17. * * but WITHOUT ANY WARRANTY; without even the implied warranty of
  18. * * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  19. * * GNU General Public License for more details.
  20. * *
  21. * * You should have received a copy of the GNU General Public License
  22. * * along with this program; if not, write to the Free Software
  23. * * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA
  24. *
  25. * Otherwise, the following license terms apply:
  26. *
  27. * * Redistribution and use in source and binary forms, with or without
  28. * * modification, are permitted provided that the following conditions
  29. * * are met:
  30. * * 1) Redistributions of source code must retain the above copyright
  31. * * notice, this list of conditions and the following disclaimer.
  32. * * 2) Redistributions in binary form must reproduce the above copyright
  33. * * notice, this list of conditions and the following disclaimer in the
  34. * * documentation and/or other materials provided with the distribution.
  35. * * 3) The name of the author may not be used to endorse or promote products
  36. * * derived from this software without specific prior written permission.
  37. * *
  38. * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
  39. * * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  40. * * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  41. * * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
  42. * * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  43. * * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  44. * * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  45. * * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  46. * * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  47. * * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  48. *
  49. * Author: Thomas Winischhofer <thomas@winischhofer.net>
  50. *
  51. */
  52. #ifndef _INIT_
  53. #define _INIT_
  54. #include "osdef.h"
  55. #include "initdef.h"
  56. #ifdef LINUX_XF86
  57. #include "sis.h"
  58. #include "sis_regs.h"
  59. #endif
  60. #ifdef LINUX_KERNEL
  61. #include "vgatypes.h"
  62. #include "vstruct.h"
  63. #ifdef SIS_CP
  64. #undef SIS_CP
  65. #endif
  66. #include <linux/config.h>
  67. #include <linux/version.h>
  68. #include <linux/types.h>
  69. #include <asm/io.h>
  70. #include <linux/fb.h>
  71. #if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
  72. #include <linux/sisfb.h>
  73. #else
  74. #include <video/sisfb.h>
  75. #endif
  76. #endif
  77. /* Mode numbers */
  78. static const USHORT ModeIndex_320x200[] = {0x59, 0x41, 0x00, 0x4f};
  79. static const USHORT ModeIndex_320x240[] = {0x50, 0x56, 0x00, 0x53};
  80. static const USHORT ModeIndex_320x240_FSTN[] = {0x5a, 0x5b, 0x00, 0x00}; /* FSTN */
  81. static const USHORT ModeIndex_400x300[] = {0x51, 0x57, 0x00, 0x54};
  82. static const USHORT ModeIndex_512x384[] = {0x52, 0x58, 0x00, 0x5c};
  83. static const USHORT ModeIndex_640x400[] = {0x2f, 0x5d, 0x00, 0x5e};
  84. static const USHORT ModeIndex_640x480[] = {0x2e, 0x44, 0x00, 0x62};
  85. static const USHORT ModeIndex_720x480[] = {0x31, 0x33, 0x00, 0x35};
  86. static const USHORT ModeIndex_720x576[] = {0x32, 0x34, 0x00, 0x36};
  87. static const USHORT ModeIndex_768x576[] = {0x5f, 0x60, 0x00, 0x61};
  88. static const USHORT ModeIndex_800x480[] = {0x70, 0x7a, 0x00, 0x76};
  89. static const USHORT ModeIndex_800x600[] = {0x30, 0x47, 0x00, 0x63};
  90. static const USHORT ModeIndex_848x480[] = {0x39, 0x3b, 0x00, 0x3e};
  91. static const USHORT ModeIndex_856x480[] = {0x3f, 0x42, 0x00, 0x45};
  92. static const USHORT ModeIndex_960x540[] = {0x1d, 0x1e, 0x00, 0x1f}; /* 315 series only */
  93. static const USHORT ModeIndex_960x600[] = {0x20, 0x21, 0x00, 0x22}; /* 315 series only */
  94. static const USHORT ModeIndex_1024x768[] = {0x38, 0x4a, 0x00, 0x64};
  95. static const USHORT ModeIndex_1024x576[] = {0x71, 0x74, 0x00, 0x77};
  96. static const USHORT ModeIndex_1024x600[] = {0x20, 0x21, 0x00, 0x22}; /* 300 series only */
  97. static const USHORT ModeIndex_1280x1024[] = {0x3a, 0x4d, 0x00, 0x65};
  98. static const USHORT ModeIndex_1280x960[] = {0x7c, 0x7d, 0x00, 0x7e};
  99. static const USHORT ModeIndex_1152x768[] = {0x23, 0x24, 0x00, 0x25}; /* 300 series only */
  100. static const USHORT ModeIndex_1152x864[] = {0x29, 0x2a, 0x00, 0x2b};
  101. static const USHORT ModeIndex_300_1280x768[] = {0x55, 0x5a, 0x00, 0x5b};
  102. static const USHORT ModeIndex_310_1280x768[] = {0x23, 0x24, 0x00, 0x25};
  103. static const USHORT ModeIndex_1280x720[] = {0x79, 0x75, 0x00, 0x78};
  104. static const USHORT ModeIndex_1280x800[] = {0x14, 0x15, 0x00, 0x16};
  105. static const USHORT ModeIndex_1360x768[] = {0x48, 0x4b, 0x00, 0x4e};
  106. static const USHORT ModeIndex_300_1360x1024[]= {0x67, 0x6f, 0x00, 0x72}; /* 300 series, BARCO only */
  107. static const USHORT ModeIndex_1400x1050[] = {0x26, 0x27, 0x00, 0x28}; /* 315 series only */
  108. static const USHORT ModeIndex_1680x1050[] = {0x17, 0x18, 0x00, 0x19}; /* 315 series only */
  109. static const USHORT ModeIndex_1600x1200[] = {0x3c, 0x3d, 0x00, 0x66};
  110. static const USHORT ModeIndex_1920x1080[] = {0x2c, 0x2d, 0x00, 0x73}; /* 315 series only */
  111. static const USHORT ModeIndex_1920x1440[] = {0x68, 0x69, 0x00, 0x6b};
  112. static const USHORT ModeIndex_300_2048x1536[]= {0x6c, 0x6d, 0x00, 0x00};
  113. static const USHORT ModeIndex_310_2048x1536[]= {0x6c, 0x6d, 0x00, 0x6e};
  114. static const USHORT SiS_DRAMType[17][5]={
  115. {0x0C,0x0A,0x02,0x40,0x39},
  116. {0x0D,0x0A,0x01,0x40,0x48},
  117. {0x0C,0x09,0x02,0x20,0x35},
  118. {0x0D,0x09,0x01,0x20,0x44},
  119. {0x0C,0x08,0x02,0x10,0x31},
  120. {0x0D,0x08,0x01,0x10,0x40},
  121. {0x0C,0x0A,0x01,0x20,0x34},
  122. {0x0C,0x09,0x01,0x08,0x32},
  123. {0x0B,0x08,0x02,0x08,0x21},
  124. {0x0C,0x08,0x01,0x08,0x30},
  125. {0x0A,0x08,0x02,0x04,0x11},
  126. {0x0B,0x0A,0x01,0x10,0x28},
  127. {0x09,0x08,0x02,0x02,0x01},
  128. {0x0B,0x09,0x01,0x08,0x24},
  129. {0x0B,0x08,0x01,0x04,0x20},
  130. {0x0A,0x08,0x01,0x02,0x10},
  131. {0x09,0x08,0x01,0x01,0x00}
  132. };
  133. static const USHORT SiS_SDRDRAM_TYPE[13][5] =
  134. {
  135. { 2,12, 9,64,0x35},
  136. { 1,13, 9,64,0x44},
  137. { 2,12, 8,32,0x31},
  138. { 2,11, 9,32,0x25},
  139. { 1,12, 9,32,0x34},
  140. { 1,13, 8,32,0x40},
  141. { 2,11, 8,16,0x21},
  142. { 1,12, 8,16,0x30},
  143. { 1,11, 9,16,0x24},
  144. { 1,11, 8, 8,0x20},
  145. { 2, 9, 8, 4,0x01},
  146. { 1,10, 8, 4,0x10},
  147. { 1, 9, 8, 2,0x00}
  148. };
  149. static const USHORT SiS_DDRDRAM_TYPE[4][5] =
  150. {
  151. { 2,12, 9,64,0x35},
  152. { 2,12, 8,32,0x31},
  153. { 2,11, 8,16,0x21},
  154. { 2, 9, 8, 4,0x01}
  155. };
  156. static const USHORT SiS_MDA_DAC[] =
  157. {
  158. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  159. 0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
  160. 0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
  161. 0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,
  162. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  163. 0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
  164. 0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
  165. 0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F,0x3F
  166. };
  167. static const USHORT SiS_CGA_DAC[] =
  168. {
  169. 0x00,0x10,0x04,0x14,0x01,0x11,0x09,0x15,
  170. 0x00,0x10,0x04,0x14,0x01,0x11,0x09,0x15,
  171. 0x2A,0x3A,0x2E,0x3E,0x2B,0x3B,0x2F,0x3F,
  172. 0x2A,0x3A,0x2E,0x3E,0x2B,0x3B,0x2F,0x3F,
  173. 0x00,0x10,0x04,0x14,0x01,0x11,0x09,0x15,
  174. 0x00,0x10,0x04,0x14,0x01,0x11,0x09,0x15,
  175. 0x2A,0x3A,0x2E,0x3E,0x2B,0x3B,0x2F,0x3F,
  176. 0x2A,0x3A,0x2E,0x3E,0x2B,0x3B,0x2F,0x3F
  177. };
  178. static const USHORT SiS_EGA_DAC[] =
  179. {
  180. 0x00,0x10,0x04,0x14,0x01,0x11,0x05,0x15,
  181. 0x20,0x30,0x24,0x34,0x21,0x31,0x25,0x35,
  182. 0x08,0x18,0x0C,0x1C,0x09,0x19,0x0D,0x1D,
  183. 0x28,0x38,0x2C,0x3C,0x29,0x39,0x2D,0x3D,
  184. 0x02,0x12,0x06,0x16,0x03,0x13,0x07,0x17,
  185. 0x22,0x32,0x26,0x36,0x23,0x33,0x27,0x37,
  186. 0x0A,0x1A,0x0E,0x1E,0x0B,0x1B,0x0F,0x1F,
  187. 0x2A,0x3A,0x2E,0x3E,0x2B,0x3B,0x2F,0x3F
  188. };
  189. static const USHORT SiS_VGA_DAC[] =
  190. {
  191. 0x00,0x10,0x04,0x14,0x01,0x11,0x09,0x15,
  192. 0x2A,0x3A,0x2E,0x3E,0x2B,0x3B,0x2F,0x3F,
  193. 0x00,0x05,0x08,0x0B,0x0E,0x11,0x14,0x18,
  194. 0x1C,0x20,0x24,0x28,0x2D,0x32,0x38,0x3F,
  195. 0x00,0x10,0x1F,0x2F,0x3F,0x1F,0x27,0x2F,
  196. 0x37,0x3F,0x2D,0x31,0x36,0x3A,0x3F,0x00,
  197. 0x07,0x0E,0x15,0x1C,0x0E,0x11,0x15,0x18,
  198. 0x1C,0x14,0x16,0x18,0x1A,0x1C,0x00,0x04,
  199. 0x08,0x0C,0x10,0x08,0x0A,0x0C,0x0E,0x10,
  200. 0x0B,0x0C,0x0D,0x0F,0x10
  201. };
  202. static const SiS_StResInfoStruct SiS_StResInfo[]=
  203. {
  204. { 640,400},
  205. { 640,350},
  206. { 720,400},
  207. { 720,350},
  208. { 640,480}
  209. };
  210. static const SiS_ModeResInfoStruct SiS_ModeResInfo[] =
  211. {
  212. { 320, 200, 8, 8}, /* 0x00 */
  213. { 320, 240, 8, 8}, /* 0x01 */
  214. { 320, 400, 8, 8}, /* 0x02 */
  215. { 400, 300, 8, 8}, /* 0x03 */
  216. { 512, 384, 8, 8}, /* 0x04 */
  217. { 640, 400, 8,16}, /* 0x05 */
  218. { 640, 480, 8,16}, /* 0x06 */
  219. { 800, 600, 8,16}, /* 0x07 */
  220. { 1024, 768, 8,16}, /* 0x08 */
  221. { 1280,1024, 8,16}, /* 0x09 */
  222. { 1600,1200, 8,16}, /* 0x0a */
  223. { 1920,1440, 8,16}, /* 0x0b */
  224. { 2048,1536, 8,16}, /* 0x0c */
  225. { 720, 480, 8,16}, /* 0x0d */
  226. { 720, 576, 8,16}, /* 0x0e */
  227. { 1280, 960, 8,16}, /* 0x0f */
  228. { 800, 480, 8,16}, /* 0x10 */
  229. { 1024, 576, 8,16}, /* 0x11 */
  230. { 1280, 720, 8,16}, /* 0x12 */
  231. { 856, 480, 8,16}, /* 0x13 */
  232. { 1280, 768, 8,16}, /* 0x14 */
  233. { 1400,1050, 8,16}, /* 0x15 */
  234. { 1152, 864, 8,16}, /* 0x16 */
  235. { 848, 480, 8,16}, /* 0x17 */
  236. { 1360, 768, 8,16}, /* 0x18 */
  237. { 1024, 600, 8,16}, /* 0x19 */
  238. { 1152, 768, 8,16}, /* 0x1a */
  239. { 768, 576, 8,16}, /* 0x1b */
  240. { 1360,1024, 8,16}, /* 0x1c */
  241. { 1680,1050, 8,16}, /* 0x1d */
  242. { 1280, 800, 8,16}, /* 0x1e */
  243. { 1920,1080, 8,16}, /* 0x1f */
  244. { 960, 540, 8,16}, /* 0x20 */
  245. { 960, 600, 8,16} /* 0x21 */
  246. };
  247. #if defined(SIS300) || defined(SIS315H)
  248. static const SiS_StandTableStruct SiS_StandTable[]=
  249. {
  250. /* 0x00: MD_0_200 */
  251. {
  252. 0x28,0x18,0x08,0x0800,
  253. {0x09,0x03,0x00,0x02},
  254. 0x63,
  255. {0x2d,0x27,0x28,0x90,0x2b,0xa0,0xbf,0x1f,
  256. 0x00,0xc7,0x06,0x07,0x00,0x00,0x00,0x00,
  257. 0x9c,0x8e,0x8f,0x14,0x1f,0x96,0xb9,0xa3,
  258. 0xff},
  259. {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,
  260. 0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,
  261. 0x08,0x00,0x0f,0x00},
  262. {0x00,0x00,0x00,0x00,0x00,0x10,0x0e,0x00,
  263. 0xff}
  264. },
  265. /* 0x01: MD_1_200 */
  266. {
  267. 0x28,0x18,0x08,0x0800,
  268. {0x09,0x03,0x00,0x02},
  269. 0x63,
  270. {0x2d,0x27,0x28,0x90,0x2b,0xa0,0xbf,0x1f,
  271. 0x00,0xc7,0x06,0x07,0x00,0x00,0x00,0x00,
  272. 0x9c,0x8e,0x8f,0x14,0x1f,0x96,0xb9,0xa3,
  273. 0xff},
  274. {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,
  275. 0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,
  276. 0x08,0x00,0x0f,0x00},
  277. {0x00,0x00,0x00,0x00,0x00,0x10,0x0e,0x00,
  278. 0xff}
  279. },
  280. /* 0x02: MD_2_200 */
  281. {
  282. 0x50,0x18,0x08,0x1000,
  283. {0x01,0x03,0x00,0x02},
  284. 0x63,
  285. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f,
  286. 0x00,0xc7,0x06,0x07,0x00,0x00,0x00,0x00,
  287. 0x9c,0x8e,0x8f,0x28,0x1f,0x96,0xb9,0xa3,
  288. 0xff},
  289. {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,
  290. 0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,
  291. 0x08,0x00,0x0f,0x00},
  292. {0x00,0x00,0x00,0x00,0x00,0x10,0x0e,0x00,
  293. 0xff}
  294. },
  295. /* 0x03: MD_3_200 - mode 0x03 - 0 */
  296. {
  297. 0x50,0x18,0x08,0x1000,
  298. {0x01,0x03,0x00,0x02},
  299. 0x63,
  300. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f,
  301. 0x00,0xc7,0x06,0x07,0x00,0x00,0x00,0x00,
  302. 0x9c,0x8e,0x8f,0x28,0x1f,0x96,0xb9,0xa3,
  303. 0xff},
  304. {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,
  305. 0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,
  306. 0x08,0x00,0x0f,0x00},
  307. {0x00,0x00,0x00,0x00,0x00,0x10,0x0e,0x00,
  308. 0xff}
  309. },
  310. /* 0x04: MD_4 */
  311. {
  312. 0x28,0x18,0x08,0x4000,
  313. {0x09,0x03,0x00,0x02},
  314. 0x63,
  315. {0x2d,0x27,0x28,0x90,0x2c,0x80,0xbf,0x1f, /* 0x2c is 2b for 300 */
  316. 0x00,0xc1,0x00,0x00,0x00,0x00,0x00,0x00,
  317. 0x9c,0x8e,0x8f,0x14,0x00,0x96,0xb9,0xa2,
  318. 0xff},
  319. {0x00,0x13,0x15,0x17,0x02,0x04,0x06,0x07,
  320. 0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,
  321. 0x01,0x00,0x03,0x00},
  322. {0x00,0x00,0x00,0x00,0x00,0x30,0x0f,0x00,
  323. 0xff}
  324. },
  325. /* 0x05: MD_5 */
  326. {
  327. 0x28,0x18,0x08,0x4000,
  328. {0x09,0x03,0x00,0x02},
  329. 0x63,
  330. {0x2d,0x27,0x28,0x90,0x2c,0x80,0xbf,0x1f, /* 0x2c is 2b for 300 */
  331. 0x00,0xc1,0x00,0x00,0x00,0x00,0x00,0x00,
  332. 0x9c,0x8e,0x8f,0x14,0x00,0x96,0xb9,0xa2,
  333. 0xff},
  334. {0x00,0x13,0x15,0x17,0x02,0x04,0x06,0x07,
  335. 0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,
  336. 0x01,0x00,0x03,0x00},
  337. {0x00,0x00,0x00,0x00,0x00,0x30,0x0f,0x00,
  338. 0xff}
  339. },
  340. /* 0x06: MD_6 */
  341. {
  342. 0x50,0x18,0x08,0x4000,
  343. {0x01,0x01,0x00,0x06},
  344. 0x63,
  345. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f, /* 55,81 is 54,80 for 300 */
  346. 0x00,0xc1,0x00,0x00,0x00,0x00,0x00,0x00,
  347. 0x9c,0x8e,0x8f,0x28,0x00,0x96,0xb9,0xc2,
  348. 0xff},
  349. {0x00,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
  350. 0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17,
  351. 0x01,0x00,0x01,0x00},
  352. {0x00,0x00,0x00,0x00,0x00,0x00,0x0d,0x00,
  353. 0xff}
  354. },
  355. /* 0x07: MD_7 */
  356. {
  357. 0x50,0x18,0x0e,0x1000,
  358. {0x00,0x03,0x00,0x03},
  359. 0xa6,
  360. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f,
  361. 0x00,0x4d,0x0b,0x0c,0x00,0x00,0x00,0x00,
  362. 0x83,0x85,0x5d,0x28,0x0d,0x63,0xba,0xa3,
  363. 0xff},
  364. {0x00,0x08,0x08,0x08,0x08,0x08,0x08,0x08,
  365. 0x10,0x18,0x18,0x18,0x18,0x18,0x18,0x18,
  366. 0x0e,0x00,0x0f,0x08},
  367. {0x00,0x00,0x00,0x00,0x00,0x10,0x0a,0x00,
  368. 0xff}
  369. },
  370. /* 0x08: MDA_DAC */
  371. {
  372. 0x00,0x00,0x00,0x0000,
  373. {0x00,0x00,0x00,0x15},
  374. 0x15,
  375. {0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
  376. 0x15,0x15,0x15,0x15,0x15,0x15,0x3f,0x3f,
  377. 0x3f,0x3f,0x3f,0x3f,0x3f,0x3f,0x00,0x00,
  378. 0x00},
  379. {0x00,0x00,0x00,0x00,0x00,0x15,0x15,0x15,
  380. 0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15,
  381. 0x15,0x15,0x15,0x15},
  382. {0x15,0x3f,0x3f,0x3f,0x3f,0x3f,0x3f,0x3f,
  383. 0x3f}
  384. },
  385. /* 0x09: CGA_DAC */
  386. {
  387. 0x00,0x10,0x04,0x0114,
  388. {0x11,0x09,0x15,0x00},
  389. 0x10,
  390. {0x04,0x14,0x01,0x11,0x09,0x15,0x2a,0x3a,
  391. 0x2e,0x3e,0x2b,0x3b,0x2f,0x3f,0x2a,0x3a,
  392. 0x2e,0x3e,0x2b,0x3b,0x2f,0x3f,0x00,0x10,
  393. 0x04},
  394. {0x14,0x01,0x11,0x09,0x15,0x00,0x10,0x04,
  395. 0x14,0x01,0x11,0x09,0x15,0x2a,0x3a,0x2e,
  396. 0x3e,0x2b,0x3b,0x2f},
  397. {0x3f,0x2a,0x3a,0x2e,0x3e,0x2b,0x3b,0x2f,
  398. 0x3f}
  399. },
  400. /* 0x0a: EGA_DAC */
  401. {
  402. 0x00,0x10,0x04,0x0114,
  403. {0x11,0x05,0x15,0x20},
  404. 0x30,
  405. {0x24,0x34,0x21,0x31,0x25,0x35,0x08,0x18,
  406. 0x0c,0x1c,0x09,0x19,0x0d,0x1d,0x28,0x38,
  407. 0x2c,0x3c,0x29,0x39,0x2d,0x3d,0x02,0x12,
  408. 0x06},
  409. {0x16,0x03,0x13,0x07,0x17,0x22,0x32,0x26,
  410. 0x36,0x23,0x33,0x27,0x37,0x0a,0x1a,0x0e,
  411. 0x1e,0x0b,0x1b,0x0f},
  412. {0x1f,0x2a,0x3a,0x2e,0x3e,0x2b,0x3b,0x2f,
  413. 0x3f}
  414. },
  415. /* 0x0b: VGA_DAC */
  416. {
  417. 0x00,0x10,0x04,0x0114,
  418. {0x11,0x09,0x15,0x2a},
  419. 0x3a,
  420. {0x2e,0x3e,0x2b,0x3b,0x2f,0x3f,0x00,0x05,
  421. 0x08,0x0b,0x0e,0x11,0x14,0x18,0x1c,0x20,
  422. 0x24,0x28,0x2d,0x32,0x38,0x3f,0x00,0x10,
  423. 0x1f},
  424. {0x2f,0x3f,0x1f,0x27,0x2f,0x37,0x3f,0x2d,
  425. 0x31,0x36,0x3a,0x3f,0x00,0x07,0x0e,0x15,
  426. 0x1c,0x0e,0x11,0x15},
  427. {0x18,0x1c,0x14,0x16,0x18,0x1a,0x1c,0x00,
  428. 0x04}
  429. },
  430. /* 0x0c */
  431. {
  432. 0x08,0x0c,0x10,0x0a08,
  433. {0x0c,0x0e,0x10,0x0b},
  434. 0x0c,
  435. {0x0d,0x0f,0x10,0x10,0x01,0x08,0x00,0x00,
  436. 0x00,0x00,0x01,0x00,0x02,0x02,0x01,0x00,
  437. 0x04,0x04,0x01,0x00,0x05,0x02,0x05,0x00,
  438. 0x06},
  439. {0x01,0x06,0x05,0x06,0x00,0x08,0x01,0x08,
  440. 0x00,0x07,0x02,0x07,0x06,0x07,0x00,0x00,
  441. 0x00,0x00,0x00,0x00},
  442. {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  443. 0x00}
  444. },
  445. /* 0x0d: MD_D */
  446. {
  447. 0x28,0x18,0x08,0x2000,
  448. {0x09,0x0f,0x00,0x06},
  449. 0x63,
  450. {0x2d,0x27,0x28,0x90,0x2c,0x80,0xbf,0x1f, /* 2c is 2b for 300 */
  451. 0x00,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,
  452. 0x9c,0x8e,0x8f,0x14,0x00,0x96,0xb9,0xe3,
  453. 0xff},
  454. {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,
  455. 0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,
  456. 0x01,0x00,0x0f,0x00},
  457. {0x00,0x00,0x00,0x00,0x00,0x00,0x05,0x0f,
  458. 0xff}
  459. },
  460. /* 0x0e: MD_E */
  461. {
  462. 0x50,0x18,0x08,0x4000,
  463. {0x01,0x0f,0x00,0x06},
  464. 0x63,
  465. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f, /* 55,81 is 54,80 for 300 */
  466. 0x00,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,
  467. 0x9c,0x8e,0x8f,0x28,0x00,0x96,0xb9,0xe3,
  468. 0xff},
  469. {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,
  470. 0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17,
  471. 0x01,0x00,0x0f,0x00},
  472. {0x00,0x00,0x00,0x00,0x00,0x00,0x05,0x0f,
  473. 0xff}
  474. },
  475. /* 0x0f: ExtVGATable - modes > 0x13 */
  476. {
  477. 0x00,0x00,0x00,0x0000,
  478. {0x01,0x0f,0x00,0x0e},
  479. 0x23,
  480. {0x5f,0x4f,0x50,0x82,0x54,0x80,0x0b,0x3e,
  481. 0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,
  482. 0xea,0x8c,0xdf,0x28,0x40,0xe7,0x04,0xa3,
  483. 0xff},
  484. {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,
  485. 0x08,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x0f,
  486. 0x01,0x00,0x00,0x00},
  487. {0x00,0x00,0x00,0x00,0x00,0x40,0x05,0x0f,
  488. 0xff}
  489. },
  490. /* 0x10: ROM_SAVEPTR - totally different for 300 */
  491. {
  492. 0x9f,0x3b,0x00,0x00c0,
  493. {0x00,0x00,0x00,0x00},
  494. 0x00,
  495. {0x00,0x00,0x00,0x00,0x00,0x00,0xbb,0x3f,
  496. 0x00,0xc0,0x00,0x00,0x00,0x00,0x00,0x00,
  497. 0x00,0x00,0x1a,0x00,0xac,0x3e,0x00,0xc0,
  498. 0x00},
  499. {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  500. 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  501. 0x00,0x00,0x00,0x00},
  502. {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
  503. 0x00}
  504. },
  505. /* 0x11: MD_F */
  506. {
  507. 0x50,0x18,0x0e,0x8000,
  508. {0x01,0x0f,0x00,0x06},
  509. 0xa2,
  510. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f, /* 55,81 is 54,80 on 300 */
  511. 0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,
  512. 0x82,0x84,0x5d,0x28,0x0f,0x63,0xba,0xe3, /* 82,84 is 83,85 on 300 */
  513. 0xff},
  514. {0x00,0x08,0x00,0x00,0x18,0x18,0x00,0x00,
  515. 0x00,0x08,0x00,0x00,0x00,0x18,0x00,0x00,
  516. 0x0b,0x00,0x05,0x00},
  517. {0x00,0x00,0x00,0x00,0x00,0x00,0x05,0x05,
  518. 0xff}
  519. },
  520. /* 0x12: MD_10 */
  521. {
  522. 0x50,0x18,0x0e,0x8000,
  523. {0x01,0x0f,0x00,0x06},
  524. 0xa3,
  525. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f, /* 55,81 is 54,80 on 300 */
  526. 0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,
  527. 0x82,0x84,0x5d,0x28,0x0f,0x63,0xba,0xe3, /* 82,84 is 83,85 on 300 */
  528. 0xff},
  529. {0x00,0x01,0x02,0x03,0x04,0x05,0x14,0x07,
  530. 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,
  531. 0x01,0x00,0x0f,0x00},
  532. {0x00,0x00,0x00,0x00,0x00,0x00,0x05,0x0f,
  533. 0xff}
  534. },
  535. /* 0x13: MD_0_350 */
  536. {
  537. 0x28,0x18,0x0e,0x0800,
  538. {0x09,0x03,0x00,0x02},
  539. 0xa3,
  540. {0x2d,0x27,0x28,0x90,0x2b,0xb1,0xbf,0x1f, /* b1 is a0 on 300 */
  541. 0x00,0x4d,0x0b,0x0c,0x00,0x00,0x00,0x00,
  542. 0x83,0x85,0x5d,0x14,0x1f,0x63,0xba,0xa3,
  543. 0xff},
  544. {0x00,0x01,0x02,0x03,0x04,0x05,0x14,0x07,
  545. 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,
  546. 0x08,0x00,0x0f,0x00},
  547. {0x00,0x00,0x00,0x00,0x00,0x10,0x0e,0x00,
  548. 0xff}
  549. },
  550. /* 0x14: MD_1_350 */
  551. {
  552. 0x28,0x18,0x0e,0x0800,
  553. {0x09,0x03,0x00,0x02},
  554. 0xa3,
  555. {0x2d,0x27,0x28,0x90,0x2b,0xa0,0xbf,0x1f,
  556. 0x00,0x4d,0x0b,0x0c,0x00,0x00,0x00,0x00,
  557. 0x83,0x85,0x5d,0x14,0x1f,0x63,0xba,0xa3,
  558. 0xff},
  559. {0x00,0x01,0x02,0x03,0x04,0x05,0x14,0x07,
  560. 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,
  561. 0x08,0x00,0x0f,0x00},
  562. {0x00,0x00,0x00,0x00,0x00,0x10,0x0e,0x00,
  563. 0xff}
  564. },
  565. /* 0x15: MD_2_350 */
  566. {
  567. 0x50,0x18,0x0e,0x1000,
  568. {0x01,0x03,0x00,0x02},
  569. 0xa3,
  570. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f,
  571. 0x00,0x4d,0x0b,0x0c,0x00,0x00,0x00,0x00,
  572. 0x83,0x85,0x5d,0x28,0x1f,0x63,0xba,0xa3,
  573. 0xff},
  574. {0x00,0x01,0x02,0x03,0x04,0x05,0x14,0x07,
  575. 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,
  576. 0x08,0x00,0x0f,0x00},
  577. {0x00,0x00,0x00,0x00,0x00,0x10,0x0e,0x00,
  578. 0xff}
  579. },
  580. /* 0x16: MD_3_350 - mode 0x03 - 1 */
  581. {
  582. 0x50,0x18,0x0e,0x1000,
  583. {0x01,0x03,0x00,0x02},
  584. 0xa3,
  585. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f,
  586. 0x00,0x4d,0x0b,0x0c,0x00,0x00,0x00,0x00,
  587. 0x83,0x85,0x5d,0x28,0x1f,0x63,0xba,0xa3,
  588. 0xff},
  589. {0x00,0x01,0x02,0x03,0x04,0x05,0x14,0x07,
  590. 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,
  591. 0x08,0x00,0x0f,0x00},
  592. {0x00,0x00,0x00,0x00,0x00,0x10,0x0e,0x00,
  593. 0xff}
  594. },
  595. /* 0x17: MD_0_1_400 */
  596. {
  597. 0x28,0x18,0x10,0x0800,
  598. {0x08,0x03,0x00,0x02},
  599. 0x67,
  600. {0x2d,0x27,0x28,0x90,0x2b,0xb1,0xbf,0x1f, /* b1 is a0 on 300 */
  601. 0x00,0x4f,0x0d,0x0e,0x00,0x00,0x00,0x00,
  602. 0x9c,0x8e,0x8f,0x14,0x1f,0x96,0xb9,0xa3,
  603. 0xff},
  604. {0x00,0x01,0x02,0x03,0x04,0x05,0x14,0x07,
  605. 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,
  606. 0x0c,0x00,0x0f,0x08},
  607. {0x00,0x00,0x00,0x00,0x00,0x10,0x0e,0x00,
  608. 0xff}
  609. },
  610. /* 0x18: MD_2_3_400 - mode 0x03 - 2 */
  611. {
  612. 0x50,0x18,0x10,0x1000,
  613. {0x00,0x03,0x00,0x02},
  614. 0x67,
  615. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f,
  616. 0x00,0x4f,0x0d,0x0e,0x00,0x00,0x00,0x00,
  617. 0x9c,0x8e,0x8f,0x28,0x1f,0x96,0xb9,0xa3,
  618. 0xff},
  619. {0x00,0x01,0x02,0x03,0x04,0x05,0x14,0x07,
  620. 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,
  621. 0x0c,0x00,0x0f,0x08},
  622. {0x00,0x00,0x00,0x00,0x00,0x10,0x0e,0x00,
  623. 0xff}
  624. },
  625. /* 0x19: MD_7_400 */
  626. {
  627. 0x50,0x18,0x10,0x1000,
  628. {0x00,0x03,0x00,0x02},
  629. 0x66,
  630. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f,
  631. 0x00,0x4f,0x0d,0x0e,0x00,0x00,0x00,0x00,
  632. 0x9c,0x8e,0x8f,0x28,0x0f,0x96,0xb9,0xa3,
  633. 0xff},
  634. {0x00,0x08,0x08,0x08,0x08,0x08,0x08,0x08,
  635. 0x10,0x18,0x18,0x18,0x18,0x18,0x18,0x18,
  636. 0x0e,0x00,0x0f,0x08},
  637. {0x00,0x00,0x00,0x00,0x00,0x10,0x0a,0x00,
  638. 0xff}
  639. },
  640. /* 0x1a: MD_11 */
  641. {
  642. 0x50,0x1d,0x10,0xa000,
  643. {0x01,0x0f,0x00,0x06},
  644. 0xe3,
  645. {0x5f,0x4f,0x50,0x82,0x55,0x81,0x0b,0x3e, /* 55,81 is 54,80 on 300 */
  646. 0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,
  647. 0xe9,0x8b,0xdf,0x28,0x00,0xe7,0x04,0xc3, /* e9,8b is ea,8c on 300 */
  648. 0xff},
  649. {0x00,0x3f,0x3f,0x3f,0x3f,0x3f,0x3f,0x3f,
  650. 0x3f,0x3f,0x3f,0x3f,0x3f,0x3f,0x3f,0x3f,
  651. 0x01,0x00,0x0f,0x00},
  652. {0x00,0x00,0x00,0x00,0x00,0x00,0x05,0x01,
  653. 0xff}
  654. },
  655. /* 0x1b: ExtEGATable - Modes <= 0x02 */
  656. {
  657. 0x50,0x1d,0x10,0xa000,
  658. {0x01,0x0f,0x00,0x06},
  659. 0xe3,
  660. {0x5f,0x4f,0x50,0x82,0x55,0x81,0x0b,0x3e, /* 55,81 is 54,80 on 300 */
  661. 0x00,0x40,0x00,0x00,0x00,0x00,0x00,0x00,
  662. 0xe9,0x8b,0xdf,0x28,0x00,0xe7,0x04,0xe3, /* e9,8b is ea,8c on 300 */
  663. 0xff},
  664. {0x00,0x01,0x02,0x03,0x04,0x05,0x14,0x07,
  665. 0x38,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,0x3f,
  666. 0x01,0x00,0x0f,0x00},
  667. {0x00,0x00,0x00,0x00,0x00,0x00,0x05,0x0f,
  668. 0xff}
  669. },
  670. /* 0x1c: MD_13 */
  671. {
  672. 0x28,0x18,0x08,0x2000,
  673. {0x01,0x0f,0x00,0x0e},
  674. 0x63,
  675. {0x5f,0x4f,0x50,0x82,0x55,0x81,0xbf,0x1f, /* 55,81 is 54,80 on 300 */
  676. 0x00,0x41,0x00,0x00,0x00,0x00,0x00,0x00,
  677. 0x9c,0x8e,0x8f,0x28,0x40,0x96,0xb9,0xa3,
  678. 0xff},
  679. {0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07,
  680. 0x08,0x09,0x0a,0x0b,0x0c,0x0d,0x0e,0x0f,
  681. 0x41,0x00,0x0f,0x00},
  682. {0x00,0x00,0x00,0x00,0x00,0x40,0x05,0x0f,
  683. 0xff}
  684. }
  685. };
  686. #endif
  687. /**************************************************************/
  688. /* SIS VIDEO BRIDGE ----------------------------------------- */
  689. /**************************************************************/
  690. static const UCHAR SiS_SoftSetting = 0x30; /* RAM setting */
  691. static const UCHAR SiS_OutputSelect = 0x40;
  692. static const UCHAR SiS_NTSCTiming[] = {
  693. 0x17,0x1d,0x03,0x09,0x05,0x06,0x0c,0x0c,
  694. 0x94,0x49,0x01,0x0a,0x06,0x0d,0x04,0x0a,
  695. 0x06,0x14,0x0d,0x04,0x0a,0x00,0x85,0x1b,
  696. 0x0c,0x50,0x00,0x97,0x00,0xda,0x4a,0x17,
  697. 0x7d,0x05,0x4b,0x00,0x00,0xe2,0x00,0x02,
  698. 0x03,0x0a,0x65,0x9d,0x08,0x92,0x8f,0x40,
  699. 0x60,0x80,0x14,0x90,0x8c,0x60,0x14,0x50,
  700. 0x00,0x40,0x44,0x00,0xdb,0x02,0x3b,0x00
  701. };
  702. static const UCHAR SiS_PALTiming[] = {
  703. 0x19,0x52,0x35,0x6e,0x04,0x38,0x3d,0x70,
  704. 0x94,0x49,0x01,0x12,0x06,0x3e,0x35,0x6d,
  705. 0x06,0x14,0x3e,0x35,0x6d,0x00,0x45,0x2b,
  706. 0x70,0x50,0x00,0x9b,0x00,0xd9,0x5d,0x17,
  707. 0x7d,0x05,0x45,0x00,0x00,0xe8,0x00,0x02,
  708. 0x0d,0x00,0x68,0xb0,0x0b,0x92,0x8f,0x40,
  709. 0x60,0x80,0x14,0x90,0x8c,0x60,0x14,0x63,
  710. 0x00,0x40,0x3e,0x00,0xe1,0x02,0x28,0x00
  711. };
  712. static const UCHAR SiS_HiTVExtTiming[] = {
  713. 0x32,0x65,0x2c,0x5f,0x08,0x31,0x3a,0x64,
  714. 0x28,0x02,0x01,0x3d,0x06,0x3e,0x35,0x6d,
  715. 0x06,0x14,0x3e,0x35,0x6d,0x00,0xc5,0x3f,
  716. 0x64,0x90,0x33,0x8c,0x18,0x36,0x3e,0x13,
  717. 0x2a,0xde,0x2a,0x44,0x40,0x2a,0x44,0x40,
  718. 0x8e,0x8e,0x82,0x07,0x0b,0x92,0x0f,0x40,
  719. 0x60,0x80,0x14,0x90,0x8c,0x60,0x14,0x3d,
  720. 0x63,0x4f,0x27,0x00,0xfc,0xff,0x6a,0x00
  721. };
  722. static const UCHAR SiS_HiTVSt1Timing[] = {
  723. 0x32,0x65,0x2c,0x5f,0x08,0x31,0x3a,0x65,
  724. 0x28,0x02,0x01,0x3d,0x06,0x3e,0x35,0x6d,
  725. 0x06,0x14,0x3e,0x35,0x6d,0x00,0xc5,0x3f,
  726. 0x65,0x90,0x7b,0xa8,0x03,0xf0,0x87,0x03,
  727. 0x11,0x15,0x11,0xcf,0x10,0x11,0xcf,0x10,
  728. 0x35,0x35,0x3b,0x69,0x1d,0x92,0x0f,0x40,
  729. 0x60,0x80,0x14,0x90,0x8c,0x60,0x04,0x86,
  730. 0xaf,0x5d,0x0e,0x00,0xfc,0xff,0x2d,0x00
  731. };
  732. static const UCHAR SiS_HiTVSt2Timing[] = {
  733. 0x32,0x65,0x2c,0x5f,0x08,0x31,0x3a,0x64,
  734. 0x28,0x02,0x01,0x3d,0x06,0x3e,0x35,0x6d,
  735. 0x06,0x14,0x3e,0x35,0x6d,0x00,0xc5,0x3f,
  736. 0x64,0x90,0x33,0x8c,0x18,0x36,0x3e,0x13,
  737. 0x2a,0xde,0x2a,0x44,0x40,0x2a,0x44,0x40,
  738. 0x8e,0x8e,0x82,0x07,0x0b,0x92,0x0f,0x40,
  739. 0x60,0x80,0x14,0x90,0x8c,0x60,0x14,0x3d,
  740. 0x63,0x4f,0x27,0x00,0xfc,0xff,0x6a,0x00
  741. };
  742. #if 0
  743. static const UCHAR SiS_HiTVTextTiming[] = {
  744. 0x32,0x65,0x2c,0x5f,0x08,0x31,0x3a,0x65,
  745. 0x28,0x02,0x01,0x3d,0x06,0x3e,0x35,0x6d,
  746. 0x06,0x14,0x3e,0x35,0x6d,0x00,0xc5,0x3f,
  747. 0x65,0x90,0xe7,0xbc,0x03,0x0c,0x97,0x03,
  748. 0x14,0x78,0x14,0x08,0x20,0x14,0x08,0x20,
  749. 0xc8,0xc8,0x3b,0xd2,0x26,0x92,0x0f,0x40,
  750. 0x60,0x80,0x14,0x90,0x8c,0x60,0x04,0x96,
  751. 0x72,0x5c,0x11,0x00,0xfc,0xff,0x32,0x00
  752. };
  753. #endif
  754. static const UCHAR SiS_HiTVGroup3Data[] = {
  755. 0x00,0x1a,0x22,0x63,0x62,0x22,0x08,0x5f,
  756. 0x05,0x21,0xb2,0xb2,0x55,0x77,0x2a,0xa6,
  757. 0x25,0x2f,0x47,0xfa,0xc8,0xff,0x8e,0x20,
  758. 0x8c,0x6e,0x60,0x2e,0x58,0x48,0x72,0x44,
  759. 0x56,0x36,0x4f,0x6e,0x3f,0x80,0x00,0x80,
  760. 0x4f,0x7f,0x03,0xa8,0x7d,0x20,0x1a,0xa9,
  761. 0x14,0x05,0x03,0x7e,0x64,0x31,0x14,0x75,
  762. 0x18,0x05,0x18,0x05,0x4c,0xa8,0x01
  763. };
  764. static const UCHAR SiS_HiTVGroup3Simu[] = {
  765. 0x00,0x1a,0x22,0x63,0x62,0x22,0x08,0x95,
  766. 0xdb,0x20,0xb8,0xb8,0x55,0x47,0x2a,0xa6,
  767. 0x25,0x2f,0x47,0xfa,0xc8,0xff,0x8e,0x20,
  768. 0x8c,0x6e,0x60,0x15,0x26,0xd3,0xe4,0x11,
  769. 0x56,0x36,0x4f,0x6e,0x3f,0x80,0x00,0x80,
  770. 0x67,0x36,0x01,0x47,0x0e,0x10,0xbe,0xb4,
  771. 0x01,0x05,0x03,0x7e,0x65,0x31,0x14,0x75,
  772. 0x18,0x05,0x18,0x05,0x4c,0xa8,0x01
  773. };
  774. #if 0
  775. static const UCHAR SiS_HiTVGroup3Text[] = {
  776. 0x00,0x1a,0x22,0x63,0x62,0x22,0x08,0xa7,
  777. 0xf5,0x20,0xce,0xce,0x55,0x47,0x2a,0xa6,
  778. 0x25,0x2f,0x47,0xfa,0xc8,0xff,0x8e,0x20,
  779. 0x8c,0x6e,0x60,0x18,0x2c,0x0c,0x20,0x22,
  780. 0x56,0x36,0x4f,0x6e,0x3f,0x80,0x00,0x80,
  781. 0x93,0x3c,0x01,0x50,0x2f,0x10,0xf4,0xca,
  782. 0x01,0x05,0x03,0x7e,0x65,0x31,0x14,0x75,
  783. 0x18,0x05,0x18,0x05,0x4c,0xa8,0x01
  784. };
  785. #endif
  786. static const UCHAR SiS_NTSCPhase[] = {0x21,0xed,0xba,0x08};
  787. static const UCHAR SiS_PALPhase[] = {0x2a,0x05,0xe3,0x00};
  788. static const UCHAR SiS_PALMPhase[] = {0x21,0xE4,0x2E,0x9B};
  789. static const UCHAR SiS_PALNPhase[] = {0x21,0xF4,0x3E,0xBA};
  790. static const UCHAR SiS_NTSCPhase2[] = {0x21,0xF0,0x7B,0xD6};
  791. static const UCHAR SiS_PALPhase2[] = {0x2a,0x09,0x86,0xe9};
  792. static const UCHAR SiS_PALMPhase2[] = {0x21,0xE6,0xEF,0xA4};
  793. static const UCHAR SiS_PALNPhase2[] = {0x21,0xF6,0x94,0x46};
  794. static const UCHAR SiS_SpecialPhase[] = {0x1e,0x8c,0x5c,0x7a};
  795. static const UCHAR SiS_SpecialPhaseM[]= {0x1e,0x83,0x0a,0xe0};
  796. static const UCHAR SiS_SpecialPhaseJ[]= {0x25,0xd4,0xfd,0x5e};
  797. static const SiS_TVDataStruct SiS_StPALData[] =
  798. {
  799. { 1, 1, 864, 525,1270, 400, 100, 0, 760,0xf4,0xff,0x1c,0x22},
  800. { 1, 1, 864, 525,1270, 350, 100, 0, 760,0xf4,0xff,0x1c,0x22},
  801. { 1, 1, 864, 525,1270, 400, 0, 0, 720,0xf1,0x04,0x1f,0x18},
  802. { 1, 1, 864, 525,1270, 350, 0, 0, 720,0xf4,0x0b,0x1c,0x0a},
  803. { 1, 1, 864, 525,1270, 480, 50, 0, 760,0xf4,0xff,0x1c,0x22},
  804. { 1, 1, 864, 525,1270, 600, 50, 0, 0,0xf4,0xff,0x1c,0x22}
  805. };
  806. static const SiS_TVDataStruct SiS_ExtPALData[] =
  807. {
  808. { 27, 10, 848, 448,1270, 530, 50, 0, 50,0xf4,0xff,0x1c,0x22}, /* 640x400, 320x200 */
  809. { 108, 35, 848, 398,1270, 530, 50, 0, 50,0xf4,0xff,0x1c,0x22},
  810. { 12, 5, 954, 448,1270, 530, 50, 0, 50,0xf1,0x04,0x1f,0x18},
  811. { 9, 4, 960, 463,1644, 438, 50, 0, 50,0xf4,0x0b,0x1c,0x0a},
  812. { 9, 4, 848, 528,1270, 530, 0, 0, 50,0xf5,0xfb,0x1b,0x2a}, /* 640x480, 320x240 */
  813. /*{ 36, 25,1060, 648,1316, 530, 438, 0, 438,0xeb,0x05,0x25,0x16},*//* 800x600, 400x300 */
  814. { 36, 25,1060, 648,1270, 530, 438, 0, 438,0xeb,0x05,0x25,0x16}, /* 800x600, 400x300 - better */
  815. { 3, 2,1080, 619,1270, 540, 438, 0, 438,0xf3,0x00,0x1d,0x20}, /* 720x576 */
  816. { 1, 1,1170, 821,1270, 520, 686, 0, 686,0xF3,0x00,0x1D,0x20}, /* 1024x768 */
  817. { 1, 1,1170, 821,1270, 520, 686, 0, 686,0xF3,0x00,0x1D,0x20}, /* 1024x768 (for NTSC equ) */
  818. { 9, 4, 848, 528,1270, 530, 0, 0, 50,0xf5,0xfb,0x1b,0x2a} /* 720x480 test */
  819. };
  820. static const SiS_TVDataStruct SiS_StNTSCData[] =
  821. {
  822. { 1, 1, 858, 525,1270, 400, 50, 0, 760,0xf1,0x04,0x1f,0x18},
  823. { 1, 1, 858, 525,1270, 350, 50, 0, 640,0xf1,0x04,0x1f,0x18},
  824. { 1, 1, 858, 525,1270, 400, 0, 0, 720,0xf1,0x04,0x1f,0x18},
  825. { 1, 1, 858, 525,1270, 350, 0, 0, 720,0xf4,0x0b,0x1c,0x0a},
  826. { 1, 1, 858, 525,1270, 480, 0, 0, 760,0xf1,0x04,0x1f,0x18}
  827. };
  828. static const SiS_TVDataStruct SiS_ExtNTSCData[] =
  829. {
  830. { 143, 65, 858, 443,1270, 440, 171, 0, 171,0xf1,0x04,0x1f,0x18}, /* 640x400, 320x200 */
  831. { 88, 35, 858, 393,1270, 440, 171, 0, 171,0xf1,0x04,0x1f,0x18},
  832. { 143, 70, 924, 443,1270, 440, 92, 0, 92,0xf1,0x04,0x1f,0x18},
  833. { 143, 70, 924, 393,1270, 440, 92, 0, 92,0xf4,0x0b,0x1c,0x0a},
  834. { 143, 76, 836, 523,1270, 440, 224, 0, 0,0xf1,0x05,0x1f,0x16}, /* 640x480, 320x240 */
  835. { 143, 120,1056, 643,1270, 440, 0, 128, 0,0xf4,0x10,0x1c,0x00}, /* 800x600, 400x300 */
  836. /*{ 2, 1, 858, 503,1270, 480, 0, 128, 0,0xee,0x0c,0x22,0x08},*/ /* 720x480 (old, from 650) */
  837. { 143, 76, 836, 523,1270, 440, 0, 128, 0,0xee,0x0c,0x22,0x08}, /* 720x480 - BETTER (from 300 series) */
  838. /*{ 65, 64,1056, 791,1270, 480, 638, 0, 0,0xEE,0x0C,0x22,0x08} */ /* 1024x768 (525i) */
  839. { 1, 1,1100, 811,1412, 440, 0, 128, 0,0xee,0x0c,0x22,0x08}, /* 1024x768 (525i) CORRECTED */
  840. { 65, 64,1056, 791,1270, 480, 455, 0, 0,0x00,0x00,0x00,0x00} /* 1024x768 (525p) */
  841. };
  842. static const SiS_TVDataStruct SiS_StHiTVData[] = /* Slave + TVSimu */
  843. {
  844. { 1, 1, 0x37c,0x233,0x2b2,0x320, 0, 0, 0, 0x00,0x00,0x00,0x00},
  845. { 1, 1, 0x37c,0x233,0x2b2,0x2bc, 0, 0, 0, 0x00,0x00,0x00,0x00},
  846. { 1, 1, 0x37c,0x233,0x2b2,0x320, 0, 0, 0, 0x00,0x00,0x00,0x00},
  847. { 1, 1, 0x37c,0x233,0x2b2,0x2bc, 0, 0, 0, 0x00,0x00,0x00,0x00},
  848. { 1, 1, 0x37c,0x233,0x2b2,0x3c0, 0, 0, 0, 0x00,0x00,0x00,0x00},
  849. { 8, 5, 0x41a,0x2ab,0x670,0x3c0,0x150,128, 0, 0x00,0x00,0x00,0x00}
  850. };
  851. static const SiS_TVDataStruct SiS_St2HiTVData[] = /* Slave */
  852. {
  853. { 3, 1, 0x348,0x1e3,0x670,0x3c0,0x032, 0, 0, 0x00,0x00,0x00,0x00},
  854. { 1, 1, 0x37c,0x233,0x2b2,0x2bc, 0, 0, 0, 0x00,0x00,0x00,0x00},
  855. { 3, 1, 0x348,0x1e3,0x670,0x3c0,0x032, 0, 0, 0x00,0x00,0x00,0x00},
  856. { 1, 1, 0x37c,0x233,0x2b2,0x2bc, 0, 0, 0, 0x00,0x00,0x00,0x00},
  857. { 5, 2, 0x348,0x233,0x670,0x3c0,0x08d,128, 0, 0x00,0x00,0x00,0x00},
  858. { 8, 5, 0x41a,0x2ab,0x670,0x3c0,0x17c,128, 0, 0x00,0x00,0x00,0x00}
  859. };
  860. static const SiS_TVDataStruct SiS_ExtHiTVData[] =
  861. {
  862. { 6, 1, 0x348,0x233,0x660,0x3c0, 0, 0, 0, 0x00,0x00,0x00,0x00},
  863. { 3, 1, 0x3c0,0x233,0x660,0x3c0, 0, 0, 0, 0x00,0x00,0x00,0x00},
  864. { 6, 1, 0x348,0x233,0x660,0x3c0, 0, 0, 0, 0x00,0x00,0x00,0x00},
  865. { 3, 1, 0x3c0,0x233,0x660,0x3c0, 0, 0, 0, 0x00,0x00,0x00,0x00},
  866. { 5, 1, 0x348,0x233,0x670,0x3c0,0x166,128, 0, 0x00,0x00,0x00,0x00}, /* 640x480 */
  867. { 16, 5, 0x41a,0x2ab,0x670,0x3c0,0x143,128, 0, 0x00,0x00,0x00,0x00}, /* 800x600 */
  868. { 25, 12, 0x4ec,0x353,0x670,0x3c0,0x032, 0, 0, 0x00,0x00,0x00,0x00}, /* 1024x768 */
  869. { 5, 4, 0x627,0x464,0x670,0x3c0,0x128, 0, 0, 0x00,0x00,0x00,0x00}, /* 1280x1024 */
  870. { 4, 1, 0x41a,0x233,0x60c,0x3c0,0x143,128, 0, 0x00,0x00,0x00,0x00}, /* 800x480 */
  871. { 5, 2, 0x578,0x293,0x670,0x3c0,0x032, 0, 0, 0x00,0x00,0x00,0x00}, /* 1024x576 */
  872. { 8, 5, 0x6d6,0x323,0x670,0x3c0,0x128, 0, 0, 0x00,0x00,0x00,0x00}, /* 1280x720 */
  873. { 137, 32, 0x3d4,0x233,0x663,0x3bf,0x143, 0, 0, 0x00,0x00,0x00,0x00} /* 960x600 */
  874. };
  875. static const SiS_TVDataStruct SiS_St525pData[] =
  876. {
  877. { 1, 1, 0x6b4,0x20d,0x4f6,0x190, 50, 0, 0x2f8, 0x00,0x00,0x00,0x00},
  878. { 1, 1, 0x6b4,0x20d,0x4f6,0x15e, 50, 0, 0x280, 0x00,0x00,0x00,0x00},
  879. { 1, 1, 0x6b4,0x20d,0x4f6,0x190, 50, 0, 0x2f8, 0x00,0x00,0x00,0x00},
  880. { 1, 1, 0x6b4,0x20d,0x4f6,0x15e, 50, 0, 0x280, 0x00,0x00,0x00,0x00},
  881. { 1, 1, 0x6b4,0x20d,0x4f6,0x1e0, 0, 0, 0x2f8, 0x00,0x00,0x00,0x00}
  882. };
  883. static const SiS_TVDataStruct SiS_St750pData[] =
  884. {
  885. { 1, 1, 0x672,0x2ee,0x500,0x190, 50, 0, 0x2f8, 0x00,0x00,0x00,0x00},
  886. { 1, 1, 0x672,0x2ee,0x500,0x15e, 50, 0, 0x280, 0x00,0x00,0x00,0x00},
  887. { 1, 1, 0x672,0x2ee,0x500,0x190, 0, 0, 0x2d0, 0x00,0x00,0x00,0x00},
  888. { 1, 1, 0x672,0x2ee,0x500,0x15e, 0, 0, 0x2d0, 0x00,0x00,0x00,0x00},
  889. { 1, 1, 0x672,0x2ee,0x500,0x1e0, 0, 0, 0x2f8, 0x00,0x00,0x00,0x00}
  890. };
  891. static const SiS_TVDataStruct SiS_Ext750pData[] =
  892. {
  893. { 143, 65, 0x35a,0x1bb,0x4f6,0x1b8,0x0ab, 0, 0x0ab, 0x00,0x00,0x00,0x00},
  894. { 88, 35, 0x35a,0x189,0x4f6,0x1b8,0x0ab, 0, 0x0ab, 0x00,0x00,0x00,0x00},
  895. { 18, 5, 0x339,0x1ae,0x500,0x2d0,0x05c, 0, 0x05c, 0x00,0x00,0x00,0x00},
  896. { 143, 70, 0x39c,0x189,0x4f6,0x1b8,0x05c, 0, 0x05c, 0x00,0x00,0x00,0x00},
  897. { 99, 32, 0x320,0x1fe,0x500,0x2d0, 50, 0, 0, 0x00,0x00,0x00,0x00}, /* 640x480 */
  898. { 5, 4, 0x5d8,0x29e,0x500,0x2a8, 50, 0, 0, 0x00,0x00,0x00,0x00}, /* 800x600 */
  899. { 99, 32, 0x320,0x1fe,0x500,0x2d0, 50, 0, 0, 0x00,0x00,0x00,0x00}, /* 720x480 test WORKS */
  900. { 68, 64, 0x55f,0x346,0x500,0x2a8,0x27e, 0, 0, 0x00,0x00,0x00,0x00}, /* 1024x768 */
  901. { 5, 2, 0x3a7,0x226,0x500,0x2a8, 0,128, 0, 0x00,0x00,0x00,0x00}, /* 720x576 */
  902. { 25, 24, 0x5d8,0x2f3,0x460,0x2a8, 50, 0, 0, 0x00,0x00,0x00,0x00} /* 1280x720 WORKS */
  903. };
  904. static const SiS_LCDDataStruct SiS_LCD1280x720Data[] = /* 2.03.00 */
  905. {
  906. { 44, 15, 864, 430, 1408, 806 }, /* 640x400 */
  907. { 128, 35, 792, 385, 1408, 806 },
  908. { 44, 15, 864, 430, 1408, 806 },
  909. { 128, 35, 792, 385, 1408, 806 },
  910. { 22, 9, 864, 516, 1408, 806 }, /* 640x480 */
  911. { 8, 5, 1056, 655, 1408, 806 }, /* 800x600 */
  912. { 0, 0, 0, 0, 0, 0 }, /* 1024x768 */
  913. { 0, 0, 0, 0, 0, 0 }, /* 1280x1024 */
  914. { 0, 0, 0, 0, 0, 0 },
  915. { 0, 0, 0, 0, 0, 0 },
  916. { 1, 1, 1408, 806, 1408, 806 } /* 1280x720 */
  917. };
  918. /* About 1280x768: For TMDS, Panel_1280x768 will only be set if
  919. * the panel is a Fujitsu 7911 (VL-17WDX8) (with clock 81, 1688x802)
  920. * Other TMDS panels of this resolution will be treated as custom.
  921. * For LVDS, we know another type (_2).
  922. * (Note: 1280x768_3 is now special for SiS301/NetVista
  923. */
  924. static const SiS_LCDDataStruct SiS_StLCD1280x768_2Data[] = /* 2.03.00 */
  925. {
  926. { 64, 21, 858, 434, 1408, 806 }, /* 640x400 */
  927. { 32, 9, 858, 372, 1408, 806 },
  928. { 64, 21, 858, 434, 1408, 806 },
  929. { 32, 9, 858, 372, 1408, 806 },
  930. { 143, 68, 1024, 527, 1408, 806 }, /* 640x480 */
  931. { 64, 51, 1364, 663, 1408, 806 }, /* 800x600 */
  932. { 88, 81, 1296, 806, 1408, 806 }, /* 1024x768 */
  933. { 0, 0, 0, 0, 0, 0 },
  934. { 1, 1, 1408, 806, 1408, 806 }, /* 1280x768 */
  935. { 0, 0, 0, 0, 0, 0 },
  936. { 16, 15, 1600, 750, 1600, 806 } /* 1280x720 - from Ext */
  937. };
  938. static const SiS_LCDDataStruct SiS_ExtLCD1280x768_2Data[] = /* 2.03.00 */
  939. {
  940. { 16, 5, 960, 410, 1600, 806 }, /* 640x400 */
  941. { 64, 21, 1152, 364, 1600, 806 },
  942. { 16, 5, 960, 410, 1600, 806 },
  943. { 64, 21, 1152, 364, 1600, 806 },
  944. { 32, 13, 1040, 493, 1600, 806 }, /* 640x480 */
  945. { 16, 9, 1152, 618, 1600, 806 }, /* 800x600 */
  946. { 25, 21, 1344, 796, 1600, 806 }, /* 1024x768 */
  947. { 0, 0, 0, 0, 0, 0 },
  948. { 1, 1, 1600, 806, 1600, 806 }, /* 1280x768 */
  949. { 0, 0, 0, 0, 0, 0 },
  950. { 16, 15, 1600, 750, 1600, 806 } /* 1280x720 */
  951. };
  952. #if 0 /* Not used; _3 now reserved for NetVista (SiS301) */
  953. static const SiS_LCDDataStruct SiS_LCD1280x768_3Data[] =
  954. {
  955. { 64, 25, 1056, 422, 1664, 798 }, /* 640x400 */
  956. { 128, 39, 884, 396, 1408, 806 }, /* ,640 */
  957. { 64, 25, 1056, 422, 1664, 798 }, /* 640x400 */
  958. { 128, 39, 884, 396, 1408, 806 }, /* ,640 */
  959. { 32, 15, 1056, 513, 1408, 806 }, /* ,664 */ /* 640x480 */
  960. { 176, 125, 1280, 640, 1408, 806 }, /* ,768 */ /* 800x600 */
  961. { 64, 61, 1342, 806, 1408, 806 }, /* 1024x768 */
  962. { 0, 0, 0, 0, 0, 0 },
  963. { 1, 1, 1408, 806, 1408, 806 }, /* 1280x768 */
  964. { 0, 0, 0, 0, 0, 0 },
  965. { 16, 15, 1600, 750, 1600, 806 } /* 1280x720 from above */
  966. };
  967. #endif
  968. static const SiS_LCDDataStruct SiS_LCD1280x800Data[] = /* 0.93.12a (TMDS) */
  969. {
  970. { 128, 51, 1122, 412, 1408, 816 }, /* 640x400 */
  971. { 128, 49, 1232, 361, 1408, 816 },
  972. { 128, 51, 1122, 412, 1408, 816 },
  973. { 128, 49, 1232, 361, 1408, 816 },
  974. { 8, 3, 880, 491, 1408, 816 }, /* 640x480 */
  975. { 11, 6, 1024, 612, 1408, 816 }, /* 800x600 */
  976. { 22, 21, 1400, 784, 1408, 816 }, /* 1024x768 */
  977. { 0, 0, 0, 0, 0, 0 }, /* 1280x1024 */
  978. { 1, 1, 1408, 816, 1408, 816 }, /* 1280x800 */
  979. { 0, 0, 0, 0, 0, 0 }, /* 1280x768 (patch index) */
  980. { 0, 0, 0, 0, 0, 0 } /* 1280x720 */
  981. };
  982. static const SiS_LCDDataStruct SiS_LCD1280x800_2Data[] = /* 2.03.00 (LVDS) */
  983. {
  984. { 97, 42, 1344, 409, 1552, 812 }, /* 640x400 */
  985. { 97, 35, 1280, 358, 1552, 812 },
  986. { 97, 42, 1344, 409, 1552, 812 },
  987. { 97, 35, 1280, 358, 1552, 812 },
  988. { 97, 39, 1040, 488, 1552, 812 }, /* 640x480 */
  989. { 194, 105, 1120, 608, 1552, 812 }, /* 800x600 */
  990. { 97, 84, 1400, 780, 1552, 812 }, /* 1024x768 */
  991. { 0, 0, 0, 0, 0, 0 }, /* 1280x1024 */
  992. { 1, 1, 1552, 812, 1552, 812 }, /* 1280x800 */
  993. { 97, 96, 1600, 780, 1552, 812 }, /* 1280x768 - patch index */
  994. { 97, 90, 1600, 730, 1552, 812 } /* 1280x720 */
  995. };
  996. static const SiS_LCDDataStruct SiS_LCD1280x960Data[] =
  997. {
  998. { 9, 2, 800, 500, 1800, 1000 },
  999. { 9, 2, 800, 500, 1800, 1000 },
  1000. { 4, 1, 900, 500, 1800, 1000 },
  1001. { 4, 1, 900, 500, 1800, 1000 },
  1002. { 9, 2, 800, 500, 1800, 1000 },
  1003. { 30, 11, 1056, 625, 1800, 1000 },
  1004. { 5, 3, 1350, 800, 1800, 1000 },
  1005. { 1, 1, 1576, 1050, 1576, 1050 },
  1006. { 1, 1, 1800, 1000, 1800, 1000 }
  1007. };
  1008. static const SiS_LCDDataStruct SiS_StLCD1400x1050Data[] =
  1009. {
  1010. { 211, 100, 2100, 408, 1688, 1066 },
  1011. { 211, 64, 1536, 358, 1688, 1066 },
  1012. { 211, 100, 2100, 408, 1688, 1066 },
  1013. { 211, 64, 1536, 358, 1688, 1066 },
  1014. { 211, 48, 840, 488, 1688, 1066 },
  1015. { 211, 72, 1008, 609, 1688, 1066 },
  1016. { 211, 128, 1400, 776, 1688, 1066 },
  1017. { 211, 205, 1680, 1041, 1688, 1066 },
  1018. { 1, 1, 1688, 1066, 1688, 1066 }
  1019. };
  1020. static const SiS_LCDDataStruct SiS_ExtLCD1400x1050Data[] =
  1021. {
  1022. /* { 211, 60, 1260, 410, 1688, 1066 }, 640x400 (6330) */
  1023. { 211, 100, 2100, 408, 1688, 1066 }, /* 640x400 (6325) WORKS */
  1024. { 211, 64, 1536, 358, 1688, 1066 },
  1025. { 211, 100, 2100, 408, 1688, 1066 },
  1026. { 211, 64, 1536, 358, 1688, 1066 },
  1027. /* { 211, 80, 1400, 490, 1688, 1066 }, 640x480 (6330) */
  1028. { 211, 48, 840, 488, 1688, 1066 }, /* 640x480 (6325) WORKS */
  1029. /* { 211, 117, 1638, 613, 1688, 1066 }, 800x600 (6330) */
  1030. { 211, 72, 1008, 609, 1688, 1066 }, /* 800x600 (6325) WORKS */
  1031. { 211, 128, 1400, 776, 1688, 1066 }, /* 1024x768 */
  1032. { 211, 205, 1680, 1041, 1688, 1066 }, /* 1280x1024 - not used (always unscaled) */
  1033. { 1, 1, 1688, 1066, 1688, 1066 }, /* 1400x1050 */
  1034. { 0, 0, 0, 0, 0, 0 }, /* kludge */
  1035. { 211, 120, 1400, 730, 1688, 1066 } /* 1280x720 */
  1036. };
  1037. static const SiS_LCDDataStruct SiS_LCD1680x1050Data[] =
  1038. {
  1039. { 95, 24, 1260, 410, 1900, 1066 }, /* 0 640x400 */
  1040. { 10, 3, 1710, 362, 1900, 1066 },
  1041. { 95, 24, 1260, 410, 1900, 1066 },
  1042. { 10, 3, 1710, 362, 1900, 1066 },
  1043. { 95, 32, 1400, 490, 1900, 1066 }, /* 4 640x480 */
  1044. { 95, 42, 1470, 610, 1900, 1066 }, /* 5 800x600 */
  1045. { 95, 64, 1750, 784, 1900, 1066 }, /* 6 1024x768 */
  1046. { 95, 94, 1900, 1055, 1900, 1066 }, /* 7 1280x1024 */
  1047. { 41, 31, 1900, 806, 1900, 1066 }, /* 8 1280x768 */
  1048. { 95, 69, 1800, 817, 1900, 1066 }, /* 9 1280x800 patch index */
  1049. { 13, 9, 1900, 739, 1900, 1066 }, /* 10 1280x720 */
  1050. { 95, 94, 1880, 1066, 1900, 1066 }, /* 11 1400x1050 patch index */
  1051. { 1, 1, 1900, 1066, 1900, 1066 } /* 12 1680x1050 */
  1052. };
  1053. static const SiS_LCDDataStruct SiS_StLCD1600x1200Data[] =
  1054. {
  1055. {27, 4, 800, 500, 2160, 1250 },
  1056. {27, 4, 800, 500, 2160, 1250 },
  1057. { 6, 1, 900, 500, 2160, 1250 },
  1058. { 6, 1, 900, 500, 2160, 1250 },
  1059. {27, 1, 800, 500, 2160, 1250 },
  1060. { 4, 1,1080, 625, 2160, 1250 },
  1061. { 5, 2,1350, 800, 2160, 1250 },
  1062. {135,88,1600,1100, 2160, 1250 },
  1063. {72, 49,1680,1092, 2160, 1250 },
  1064. { 1, 1,2160,1250, 2160, 1250 }
  1065. };
  1066. static const SiS_LCDDataStruct SiS_ExtLCD1600x1200Data[] =
  1067. {
  1068. {72,11, 990, 422, 2160, 1250 }, /* 640x400 (6330) WORKS */
  1069. /* {27, 4, 800, 500, 2160, 1250 }, 640x400 (6235) */
  1070. {27, 4, 800, 500, 2160, 1250 },
  1071. { 6, 1, 900, 500, 2160, 1250 },
  1072. { 6, 1, 900, 500, 2160, 1250 },
  1073. {45, 8, 960, 505, 2160, 1250 }, /* 640x480 (6330) WORKS */
  1074. /* {27, 1, 800, 500, 2160, 1250 }, 640x480 (6325) */
  1075. { 4, 1,1080, 625, 2160, 1250 },
  1076. { 5, 2,1350, 800, 2160, 1250 },
  1077. {27,16,1500,1064, 2160, 1250 }, /* 1280x1024 */
  1078. {72,49,1680,1092, 2160, 1250 }, /* 1400x1050 (6330, was not supported on 6325) */
  1079. { 1, 1,2160,1250, 2160, 1250 }
  1080. };
  1081. static const SiS_LCDDataStruct SiS_NoScaleData[] =
  1082. {
  1083. { 1, 1, 800, 449, 800, 449 }, /* 0x00: 320x200, 640x400 */
  1084. { 1, 1, 800, 449, 800, 449 },
  1085. { 1, 1, 900, 449, 900, 449 },
  1086. { 1, 1, 900, 449, 900, 449 },
  1087. { 1, 1, 800, 525, 800, 525 }, /* 0x04: 320x240, 640x480 */
  1088. { 1, 1,1056, 628,1056, 628 }, /* 0x05: 400x300, 800x600 */
  1089. { 1, 1,1344, 806,1344, 806 }, /* 0x06: 512x384, 1024x768 */
  1090. { 1, 1,1688,1066,1688,1066 }, /* 0x07: 1280x1024 */
  1091. { 1, 1,1688, 802,1688, 802 }, /* 0x08: 1280x768: Fujitsu, TMDS only */
  1092. { 1, 1,2160,1250,2160,1250 }, /* 0x09: 1600x1200 */
  1093. { 1, 1,1800,1000,1800,1000 }, /* 0x0a: 1280x960 */
  1094. { 1, 1,1688,1066,1688,1066 }, /* 0x0b: 1400x1050 */
  1095. { 1, 1,1650, 750,1650, 750 }, /* 0x0c: 1280x720 (TMDS, projector) */
  1096. { 1, 1,1552, 812,1552, 812 }, /* 0x0d: 1280x800_2 (LVDS) (was: 1408,816/ 1656,841) */
  1097. { 1, 1,1900,1066,1900,1066 }, /* 0x0e: 1680x1050 (LVDS) */
  1098. { 1, 1,1660, 806,1660, 806 }, /* 0x0f: 1280x768_2 (LVDS) */
  1099. { 1, 1,1664, 798,1664, 798 }, /* 0x10: 1280x768_3 (NetVista SiS 301) - TODO */
  1100. { 1, 1,1688, 802,1688, 802 }, /* 0x11: 1280x768 (TMDS Fujitsu) */
  1101. { 1, 1,1408, 806,1408, 806 }, /* 0x12: 1280x720 (LVDS) */
  1102. { 1, 1, 896, 497, 896, 497 }, /* 0x13: 720x480 */
  1103. { 1, 1, 912, 597, 912, 597 }, /* 0x14: 720x576 */
  1104. { 1, 1, 912, 597, 912, 597 }, /* 0x15: 768x576 */
  1105. { 1, 1,1056, 497,1056, 497 }, /* 0x16: 848x480 */
  1106. { 1, 1,1064, 497,1064, 497 }, /* 0x17: 856x480 */
  1107. { 1, 1,1056, 497,1056, 497 }, /* 0x18: 800x480 */
  1108. { 1, 1,1328, 739,1328, 739 }, /* 0x19: 1024x576 */
  1109. { 1, 1,1680, 892,1680, 892 }, /* 0x1a: 1152x864 */
  1110. { 1, 1,1808, 808,1808, 808 }, /* 0x1b: 1360x768 */
  1111. { 1, 1,1104, 563,1104, 563 }, /* 0x1c: 960x540 */
  1112. { 1, 1,1120, 618,1120, 618 }, /* 0x1d: 960x600 */
  1113. { 1, 1,1408, 816,1408, 816 } /* 0x1f: 1280x800 (TMDS special) */
  1114. };
  1115. /**************************************************************/
  1116. /* LVDS ----------------------------------------------------- */
  1117. /**************************************************************/
  1118. static const SiS_LVDSDataStruct SiS_LVDS320x480Data_1[]=
  1119. {
  1120. { 848, 433, 400, 525},
  1121. { 848, 389, 400, 525},
  1122. { 848, 433, 400, 525},
  1123. { 848, 389, 400, 525},
  1124. { 848, 518, 400, 525},
  1125. {1056, 628, 400, 525},
  1126. { 400, 525, 400, 525},
  1127. { 800, 449,1000, 644},
  1128. { 800, 525,1000, 635}
  1129. };
  1130. static const SiS_LVDSDataStruct SiS_LVDS640x480Data_1[]=
  1131. {
  1132. { 800, 445, 800, 525}, /* 800, 449, 800, 449 */
  1133. { 800, 395, 800, 525},
  1134. { 800, 445, 800, 525},
  1135. { 800, 395, 800, 525},
  1136. { 800, 525, 800, 525},
  1137. { 800, 525, 800, 525}, /* pseudo */
  1138. { 800, 525, 800, 525} /* pseudo */
  1139. };
  1140. /* FSTN 320x240 */
  1141. static const SiS_LVDSDataStruct SiS_LVDS640x480Data_2[]=
  1142. {
  1143. { 800, 445, 800, 525},
  1144. { 800, 395, 800, 525},
  1145. { 800, 445, 800, 525},
  1146. { 800, 395, 800, 525},
  1147. { 800, 525, 800, 525},
  1148. { 800, 525, 800, 525}, /* pseudo */
  1149. { 800, 525, 800, 525} /* pseudo */
  1150. };
  1151. static const SiS_LVDSDataStruct SiS_LVDS800x600Data_1[]=
  1152. {
  1153. { 848, 433,1060, 629},
  1154. { 848, 389,1060, 629},
  1155. { 848, 433,1060, 629},
  1156. { 848, 389,1060, 629},
  1157. { 848, 518,1060, 629},
  1158. {1056, 628,1056, 628},
  1159. {1056, 628,1056, 628}
  1160. };
  1161. static const SiS_LVDSDataStruct SiS_LVDS800x600Data_2[]=
  1162. {
  1163. {1056, 628,1056, 628}
  1164. };
  1165. static const SiS_LVDSDataStruct SiS_LVDS1024x768Data_1[]=
  1166. {
  1167. { 840, 438,1344, 806},
  1168. { 840, 409,1344, 806},
  1169. { 840, 438,1344, 806},
  1170. { 840, 409,1344, 806},
  1171. { 840, 518,1344, 806}, /* 640x480 */
  1172. {1050, 638,1344, 806}, /* 800x600 */
  1173. {1344, 806,1344, 806}, /* 1024x768 */
  1174. };
  1175. static const SiS_LVDSDataStruct SiS_LVDS1024x768Data_2[]=
  1176. {
  1177. {1344, 806,1344, 806}
  1178. };
  1179. static const SiS_LVDSDataStruct SiS_LVDS1280x1024Data_1[]=
  1180. {
  1181. {1048, 442,1688,1066},
  1182. {1048, 392,1688,1066},
  1183. {1048, 442,1688,1066},
  1184. {1048, 392,1688,1066},
  1185. {1048, 522,1688,1066},
  1186. {1208, 642,1688,1066},
  1187. {1432, 810,1688,1066},
  1188. {1688,1066,1688,1066}
  1189. };
  1190. static const SiS_LVDSDataStruct SiS_LVDS1280x1024Data_2[]=
  1191. {
  1192. {1688,1066,1688,1066}
  1193. };
  1194. static const SiS_LVDSDataStruct SiS_LVDS1400x1050Data_1[]=
  1195. {
  1196. { 928, 416, 1688,1066},
  1197. { 928, 366, 1688,1066},
  1198. { 928, 416, 1688,1066},
  1199. { 928, 366, 1688,1066},
  1200. { 928, 496, 1688,1066},
  1201. {1088, 616, 1688,1066},
  1202. {1312, 784, 1688,1066},
  1203. {1568,1040, 1688,1066},
  1204. {1688,1066, 1688,1066}
  1205. };
  1206. static const SiS_LVDSDataStruct SiS_LVDS1400x1050Data_2[]=
  1207. {
  1208. {1688,1066, 1688,1066}
  1209. };
  1210. static const SiS_LVDSDataStruct SiS_LVDS1600x1200Data_1[]=
  1211. {
  1212. {1088, 520, 2048,1320},
  1213. {1088, 470, 2048,1320},
  1214. {1088, 520, 2048,1320},
  1215. {1088, 470, 2048,1320},
  1216. {1088, 600, 2048,1320},
  1217. {1248, 720, 2048,1320},
  1218. {1472, 888, 2048,1320},
  1219. {1728,1144, 2048,1320},
  1220. {1848,1170, 2048,1320},
  1221. {2048,1320, 2048,1320}
  1222. };
  1223. static const SiS_LVDSDataStruct SiS_LVDS1600x1200Data_2[]=
  1224. {
  1225. {2048,1320, 2048,1320}
  1226. };
  1227. static const SiS_LVDSDataStruct SiS_LVDS1280x960Data_1[]=
  1228. {
  1229. { 840, 438,1344, 806},
  1230. { 840, 409,1344, 806},
  1231. { 840, 438,1344, 806},
  1232. { 840, 409,1344, 806},
  1233. { 840, 518,1344, 806},
  1234. {1050, 638,1344, 806},
  1235. {1344, 806,1344, 806},
  1236. { 800, 449,1280, 801},
  1237. { 800, 525,1280, 813}
  1238. };
  1239. static const SiS_LVDSDataStruct SiS_LVDS1280x960Data_2[]=
  1240. {
  1241. {1344, 806,1344, 806}
  1242. };
  1243. static const SiS_LVDSDataStruct SiS_LVDS1280x768Data_1[]=
  1244. {
  1245. { 768, 438, 1408, 806},
  1246. { 768, 388, 1408, 806},
  1247. { 768, 438, 1408, 806},
  1248. { 768, 388, 1408, 806},
  1249. { 768, 518, 1408, 806},
  1250. { 928, 638, 1408, 806},
  1251. {1152, 806, 1408, 806},
  1252. {1408, 806, 1408, 806},
  1253. {1408, 806, 1408, 806}
  1254. };
  1255. static const SiS_LVDSDataStruct SiS_LVDS1280x768Data_2[]=
  1256. {
  1257. {1408, 806, 1408, 806}
  1258. };
  1259. static const SiS_LVDSDataStruct SiS_LVDS1024x600Data_1[] =
  1260. {
  1261. { 840, 604,1344, 800},
  1262. { 840, 560,1344, 800},
  1263. { 840, 604,1344, 800},
  1264. { 840, 560,1344, 800},
  1265. { 840, 689,1344, 800},
  1266. {1050, 800,1344, 800},
  1267. {1344, 800,1344, 800}
  1268. };
  1269. static const SiS_LVDSDataStruct SiS_LVDS1024x600Data_2[] =
  1270. {
  1271. {1344, 800,1344, 800}
  1272. };
  1273. static const SiS_LVDSDataStruct SiS_LVDS1152x768Data_1[] =
  1274. {
  1275. { 840, 438,1344, 806},
  1276. { 840, 409,1344, 806},
  1277. { 840, 438,1344, 806},
  1278. { 840, 409,1344, 806},
  1279. { 840, 518,1344, 806},
  1280. {1050, 638,1344, 806},
  1281. {1344, 806,1344, 806}
  1282. };
  1283. static const SiS_LVDSDataStruct SiS_LVDS1152x768Data_2[] =
  1284. {
  1285. {1344, 806,1344, 806}
  1286. };
  1287. /* Pass 1:1 data */
  1288. static const SiS_LVDSDataStruct SiS_LVDSXXXxXXXData_1[]=
  1289. {
  1290. { 800, 449, 800, 449},
  1291. { 800, 449, 800, 449},
  1292. { 900, 449, 900, 449},
  1293. { 900, 449, 900, 449},
  1294. { 800, 525, 800, 525}, /* 640x480 */
  1295. {1056, 628, 1056, 628}, /* 800x600 */
  1296. {1344, 806, 1344, 806}, /* 1024x768 */
  1297. {1688,1066, 1688,1066}, /* 1280x1024 */ /* INSERTED */
  1298. {1688, 806, 1688, 806}, /* 1280x768 */
  1299. };
  1300. /* Custom data for Barco iQ R series */
  1301. static const SiS_LVDSDataStruct SiS_LVDSBARCO1366Data_1[]=
  1302. {
  1303. { 832, 438,1331, 806},
  1304. { 832, 388,1331, 806},
  1305. { 832, 438,1331, 806},
  1306. { 832, 388,1331, 806},
  1307. { 832, 518,1331, 806},
  1308. {1050, 638,1344, 806},
  1309. {1344, 806,1344, 806},
  1310. {1688,1066,1688,1066},
  1311. {1688,1066,1688,1066} /* 1360x1024 */
  1312. };
  1313. /* Custom data for Barco iQ R series */
  1314. static const SiS_LVDSDataStruct SiS_LVDSBARCO1366Data_2[]=
  1315. {
  1316. {1344, 806,1344, 806},
  1317. {1344, 806,1344, 806},
  1318. {1344, 806,1344, 806},
  1319. {1344, 806,1344, 806},
  1320. {1344, 806,1344, 806},
  1321. {1344, 806,1344, 806},
  1322. {1344, 806,1344, 806},
  1323. {1688,1066,1688,1066},
  1324. {1688,1066,1688,1066} /* 1360x1024 */
  1325. };
  1326. /* Custom data for Barco iQ G series */
  1327. static const SiS_LVDSDataStruct SiS_LVDSBARCO1024Data_1[]=
  1328. {
  1329. { 832, 438,1331, 806},
  1330. { 832, 409,1331, 806},
  1331. { 832, 438,1331, 806},
  1332. { 832, 409,1331, 806},
  1333. { 832, 518,1331, 806}, /* 640x480 */
  1334. {1050, 638,1344, 806}, /* 800x600 */
  1335. {1344, 806,1344, 806}, /* 1024x768 */
  1336. };
  1337. /* Custom data for Barco iQ G series */
  1338. static const SiS_LVDSDataStruct SiS_LVDSBARCO1024Data_2[]=
  1339. {
  1340. {1344, 806,1344, 806}
  1341. };
  1342. /* Custom data for 848x480 parallel panel */
  1343. static const SiS_LVDSDataStruct SiS_LVDS848x480Data_1[]=
  1344. {
  1345. { 0, 0, 0, 0},
  1346. { 0, 0, 0, 0},
  1347. { 0, 0, 0, 0},
  1348. { 0, 0, 0, 0},
  1349. {1088, 525,1088, 525}, /* 640x480 TODO */
  1350. {1088, 525,1088, 525}, /* 800x600 TODO */
  1351. {1088, 525,1088, 525}, /* 1024x768 TODO */
  1352. { 0, 0, 0, 0},
  1353. { 0, 0, 0, 0},
  1354. { 0, 0, 0, 0},
  1355. { 0, 0, 0, 0},
  1356. {1088, 525,1088, 525}, /* 848x480 */
  1357. {1088, 525,1088, 525} /* 1360x768 TODO */
  1358. };
  1359. /* Custom data for 848x480 parallel panel */
  1360. static const SiS_LVDSDataStruct SiS_LVDS848x480Data_2[]=
  1361. {
  1362. { 0, 0, 0, 0},
  1363. { 0, 0, 0, 0},
  1364. { 0, 0, 0, 0},
  1365. { 0, 0, 0, 0},
  1366. {1088, 525,1088, 525}, /* 640x480 */
  1367. {1088, 525,1088, 525}, /* 800x600 */
  1368. {1088, 525,1088, 525}, /* 1024x768 */
  1369. { 0, 0, 0, 0},
  1370. { 0, 0, 0, 0},
  1371. { 0, 0, 0, 0},
  1372. { 0, 0, 0, 0},
  1373. {1088, 525,1088, 525}, /* 848x480 */
  1374. {1088, 525,1088, 525} /* 1360x768 TODO */
  1375. };
  1376. static const SiS_LVDSDataStruct SiS_CHTVUNTSCData[]=
  1377. {
  1378. { 840, 600, 840, 600},
  1379. { 840, 600, 840, 600},
  1380. { 840, 600, 840, 600},
  1381. { 840, 600, 840, 600},
  1382. { 784, 600, 784, 600},
  1383. {1064, 750,1064, 750},
  1384. {1160, 945,1160, 945}
  1385. };
  1386. static const SiS_LVDSDataStruct SiS_CHTVONTSCData[]=
  1387. {
  1388. { 840, 525, 840, 525},
  1389. { 840, 525, 840, 525},
  1390. { 840, 525, 840, 525},
  1391. { 840, 525, 840, 525},
  1392. { 784, 525, 784, 525},
  1393. {1040, 700,1040, 700},
  1394. {1160, 840,1160, 840}
  1395. };
  1396. /* Chrontel TV Skew */
  1397. static const SiS_LVDSDesStruct SiS_CHTVUNTSCDesData[]=
  1398. {
  1399. { 0, 0},
  1400. { 0, 0},
  1401. { 0, 0},
  1402. { 0, 0},
  1403. { 0, 0},
  1404. { 0, 0},
  1405. { 0, 0}
  1406. };
  1407. static const SiS_LVDSDesStruct SiS_CHTVONTSCDesData[]=
  1408. {
  1409. { 0, 0},
  1410. { 0, 0},
  1411. { 0, 0},
  1412. { 0, 0},
  1413. { 0, 0},
  1414. { 0, 0},
  1415. { 0, 0}
  1416. };
  1417. static const SiS_LVDSDesStruct SiS_CHTVUPALDesData[]=
  1418. {
  1419. {256, 0},
  1420. {256, 0},
  1421. {256, 0},
  1422. {256, 0},
  1423. { 0, 0},
  1424. { 0, 0},
  1425. { 0, 0}
  1426. };
  1427. static const SiS_LVDSDesStruct SiS_CHTVOPALDesData[]=
  1428. {
  1429. {256, 0},
  1430. {256, 0},
  1431. {256, 0},
  1432. {256, 0},
  1433. { 0, 0},
  1434. { 0, 0},
  1435. { 0, 0}
  1436. };
  1437. /* CRT1 CRTC data for slave modes */
  1438. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT1320x480_1[] =
  1439. {
  1440. {{0x65,0x4f,0x89,0x56,0x83,0xaa,0x1f,
  1441. 0x90,0x85,0x8f,0xab,0x30,0x00,0x05,
  1442. 0x00 }},
  1443. {{0x65,0x4f,0x89,0x56,0x83,0x83,0x1f,
  1444. 0x5e,0x83,0x5d,0x79,0x10,0x00,0x05,
  1445. 0x00 }},
  1446. {{0x65,0x4f,0x89,0x54,0x9f,0xc4,0x1f,
  1447. 0x92,0x89,0x8f,0xb5,0x30,0x00,0x01,
  1448. 0x00 }},
  1449. {{0x65,0x4f,0x89,0x56,0x83,0x83,0x1f,
  1450. 0x5e,0x83,0x5d,0x79,0x10,0x00,0x05,
  1451. 0x00 }},
  1452. {{0x65,0x4f,0x89,0x56,0x83,0x04,0x3e,
  1453. 0xe0,0x85,0xdf,0xfb,0x10,0x00,0x05,
  1454. 0x00 }},
  1455. {{0x7f,0x63,0x83,0x6c,0x1c,0x72,0xf0,
  1456. 0x58,0x8c,0x57,0x73,0x20,0x00,0x06,
  1457. 0x01 }},
  1458. {{0x2d,0x27,0x90,0x2c,0x80,0x0b,0x3e,
  1459. 0xe9,0x8b,0xe7,0x04,0x00,0x00,0x00,
  1460. 0x00 }}
  1461. };
  1462. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT1640x480_1[] =
  1463. {
  1464. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1465. 0xe9,0x8b,0xdf,0x04,0x30,0x00,0x05,
  1466. 0x00}},
  1467. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1468. 0xe9,0x8b,0xdf,0x04,0x30,0x00,0x05,
  1469. 0x00}},
  1470. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1471. 0xe9,0x8b,0xdf,0x04,0x30,0x00,0x05,
  1472. 0x00}},
  1473. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1474. 0xe9,0x8b,0xdf,0x04,0x30,0x00,0x05,
  1475. 0x00}},
  1476. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1477. 0xe9,0x8b,0xdf,0x04,0x30,0x00,0x05,
  1478. 0x00}},
  1479. {{0x7f,0x63,0x83,0x6c,0x1c,0x72,0xf0,
  1480. 0x58,0x8c,0x57,0x73,0x20,0x00,0x06,
  1481. 0x01}}
  1482. };
  1483. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT1640x480_1_H[] =
  1484. {
  1485. {{0x2d,0x28,0x90,0x2b,0xa0,0xbf,0x1f,
  1486. 0x9c,0x8e,0x96,0xb9,0x00,0x00,0x00,
  1487. 0x00}},
  1488. {{0x2d,0x28,0x90,0x2b,0xa0,0xbf,0x1f,
  1489. 0x83,0x85,0x63,0xba,0x00,0x00,0x00,
  1490. 0x00}},
  1491. {{0x2d,0x28,0x90,0x2b,0xa0,0xbf,0x1f,
  1492. 0x9c,0x8e,0x96,0xb9,0x00,0x00,0x00,
  1493. 0x00}},
  1494. {{0x2d,0x28,0x90,0x2b,0xa0,0xbf,0x1f,
  1495. 0x83,0x85,0x63,0xba,0x00,0x00,0x00,
  1496. 0x00}},
  1497. {{0x2d,0x28,0x90,0x2c,0x80,0x0b,0x3e,
  1498. 0xe9,0x8b,0xe7,0x04,0x00,0x00,0x00,
  1499. 0x00}}
  1500. };
  1501. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT1640x480_2[] =
  1502. {
  1503. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1504. 0xe9,0x8b,0xdf,0x04,0x30,0x00,0x05,
  1505. 0x00}},
  1506. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1507. 0xe9,0x8b,0xdf,0x04,0x30,0x00,0x05,
  1508. 0x00}},
  1509. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1510. 0xe9,0x8b,0xdf,0x04,0x30,0x00,0x05,
  1511. 0x00}},
  1512. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1513. 0xe9,0x8b,0xdf,0x04,0x30,0x00,0x05,
  1514. 0x00}},
  1515. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1516. 0xe9,0x8b,0xdf,0x04,0x30,0x00,0x05,
  1517. 0x00}},
  1518. {{0x7f,0x63,0x83,0x6c,0x1c,0x72,0xf0,
  1519. 0x58,0x8c,0x57,0x73,0x20,0x00,0x06,
  1520. 0x01}},
  1521. {{0x2d,0x27,0x90,0x2c,0x80,0x0b,0x3e,
  1522. 0xe9,0x8b,0xe7,0x04,0x00,0x00,0x00,
  1523. 0x00}}
  1524. };
  1525. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT1640x480_2_H[] =
  1526. {
  1527. {{0x65,0x4f,0x89,0x56,0x83,0xaa,0x1f,
  1528. 0x90,0x85,0x8f,0xab,0x30,0x00,0x05,
  1529. 0x00}},
  1530. {{0x65,0x4f,0x89,0x56,0x83,0x83,0x1f,
  1531. 0x5e,0x83,0x5d,0x79,0x10,0x00,0x05,
  1532. 0x00}},
  1533. {{0x65,0x4f,0x89,0x54,0x9f,0xc4,0x1f,
  1534. 0x92,0x89,0x8f,0xb5,0x30,0x00,0x01,
  1535. 0x00}},
  1536. {{0x65,0x4f,0x89,0x56,0x83,0x83,0x1f,
  1537. 0x5e,0x83,0x5d,0x79,0x10,0x00,0x05,
  1538. 0x00}},
  1539. {{0x65,0x4f,0x89,0x56,0x83,0x04,0x3e,
  1540. 0xe0,0x85,0xdf,0xfb,0x10,0x00,0x05,
  1541. 0x00}},
  1542. {{0x7f,0x63,0x83,0x6c,0x1c,0x72,0xf0,
  1543. 0x58,0x8c,0x57,0x73,0x20,0x00,0x06,
  1544. 0x01}},
  1545. {{0x2d,0x27,0x90,0x2c,0x80,0x0b,0x3e,
  1546. 0xe9,0x8b,0xe7,0x04,0x00,0x00,0x00,
  1547. 0x00}}
  1548. };
  1549. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT1640x480_3[] =
  1550. {
  1551. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1552. 0xe9,0x8b,0xdf,0x04,0x00,0x00,0x05,
  1553. 0x00}},
  1554. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1555. 0xe9,0x8b,0xdf,0x04,0x00,0x00,0x05,
  1556. 0x00}},
  1557. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1558. 0xe9,0x8b,0xdf,0x04,0x00,0x00,0x05,
  1559. 0x00}},
  1560. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1561. 0xe9,0x8b,0xdf,0x04,0x00,0x00,0x05,
  1562. 0x00}},
  1563. {{0x5f,0x4f,0x82,0x55,0x81,0x0b,0x3e,
  1564. 0xe9,0x8b,0xdf,0x04,0x00,0x00,0x05,
  1565. 0x00}},
  1566. {{0x7f,0x63,0x83,0x6c,0x1c,0x72,0xf0,
  1567. 0x58,0x8c,0x57,0x73,0x20,0x00,0x06,
  1568. 0x01}},
  1569. {{0x2d,0x27,0x90,0x2c,0x80,0x0b,0x3e,
  1570. 0xe9,0x8b,0xe7,0x04,0x00,0x00,0x00,
  1571. 0x00}}
  1572. };
  1573. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT1640x480_3_H[] =
  1574. {
  1575. {{0x65,0x4f,0x89,0x56,0x83,0xaa,0x1f,
  1576. 0x90,0x85,0x8f,0xab,0x30,0x00,0x05,
  1577. 0x00}},
  1578. {{0x65,0x4f,0x89,0x56,0x83,0x83,0x1f,
  1579. 0x5e,0x83,0x5d,0x79,0x10,0x00,0x05,
  1580. 0x00}},
  1581. {{0x65,0x4f,0x89,0x54,0x9f,0xc4,0x1f,
  1582. 0x92,0x89,0x8f,0xb5,0x30,0x00,0x01,
  1583. 0x00}},
  1584. {{0x65,0x4f,0x89,0x56,0x83,0x83,0x1f,
  1585. 0x5e,0x83,0x5d,0x79,0x10,0x00,0x05,
  1586. 0x00}},
  1587. {{0x65,0x4f,0x89,0x56,0x83,0x04,0x3e,
  1588. 0xe0,0x85,0xdf,0xfb,0x10,0x00,0x05,
  1589. 0x00}},
  1590. {{0x7f,0x63,0x83,0x6c,0x1c,0x72,0xf0,
  1591. 0x58,0x8c,0x57,0x73,0x20,0x00,0x06,
  1592. 0x01}},
  1593. {{0x2d,0x27,0x90,0x2c,0x80,0x0b,0x3e,
  1594. 0xe9,0x8b,0xe7,0x04,0x00,0x00,0x00,
  1595. 0x00}}
  1596. };
  1597. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11024x600_1[] =
  1598. {
  1599. {{0x64,0x4f,0x88,0x54,0x9f,0x5a,0x3e,
  1600. 0xe8,0x8f,0x8f,0x5b,0x00,0x00,0x01,
  1601. 0x00}},
  1602. {{0x64,0x4f,0x88,0x54,0x9f,0x2e,0x3e,
  1603. 0xb9,0x80,0x5d,0x2f,0x00,0x00,0x01,
  1604. 0x00}},
  1605. {{0x64,0x4f,0x88,0x54,0x9f,0x5a,0x3e,
  1606. 0xe8,0x8f,0x8f,0x5b,0x00,0x00,0x01,
  1607. 0x00}},
  1608. {{0x64,0x4f,0x88,0x54,0x9f,0x2e,0x3e,
  1609. 0xb9,0x80,0x5d,0x2f,0x00,0x00,0x01,
  1610. 0x00}},
  1611. {{0x64,0x4f,0x88,0x54,0x9f,0xaf,0xba,
  1612. 0x3b,0x82,0xdf,0xb0,0x00,0x00,0x01,
  1613. 0x00}},
  1614. {{0x7e,0x63,0x82,0x68,0x15,0x1e,0xf1,
  1615. 0xae,0x85,0x57,0x1f,0x30,0x00,0x26,
  1616. 0x01}},
  1617. {{0xa3,0x7f,0x87,0x86,0x97,0x1e,0xf1,
  1618. 0xae,0x85,0x57,0x1f,0x30,0x00,0x02,
  1619. 0x01}}
  1620. };
  1621. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11024x600_1_H[] =
  1622. {
  1623. {{0x2f,0x27,0x93,0x2b,0x90,0xc4,0x1f,
  1624. 0x92,0x89,0x8f,0xb5,0x30,0x00,0x44,
  1625. 0x00}},
  1626. {{0x2f,0x27,0x93,0x2b,0x90,0x97,0x1f,
  1627. 0x60,0x87,0x5d,0x83,0x10,0x00,0x44,
  1628. 0x00}},
  1629. {{0x2f,0x27,0x93,0x2b,0x90,0xc4,0x1f,
  1630. 0x92,0x89,0x8f,0xb5,0x30,0x00,0x44,
  1631. 0x00}},
  1632. {{0x2f,0x27,0x93,0x2b,0x90,0x97,0x1f,
  1633. 0x60,0x87,0x5d,0x83,0x10,0x00,0x44,
  1634. 0x00}},
  1635. {{0x2f,0x27,0x93,0x2b,0x90,0x04,0x3e,
  1636. 0xe2,0x89,0xdf,0x05,0x00,0x00,0x44,
  1637. 0x00}},
  1638. {{0x3c,0x31,0x80,0x35,0x1c,0x7c,0xf0,
  1639. 0x5a,0x8f,0x57,0x7d,0x20,0x00,0x55,
  1640. 0x01}},
  1641. {{0x4f,0x3f,0x93,0x45,0x0d,0x24,0xf5,
  1642. 0x02,0x88,0xff,0x25,0x10,0x00,0x01,
  1643. 0x01}}
  1644. };
  1645. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11024x600_2[] =
  1646. {
  1647. {{0xa3,0x4f,0x87,0x6e,0x9f,0x24,0xbb,
  1648. 0x4a,0x80,0x8f,0x25,0x30,0x00,0x06,
  1649. 0x00}},
  1650. {{0xa3,0x4f,0x87,0x6e,0x9f,0x24,0xbb,
  1651. 0x31,0x87,0x5d,0x25,0x30,0x00,0x06,
  1652. 0x00}},
  1653. {{0xa3,0x4f,0x87,0x6e,0x9f,0x24,0xbb,
  1654. 0x4a,0x80,0x8f,0x25,0x30,0x00,0x06,
  1655. 0x00}},
  1656. {{0xa3,0x4f,0x87,0x6e,0x9f,0x24,0xbb,
  1657. 0x31,0x87,0x5d,0x25,0x30,0x00,0x06,
  1658. 0x00}},
  1659. {{0xa3,0x4f,0x87,0x6e,0x9f,0x24,0xbb,
  1660. 0x72,0x88,0xdf,0x25,0x30,0x00,0x06,
  1661. 0x00}},
  1662. {{0xa3,0x63,0x87,0x78,0x89,0x24,0xf1,
  1663. 0xae,0x84,0x57,0x25,0x30,0x00,0x02,
  1664. 0x01}},
  1665. {{0xa3,0x7f,0x87,0x86,0x97,0x24,0xf5,
  1666. 0x02,0x88,0xff,0x25,0x10,0x00,0x02,
  1667. 0x01}}
  1668. };
  1669. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11024x600_2_H[] =
  1670. {
  1671. {{0x4f,0x27,0x93,0x39,0x01,0x24,0xbb,
  1672. 0x4a,0x80,0x8f,0x25,0x30,0x00,0x01,
  1673. 0x00}},
  1674. {{0x4f,0x27,0x93,0x39,0x01,0x24,0xbb,
  1675. 0x31,0x87,0x5d,0x25,0x30,0x00,0x01,
  1676. 0x00}},
  1677. {{0x4f,0x27,0x93,0x39,0x01,0x24,0xbb,
  1678. 0x4a,0x80,0x8f,0x25,0x30,0x00,0x01,
  1679. 0x00}},
  1680. {{0x4f,0x27,0x93,0x39,0x01,0x24,0xbb,
  1681. 0x31,0x87,0x5d,0x25,0x30,0x00,0x01,
  1682. 0x00}},
  1683. {{0x4f,0x27,0x93,0x39,0x01,0x24,0xbb,
  1684. 0x72,0x88,0xdf,0x25,0x30,0x00,0x01,
  1685. 0x00}},
  1686. {{0x4f,0x31,0x93,0x3e,0x06,0x24,0xf1,
  1687. 0xae,0x84,0x57,0x25,0x30,0x00,0x01,
  1688. 0x01}},
  1689. {{0x4f,0x3f,0x93,0x45,0x0d,0x24,0xf5,
  1690. 0x02,0x88,0xff,0x25,0x10,0x00,0x01,
  1691. 0x01}}
  1692. };
  1693. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11152x768_1[] =
  1694. {
  1695. {{0x64,0x4f,0x88,0x54,0x9f,0xc4,0x1f,
  1696. 0x92,0x89,0x8f,0xb5,0x30,0x00,0x01,
  1697. 0x00}},
  1698. {{0x64,0x4f,0x88,0x54,0x9f,0x97,0x1f,
  1699. 0x60,0x87,0x5d,0x83,0x10,0x00,0x01,
  1700. 0x00}},
  1701. {{0x64,0x4f,0x88,0x54,0x9f,0xc4,0x1f,
  1702. 0x92,0x89,0x8f,0xb5,0x30,0x00,0x01,
  1703. 0x00}},
  1704. {{0x64,0x4f,0x88,0x54,0x9f,0x97,0x1f,
  1705. 0x60,0x87,0x5d,0x83,0x10,0x00,0x01,
  1706. 0x00}},
  1707. {{0x64,0x4f,0x88,0x54,0x9f,0x04,0x3e,
  1708. 0xe2,0x89,0xdf,0x05,0x00,0x00,0x01,
  1709. 0x00}},
  1710. {{0x7e,0x63,0x82,0x68,0x15,0x7c,0xf0,
  1711. 0x5a,0x8f,0x57,0x7d,0x20,0x00,0x26,
  1712. 0x01}},
  1713. {{0xa3,0x7f,0x87,0x86,0x97,0x24,0xf5,
  1714. 0x02,0x88,0xff,0x25,0x10,0x00,0x02,
  1715. 0x01}}
  1716. };
  1717. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11152x768_1_H[] =
  1718. {
  1719. {{0x2f,0x27,0x93,0x2b,0x90,0xc4,0x1f,
  1720. 0x92,0x89,0x8f,0xb5,0x30,0x00,0x44,
  1721. 0x00}},
  1722. {{0x2f,0x27,0x93,0x2b,0x90,0x97,0x1f,
  1723. 0x60,0x87,0x5d,0x83,0x10,0x00,0x44,
  1724. 0x00}},
  1725. {{0x2f,0x27,0x93,0x2b,0x90,0xc4,0x1f,
  1726. 0x92,0x89,0x8f,0xb5,0x30,0x00,0x44,
  1727. 0x00}},
  1728. {{0x2f,0x27,0x93,0x2b,0x90,0x97,0x1f,
  1729. 0x60,0x87,0x5d,0x83,0x10,0x00,0x44,
  1730. 0x00}},
  1731. {{0x2f,0x27,0x93,0x2b,0x90,0x04,0x3e,
  1732. 0xe2,0x89,0xdf,0x05,0x00,0x00,0x44,
  1733. 0x00}},
  1734. {{0x3c,0x31,0x80,0x35,0x1c,0x7c,0xf0,
  1735. 0x5a,0x8f,0x57,0x7d,0x20,0x00,0x55,
  1736. 0x01}},
  1737. {{0x4f,0x3f,0x93,0x45,0x0d,0x24,0xf5,
  1738. 0x02,0x88,0xff,0x25,0x10,0x00,0x01,
  1739. 0x01}}
  1740. };
  1741. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11152x768_2[] =
  1742. {
  1743. {{0xa3,0x4f,0x87,0x6e,0x9f,0x24,0xbb,
  1744. 0x4a,0x80,0x8f,0x25,0x30,0x00,0x06,
  1745. 0x00}},
  1746. {{0xa3,0x4f,0x87,0x6e,0x9f,0x24,0xbb,
  1747. 0x31,0x87,0x5d,0x25,0x30,0x00,0x06,
  1748. 0x00}},
  1749. {{0xa3,0x4f,0x87,0x6e,0x9f,0x24,0xbb,
  1750. 0x4a,0x80,0x8f,0x25,0x30,0x00,0x06,
  1751. 0x00}},
  1752. {{0xa3,0x4f,0x87,0x6e,0x9f,0x24,0xbb,
  1753. 0x31,0x87,0x5d,0x25,0x30,0x00,0x06,
  1754. 0x00}},
  1755. {{0xa3,0x4f,0x87,0x6e,0x9f,0x24,0xbb,
  1756. 0x72,0x88,0xdf,0x25,0x30,0x00,0x06,
  1757. 0x00}},
  1758. {{0xa3,0x63,0x87,0x78,0x89,0x24,0xf1,
  1759. 0xae,0x84,0x57,0x25,0x30,0x00,0x02,
  1760. 0x01}},
  1761. {{0xa3,0x7f,0x87,0x86,0x97,0x24,0xf5,
  1762. 0x02,0x88,0xff,0x25,0x10,0x00,0x02,
  1763. 0x01}}
  1764. };
  1765. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11152x768_2_H[] =
  1766. {
  1767. {{0x4f,0x27,0x93,0x39,0x01,0x24,0xbb,
  1768. 0x4a,0x80,0x8f,0x25,0x30,0x00,0x01,
  1769. 0x00}},
  1770. {{0x4f,0x27,0x93,0x39,0x01,0x24,0xbb,
  1771. 0x31,0x87,0x5d,0x25,0x30,0x00,0x01,
  1772. 0x00}},
  1773. {{0x4f,0x27,0x93,0x39,0x01,0x24,0xbb,
  1774. 0x4a,0x80,0x8f,0x25,0x30,0x00,0x01,
  1775. 0x00}},
  1776. {{0x4f,0x27,0x93,0x39,0x01,0x24,0xbb,
  1777. 0x31,0x87,0x5d,0x25,0x30,0x00,0x01,
  1778. 0x00}},
  1779. {{0x4f,0x27,0x93,0x39,0x01,0x24,0xbb,
  1780. 0x72,0x88,0xdf,0x25,0x30,0x00,0x01,
  1781. 0x00}},
  1782. {{0x4f,0x31,0x93,0x3e,0x06,0x24,0xf1,
  1783. 0xae,0x84,0x57,0x25,0x30,0x00,0x01,
  1784. 0x01}},
  1785. {{0x4f,0x3f,0x93,0x45,0x0d,0x24,0xf5,
  1786. 0x02,0x88,0xff,0x25,0x10,0x00,0x01,
  1787. 0x01}}
  1788. };
  1789. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11280x768_1[] =
  1790. {
  1791. {{0x5b,0x4f,0x9f,0x55,0x19,0xb4,0x1f,
  1792. 0x9c,0x8e,0x8f,0xb5,0x10,0x00,0x01,
  1793. 0x00}},
  1794. {{0x5b,0x4f,0x9f,0x55,0x19,0x82,0x1f,
  1795. 0x6a,0x8c,0x5d,0x83,0x30,0x00,0x01,
  1796. 0x00}},
  1797. {{0x5b,0x4f,0x9f,0x55,0x19,0xb4,0x1f,
  1798. 0x9c,0x8e,0x8f,0xb5,0x10,0x00,0x01,
  1799. 0x00}},
  1800. {{0x5b,0x4f,0x9f,0x55,0x19,0x82,0x1f,
  1801. 0x6a,0x8c,0x5d,0x83,0x30,0x00,0x01,
  1802. 0x00}},
  1803. {{0x5b,0x4f,0x9f,0x55,0x19,0x04,0x3e,
  1804. 0xec,0x8e,0xdf,0x05,0x20,0x00,0x01,
  1805. 0x00}},
  1806. {{0x6f,0x63,0x93,0x69,0x8d,0x7c,0xf0,
  1807. 0x64,0x86,0x57,0x7d,0x20,0x00,0x05,
  1808. 0x01}},
  1809. {{0x8b,0x7f,0x8f,0x85,0x09,0x24,0xf5,
  1810. 0x0c,0x8e,0xff,0x25,0x30,0x00,0x02,
  1811. 0x01}},
  1812. {{0xab,0x9f,0x8f,0xa5,0x89,0x24,0xf5,
  1813. 0x0c,0x8e,0xff,0x25,0x30,0x00,0x06,
  1814. 0x01}},
  1815. {{0xab,0x9f,0x8f,0xa5,0x89,0x24,0xf5,
  1816. 0x0c,0x8e,0xff,0x25,0x30,0x00,0x06,
  1817. 0x01}}
  1818. };
  1819. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11280x768_1_H[] =
  1820. {
  1821. {{0x47,0x27,0x8b,0x2c,0x1a,0x9e,0x1f,
  1822. 0x93,0x86,0x8f,0x9f,0x30,0x00,0x05,
  1823. 0x00}},
  1824. {{0x47,0x27,0x8b,0x2c,0x1a,0x6c,0x1f,
  1825. 0x60,0x84,0x5d,0x6d,0x10,0x00,0x05,
  1826. 0x00}},
  1827. {{0x47,0x27,0x8b,0x30,0x1e,0x9e,0x1f,
  1828. 0x92,0x86,0x8f,0x9f,0x30,0x00,0x05,
  1829. 0x00}},
  1830. {{0x47,0x27,0x8b,0x2c,0x1a,0x6c,0x1f,
  1831. 0x60,0x84,0x5d,0x6d,0x10,0x00,0x05,
  1832. 0x00}},
  1833. {{0x47,0x27,0x8b,0x2c,0x1a,0xee,0x1f,
  1834. 0xe2,0x86,0xdf,0xef,0x10,0x00,0x05,
  1835. 0x00}},
  1836. {{0x51,0x31,0x95,0x36,0x04,0x66,0xf0,
  1837. 0x5a,0x8e,0x57,0x67,0x20,0x00,0x01,
  1838. 0x01}},
  1839. {{0x5f,0x3f,0x83,0x44,0x92,0x0e,0xf5,
  1840. 0x02,0x86,0xff,0x0f,0x10,0x00,0x01,
  1841. 0x01}},
  1842. {{0x6f,0x4f,0x93,0x54,0x82,0x0e,0x5a,
  1843. 0x02,0x86,0xff,0x0f,0x09,0x00,0x05,
  1844. 0x01}},
  1845. {{0x6f,0x4f,0x93,0x54,0x82,0x0e,0x5a,
  1846. 0x02,0x86,0xff,0x0f,0x09,0x00,0x05,
  1847. 0x01}}
  1848. };
  1849. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11280x768_2[] =
  1850. {
  1851. {{0xab,0x60,0x9f,0x80,0x04,0x24,0xbb,
  1852. 0x54,0x86,0xdb,0xda,0x00,0x00,0x02,
  1853. 0x00}},
  1854. {{0xab,0x60,0x9f,0x80,0x04,0x24,0xbb,
  1855. 0x3b,0x8d,0xc2,0xc1,0x00,0x00,0x02,
  1856. 0x00}},
  1857. {{0xab,0x60,0x9f,0x80,0x04,0x24,0xbb,
  1858. 0x54,0x86,0xdb,0xda,0x00,0x00,0x02,
  1859. 0x00}},
  1860. {{0xab,0x60,0x9f,0x80,0x04,0x24,0xbb,
  1861. 0x3b,0x8d,0xc2,0xc1,0x00,0x00,0x02,
  1862. 0x00}},
  1863. {{0xab,0x60,0x9f,0x80,0x04,0x24,0xb3,
  1864. 0x7c,0x8e,0x03,0x02,0x10,0x00,0x02,
  1865. 0x01}},
  1866. {{0xab,0x63,0x8f,0x8a,0x8e,0x24,0xf1,
  1867. 0xb6,0x88,0x57,0x25,0x10,0x00,0x02,
  1868. 0x01}},
  1869. {{0xab,0x7f,0x8f,0x98,0x9c,0x24,0xf5,
  1870. 0x0a,0x8c,0xff,0x25,0x30,0x00,0x02,
  1871. 0x01}},
  1872. {{0xab,0x9f,0x8f,0xa8,0x8c,0x24,0xf5,
  1873. 0x0a,0x8c,0xff,0x25,0x30,0x00,0x06,
  1874. 0x01}},
  1875. {{0xab,0x9f,0x8f,0xa8,0x8c,0x24,0xf5,
  1876. 0x0a,0x8c,0xff,0x25,0x30,0x00,0x06,
  1877. 0x01}}
  1878. };
  1879. static const SiS_LVDSCRT1DataStruct SiS_LVDSCRT11280x768_2_H[] =
  1880. {
  1881. {{0x83,0x38,0x97,0x58,0x9c,0x24,0xbb,
  1882. 0x54,0x86,0xdb,0xda,0x00,0x00,0x01,
  1883. 0x00}},
  1884. {{0x83,0x38,0x97,0x58,0x9c,0x24,0xbb,
  1885. 0x3b,0x8d,0xc2,0xc1,0x00,0x00,0x01,
  1886. 0x00}},
  1887. {{0x83,0x38,0x97,0x58,0x9c,0x24,0xbb,
  1888. 0x54,0x86,0xdb,0xda,0x00,0x00,0x01,
  1889. 0x00}},
  1890. {{0x83,0x38,0x97,0x58,0x9c,0x24,0xbb,
  1891. 0x3b,0x8d,0xc2,0xc1,0x00,0x00,0x01,
  1892. 0x00}},
  1893. {{0x83,0x38,0x97,0x58,0x9c,0x24,0xb3,
  1894. 0x7c,0x8e,0x03,0x02,0x10,0x00,0x01,
  1895. 0x01}},
  1896. {{0x79,0x31,0x9d,0x58,0x9c,0x24,0xf1,
  1897. 0xb6,0x88,0x57,0x25,0x10,0x00,0x01,
  1898. 0x01}},
  1899. {{0x6b,0x3f,0x8f,0x58,0x9c,0x24,0xf5,
  1900. 0x0a,0x8c,0xff,0x25,0x30,0x00,0x01,
  1901. 0x01}},
  1902. {{0xab,0x9f,0x8f,0xa8,0x8c,0x24,0xf5,
  1903. 0x0a,0x8c,0xff,0x25,0x30,0x00,0x06,
  1904. 0x01}},
  1905. {{0xab,0x9f,0x8f,0xa8,0x8c,0x24,0xf5,
  1906. 0x0a,0x8c,0xff,0x25,0x30,0x00,0x06,
  1907. 0x01}}
  1908. };
  1909. /**************************************************************/
  1910. /* COMMON --------------------------------------------------- */
  1911. /**************************************************************/
  1912. #ifdef LINUX_XF86
  1913. #define SIS_PL_HSYNCP 0x01
  1914. #define SIS_PL_HSYNCN 0x02
  1915. #define SIS_PL_VSYNCP 0x04
  1916. #define SIS_PL_VSYNCN 0x08
  1917. #define SIS_PL_DVI 0x80
  1918. typedef struct _SiS_PlasmaModes
  1919. {
  1920. const char *name;
  1921. ULONG clock;
  1922. USHORT HDisplay, HTotal, HFrontPorch, HSyncWidth;
  1923. USHORT VDisplay, VTotal, VFrontPorch, VSyncWidth;
  1924. UCHAR SyncFlags;
  1925. } SiS_PlasmaModes;
  1926. typedef struct _SiS_PlasmaTables
  1927. {
  1928. USHORT vendor;
  1929. UCHAR productnum;
  1930. USHORT product[5];
  1931. const char *DDCnames[5];
  1932. const char *plasmaname;
  1933. USHORT maxx,maxy;
  1934. USHORT prefx, prefy;
  1935. UCHAR modenum;
  1936. UCHAR plasmamodes[20]; /* | 0x80 = DVI-capable, | 0x40 = analog */
  1937. } SiS_PlasmaTables;
  1938. static const SiS_PlasmaModes SiS_PlasmaMode[] = {
  1939. { "640x400", /* 00: IBM 400@70 */
  1940. 25175,
  1941. 640, 800, 17, 64,
  1942. 400, 449, 13, 2,
  1943. SIS_PL_HSYNCN | SIS_PL_VSYNCN },
  1944. { "640x480", /* 01: VESA 480@72 */
  1945. 31500,
  1946. 640, 832, 24, 40,
  1947. 480, 520, 9, 3,
  1948. SIS_PL_HSYNCN | SIS_PL_VSYNCN },
  1949. { "800x600", /* 02: VESA 600@72 */
  1950. 50000,
  1951. 800, 1040, 56, 120,
  1952. 600, 666, 37, 6,
  1953. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  1954. { "864x480", /* 03: Cereb wide 1 */
  1955. 42526,
  1956. 864, 1134, 22, 86,
  1957. 480, 500, 1, 3,
  1958. SIS_PL_HSYNCP | SIS_PL_VSYNCN },
  1959. { "848x480", /* 04: VESA wide (NEC1) */
  1960. 33750,
  1961. 848, 1088, 16, 112,
  1962. 480, 517, 6, 8,
  1963. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  1964. { "1024x576", /* 05: VESA wide (NEC2) */
  1965. 47250,
  1966. 1024, 1320, 16, 144,
  1967. 576, 596, 2, 4,
  1968. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  1969. { "1280x720", /* 06: VESA wide (NEC3) */
  1970. 76500,
  1971. 1280, 1696, 48, 176,
  1972. 720, 750, 4, 8,
  1973. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  1974. { "1360x765", /* 07: VESA wide (NEC4) */
  1975. 85500,
  1976. 1360, 1792, 64, 176,
  1977. 765, 795, 4, 8,
  1978. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  1979. { "1024x600", /* 08: CEREB wide 2 */
  1980. 51200,
  1981. 1024, 1352, 51, 164,
  1982. 600, 628, 1, 4,
  1983. SIS_PL_HSYNCN | SIS_PL_VSYNCP },
  1984. { "1024x768", /* 09: VESA 768@75 */
  1985. 78750,
  1986. 1024, 1312, 16, 96,
  1987. 768, 800, 1, 3,
  1988. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  1989. { "1152x864", /* 10: VESA 1152x864@75 */
  1990. 108000,
  1991. 1152, 1600, 64, 128,
  1992. 864, 900, 1, 3,
  1993. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  1994. { "1280x1024", /* 11: VESA 1024@60 */
  1995. 108000,
  1996. 1280, 1688, 48, 112,
  1997. 1024, 1066, 1, 3,
  1998. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  1999. { "1280x768", /* 12: W_XGA */
  2000. 81000,
  2001. 1280, 1688, 48, 112,
  2002. 768, 802, 3, 6,
  2003. SIS_PL_HSYNCP | SIS_PL_VSYNCN },
  2004. { "1280x768", /* 13: I/O Data W_XGA@56Hz */
  2005. 76064,
  2006. 1280, 1688, 48, 112,
  2007. 768, 802, 2, 3,
  2008. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2009. { "1376x768", /* 14: I/O Wide XGA */
  2010. 87340,
  2011. 1376, 1808, 32, 128,
  2012. 768, 806, 3, 6,
  2013. SIS_PL_HSYNCN | SIS_PL_VSYNCP },
  2014. { "1280x960", /* 15: VESA 960@60 */
  2015. 108000,
  2016. 1280, 1800, 96, 112,
  2017. 960, 1000, 1, 3,
  2018. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2019. { "1400x1050", /* 16: VESA 1050@60Hz */
  2020. 108000,
  2021. 1400, 1688, 48, 112,
  2022. 1050, 1066, 1, 3,
  2023. SIS_PL_HSYNCN | SIS_PL_VSYNCN },
  2024. { "1360x768", /* 17: VESA wide (NEC4/2) */
  2025. 85500,
  2026. 1360, 1792, 64, 112,
  2027. 765, 795, 3, 6,
  2028. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2029. { "800x600", /* 18: VESA 600@56 */
  2030. 36000,
  2031. 800, 1024, 24, 2,
  2032. 600, 625, 1, 2,
  2033. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2034. { "1072x600", /* 19: Panasonic 1072x600 (sync?) */
  2035. 54100,
  2036. 1072, 1424, 48, 176,
  2037. 600, 628, 16, 1,
  2038. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2039. { "848x480", /* 20: Panasonic 848x480 (sync?) */
  2040. 33070, /* is 852x480, but we can't use 852 */
  2041. 848, 1068, 20, 40, /* differs from DDC data, better centered */
  2042. 480, 516, 3, 5, /* won't work assumingly, because data is % 8 */
  2043. SIS_PL_HSYNCN | SIS_PL_VSYNCN },
  2044. { "1280x720", /* 21: WIDE720(60) (aka "750p") (Panasonic) */
  2045. 74300,
  2046. 1280, 1650,110, 40,
  2047. 720, 750, 5, 5,
  2048. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2049. { "1280x768", /* 22: 1280x768@56.5 (Panasonic) */
  2050. 76200, /* (According to manual not supported for HDMI; but works) */
  2051. 1280, 1680, 16, 24,
  2052. 768, 802, 2, 5,
  2053. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2054. { "1280x720@50", /* 23: WIDE720(50) (aka "750p") (Panasonic) */
  2055. 74300, /* Panasonic states 45.0kHz. Not possible. This one works (with some overscan) */
  2056. 1280, 1980,400, 80,
  2057. 720, 750, 1, 2,
  2058. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2059. { "720x480", /* 24: 720x480 (aka "525p" and "480p") (Panasonic) */
  2060. 27000,
  2061. 720, 856, 40, 32,
  2062. 480, 525, 1, 3,
  2063. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2064. { "720x576", /* 25: 720x576 (aka "625p"and "576p") (Panasonic) */
  2065. 27500,
  2066. 720, 864, 16, 64,
  2067. 576, 625, 5, 6,
  2068. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2069. { "1280x720@50", /* 26: WIDE720(50) (aka "750p") (Generic) */
  2070. 74300,
  2071. 1280, 1980,400, 80,
  2072. 720, 750, 5, 5,
  2073. SIS_PL_HSYNCP | SIS_PL_VSYNCP },
  2074. };
  2075. /*
  2076. 27.00 720 755 791 858 480 480 484 525
  2077. 27.50 720 732 795 864 576 581 587 625
  2078. */
  2079. static const SiS_PlasmaTables SiS_PlasmaTable[] = {
  2080. #if 0 /* Product IDs missing */
  2081. { 0x38a3, 4,
  2082. { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 },
  2083. { "", "", "", "", "" },
  2084. "NEC PlasmaSync 42VP4/42VP4D/42VP4G/42VP4DG",
  2085. 0, 0,
  2086. 0, 0,
  2087. 11, /* All DVI, except 0, 7, 13 */
  2088. { 0|0x40, 1|0xc0, 2|0xc0, 4|0xc0, 7|0x40, 9|0xc0,10|0xc0,11|0xc0,13|0x40,14|0xc0,
  2089. 17|0xc0, 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2090. },
  2091. #endif
  2092. #if 0 /* Product IDs missing */
  2093. { 0x38a3, 3,
  2094. { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 },
  2095. { "", "", "", "", "" },
  2096. "NEC PlasmaSync 42PD1/50PD1/50PD2",
  2097. 0, 0,
  2098. 0, 0,
  2099. 5, /* DVI entirely unknown */
  2100. { 0|0x40, 1|0xc0, 2|0xc0, 4|0xc0, 9|0xc0, 0 , 0 , 0 , 0 , 0 ,
  2101. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2102. },
  2103. { 0x38a3, 1,
  2104. { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 },
  2105. { "", "", "", "", "" },
  2106. "NEC PlasmaSync 42PD3",
  2107. 0, 0,
  2108. 0, 0,
  2109. 10, /* DVI entirely unknown */
  2110. { 0|0x40, 1|0xc0, 2|0xc0, 3|0xc0, 4|0xc0, 5|0xc0, 6|0xc0, 7|0x40, 8|0xc0, 9|0xc0,
  2111. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2112. },
  2113. { 0x38a3, 2,
  2114. { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 },
  2115. { "", "", "", "", "" },
  2116. "NEC PlasmaSync 42VM3/61XM1",
  2117. 0, 0,
  2118. 0, 0,
  2119. 11, /* DVI entirely unknown */
  2120. { 0|0x40, 1|0xc0, 2|0xc0, 3|0xc0, 4|0xc0, 5|0xc0, 6|0xc0, 8|0xc0, 9|0xc0,11|0xc0,
  2121. 17|0xc0, 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2122. },
  2123. { 0x38a3, 2,
  2124. { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 },
  2125. { "", "", "", "", "" },
  2126. "NEC PlasmaSync 42MP1/42MP2",
  2127. 0, 0,
  2128. 0, 0,
  2129. 6, /* DVI entirely unknown */
  2130. { 0|0x40, 1|0xc0, 2|0xc0, 4|0xc0, 9|0xc0,11|0xc0, 0 , 0 , 0 , 0 ,
  2131. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2132. },
  2133. { 0x38a3, 1,
  2134. { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 },
  2135. { "", "", "", "", "" },
  2136. "NEC PlasmaSync 50MP1",
  2137. 0, 0,
  2138. 0, 0,
  2139. 10, /* DVI entirely unknown */
  2140. { 0|0x40, 1|0xc0, 2|0xc0, 4|0xc0, 7|0x40, 9|0xc0,10|0xc0,11|0xc0,13|0x40,14|0xc0,
  2141. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2142. },
  2143. #endif
  2144. { 0x38a3, 4,
  2145. { 0xa482, 0xa483, 0x0000, 0x0000, 0x0000 },
  2146. { "PX-42VM", "", "", "", "" },
  2147. "NEC PlasmaSync 42MP3/42MP4/50MP2/61MP1",
  2148. 0, 0,
  2149. 0, 0,
  2150. 11, /* All DVI except 0, 7, 13, 17 */
  2151. { 0|0x40, 1|0xc0, 2|0xc0, 4|0xc0, 7|0x40, 9|0xc0,10|0xc0,11|0xc0,13|0x40,14|0xc0,
  2152. 17|0x40, 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2153. },
  2154. #if 0 /* Product IDs missing */
  2155. { 0x38a3, 1,
  2156. { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 },
  2157. { "", "", "", "", "" },
  2158. "NEC PlasmaSync 3300W",
  2159. 0, 0,
  2160. 0, 0,
  2161. 3,
  2162. { 0|0x40, 1|0xc0,18|0xc0, 0 , 0 , 0 , 0 , 0 , 0 , 0 ,
  2163. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2164. },
  2165. { 0x38a3, 1,
  2166. { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 },
  2167. { "", "", "", "", "" },
  2168. "NEC PlasmaSync 4200W",
  2169. 4, /* DVI entirely unknown */
  2170. { 0|0x40, 1|0xc0, 2|0xc0, 4|0xc0, 0 , 0 , 0 , 0 , 0 , 0 ,
  2171. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2172. },
  2173. { 0x38a3, 1,
  2174. { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 },
  2175. { "", "", "", "", "" },
  2176. "NEC PlasmaSync 4210W",
  2177. 0, 0,
  2178. 0, 0,
  2179. 6, /* DVI entirely unknown */
  2180. { 0|0x40, 1|0xc0, 2|0xc0, 4|0xc0, 9|0xc0,11|0xc0, 0 , 0 , 0 , 0 ,
  2181. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2182. },
  2183. { 0x38a3, 1,
  2184. { 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 },
  2185. { "", "", "", "", "" },
  2186. "NEC PlasmaSync 5000W",
  2187. 0, 0,
  2188. 0, 0,
  2189. 7, /* DVI entirely unknown */
  2190. { 0|0x40, 1|0xc0, 2|0xc0, 4|0xc0, 7|0x40, 9|0xc0,11|0xc0, 0 , 0 , 0 ,
  2191. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2192. },
  2193. #endif
  2194. { 0x412f, 2,
  2195. { 0x000c, 0x000b, 0x0000, 0x0000, 0x0000 },
  2196. { "", "", "", "", "" },
  2197. "Pioneer 503CMX/PDA-5002",
  2198. 0, 0,
  2199. 0, 0,
  2200. 6, /* DVI unknown */
  2201. { 1|0xc0, 2|0xc0, 9|0xc0,11|0xc0,12|0xc0,15|0xc0, 0 , 0 , 0 , 0 ,
  2202. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2203. },
  2204. { 0x34a9, 1,
  2205. { 0xa00e, 0x0000, 0x0000, 0x0000, 0x0000 },
  2206. { "", "", "", "", "" },
  2207. "Panasonic TH-42",
  2208. 0, 0,
  2209. 0, 0,
  2210. 5, /* No DVI output */
  2211. { 1|0x40, 2|0x40, 4|0x40, 9|0x40,15|0x40, 0 , 0 , 0 , 0 , 0 ,
  2212. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2213. },
  2214. { 0x34a9, 1,
  2215. { 0xa005, 0x0000, 0x0000, 0x0000, 0x0000 },
  2216. { "TH-42PW*4", "", "", "", "" },
  2217. "Panasonic TH-42PW5",
  2218. 0, 0,
  2219. 0, 0,
  2220. 1, /* No special modes otherwise; no DVI. */
  2221. {20|0x40,19|0x40, 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 ,
  2222. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2223. },
  2224. { 0x4c2e, 1,
  2225. { 0x9b05, 0x0000, 0x0000, 0x0000, 0x0000 },
  2226. { "PLV-Z2", "", "", "", "" },
  2227. "Sanyo PLV-Z2 (non HDCP-mode)", /* HDCP mode would be id 9b06, but not needed */
  2228. 1280, 768, /* as it then advertises correct size */
  2229. 1280, 720,
  2230. 1, /* 1280x720, no special modes otherwise */
  2231. {21|0xc0, 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 ,
  2232. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2233. },
  2234. { 0x34a9, 1,
  2235. { 0xd034, 0x0000, 0x0000, 0x0000, 0x0000 },
  2236. { "AE500U (DVI-D)", "", "", "", "" },
  2237. "Panasonic AE500U",
  2238. 1280, 768,
  2239. 1280, 720,
  2240. 1, /* 1280x720, no special modes otherwise */
  2241. {21|0xc0, 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 ,
  2242. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2243. },
  2244. { 0x34a9, 1,
  2245. { 0xd043, 0x0000, 0x0000, 0x0000, 0x0000 },
  2246. { "AE700U (HDMI)", "", "", "", "" },
  2247. "Panasonic AE700U",
  2248. 1360, 768,
  2249. 1280, 720,
  2250. 6, /* 1280x720/60, 1280x720/50, 1280x768@56(digital/analog), 720x480, 720x576 */
  2251. {21|0xc0,23|0xc0,22|0x80,13|0x40,24|0x80,25|0x80, 0 , 0 , 0 , 0 ,
  2252. 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 }
  2253. },
  2254. { 0x0000 }
  2255. };
  2256. #endif
  2257. #ifdef LINUX_XF86
  2258. USHORT SiS_GetModeID(int VGAEngine, ULONG VBFlags, int HDisplay, int VDisplay,
  2259. int Depth, BOOLEAN FSTN, int LCDwith, int LCDheight);
  2260. #endif
  2261. USHORT SiS_GetModeID_LCD(int VGAEngine, ULONG VBFlags, int HDisplay, int VDisplay, int Depth, BOOLEAN FSTN,
  2262. USHORT CustomT, int LCDwith, int LCDheight);
  2263. USHORT SiS_GetModeID_TV(int VGAEngine, ULONG VBFlags, int HDisplay, int VDisplay, int Depth);
  2264. USHORT SiS_GetModeID_VGA2(int VGAEngine, ULONG VBFlags, int HDisplay, int VDisplay, int Depth);
  2265. void SiS_SetReg(SISIOADDRESS port, USHORT index, USHORT data);
  2266. void SiS_SetRegByte(SISIOADDRESS port, USHORT data);
  2267. void SiS_SetRegShort(SISIOADDRESS port, USHORT data);
  2268. void SiS_SetRegLong(SISIOADDRESS port, ULONG data);
  2269. UCHAR SiS_GetReg(SISIOADDRESS port, USHORT index);
  2270. UCHAR SiS_GetRegByte(SISIOADDRESS port);
  2271. USHORT SiS_GetRegShort(SISIOADDRESS port);
  2272. ULONG SiS_GetRegLong(SISIOADDRESS port);
  2273. void SiS_SetRegANDOR(SISIOADDRESS Port, USHORT Index, USHORT DataAND, USHORT DataOR);
  2274. void SiS_SetRegAND(SISIOADDRESS Port,USHORT Index, USHORT DataAND);
  2275. void SiS_SetRegOR(SISIOADDRESS Port,USHORT Index, USHORT DataOR);
  2276. void SiS_DisplayOn(SiS_Private *SiS_Pr);
  2277. void SiS_DisplayOff(SiS_Private *SiS_Pr);
  2278. void SiSRegInit(SiS_Private *SiS_Pr, SISIOADDRESS BaseAddr);
  2279. BOOLEAN SiSDetermineROMLayout661(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo);
  2280. void SiS_SetEnableDstn(SiS_Private *SiS_Pr, int enable);
  2281. void SiS_SetEnableFstn(SiS_Private *SiS_Pr, int enable);
  2282. BOOLEAN SiS_SearchModeID(SiS_Private *SiS_Pr, USHORT *ModeNo, USHORT *ModeIdIndex);
  2283. UCHAR SiS_GetModePtr(SiS_Private *SiS_Pr, USHORT ModeNo, USHORT ModeIdIndex);
  2284. USHORT SiS_GetColorDepth(SiS_Private *SiS_Pr, USHORT ModeNo, USHORT ModeIdIndex);
  2285. USHORT SiS_GetOffset(SiS_Private *SiS_Pr,USHORT ModeNo, USHORT ModeIdIndex,
  2286. USHORT RefreshRateTableIndex, PSIS_HW_INFO HwInfo);
  2287. void SiS_LoadDAC(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo, USHORT ModeNo, USHORT ModeIdIndex);
  2288. void SiS_CalcLCDACRT1Timing(SiS_Private *SiS_Pr, USHORT ModeNo, USHORT ModeIdIndex);
  2289. #ifdef LINUX_XF86
  2290. BOOLEAN SiSSetMode(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo,ScrnInfoPtr pScrn,USHORT ModeNo, BOOLEAN dosetpitch);
  2291. BOOLEAN SiSBIOSSetMode(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo, ScrnInfoPtr pScrn,
  2292. DisplayModePtr mode, BOOLEAN IsCustom);
  2293. BOOLEAN SiSBIOSSetModeCRT2(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo, ScrnInfoPtr pScrn,
  2294. DisplayModePtr mode, BOOLEAN IsCustom);
  2295. BOOLEAN SiSBIOSSetModeCRT1(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo, ScrnInfoPtr pScrn,
  2296. DisplayModePtr mode, BOOLEAN IsCustom);
  2297. int SiSTranslateToVESA(ScrnInfoPtr pScrn, int modenumber);
  2298. int SiSTranslateToOldMode(int modenumber);
  2299. BOOLEAN SiS_GetPanelID(SiS_Private *SiS_Pr, PSIS_HW_INFO);
  2300. USHORT SiS_CheckBuildCustomMode(ScrnInfoPtr pScrn, DisplayModePtr mode, int VBFlags);
  2301. DisplayModePtr SiSBuildBuiltInModeList(ScrnInfoPtr pScrn, BOOLEAN includelcdmodes, BOOLEAN isfordvi);
  2302. int SiS_FindPanelFromDB(SISPtr pSiS, USHORT panelvendor, USHORT panelproduct, int *maxx, int *maxy, int *prefx, int *prefy);
  2303. void SiS_MakeClockRegs(ScrnInfoPtr pScrn, int clock, UCHAR *p2b, UCHAR *p2c);
  2304. #else
  2305. BOOLEAN SiSSetMode(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo,USHORT ModeNo);
  2306. #endif
  2307. #ifdef LINUX_KERNEL
  2308. int sisfb_mode_rate_to_dclock(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo,
  2309. UCHAR modeno, UCHAR rateindex);
  2310. int sisfb_mode_rate_to_ddata(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo,
  2311. UCHAR modeno, UCHAR rateindex,
  2312. struct fb_var_screeninfo *var);
  2313. BOOLEAN sisfb_gettotalfrommode(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo,
  2314. UCHAR modeno, int *htotal, int *vtotal, UCHAR rateindex);
  2315. #endif
  2316. /* init301.c: */
  2317. extern void SiS_GetVBInfo(SiS_Private *SiS_Pr, USHORT ModeNo, USHORT ModeIdIndex,
  2318. PSIS_HW_INFO HwInfo, int chkcrt2mode);
  2319. extern void SiS_GetLCDResInfo(SiS_Private *SiS_Pr, USHORT ModeNo, USHORT ModeIdIndex,
  2320. PSIS_HW_INFO HwInfo);
  2321. extern void SiS_SetYPbPr(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo);
  2322. extern void SiS_SetTVMode(SiS_Private *SiS_Pr, USHORT ModeNo, USHORT ModeIdIndex, PSIS_HW_INFO HwInfo);
  2323. extern void SiS_UnLockCRT2(SiS_Private *SiS_Pr, PSIS_HW_INFO HwInfo);
  2324. extern void SiS_DisableBridge(SiS_Private *, PSIS_HW_INFO);
  2325. extern BOOLEAN SiS_SetCRT2Group(SiS_Private *, PSIS_HW_INFO, USHORT);
  2326. extern USHORT SiS_GetRatePtr(SiS_Private *SiS_Pr, USHORT ModeNo, USHORT ModeIdIndex,
  2327. PSIS_HW_INFO HwInfo);
  2328. extern void SiS_WaitRetrace1(SiS_Private *SiS_Pr);
  2329. extern USHORT SiS_GetResInfo(SiS_Private *SiS_Pr, USHORT ModeNo, USHORT ModeIdIndex);
  2330. extern USHORT SiS_GetCH700x(SiS_Private *SiS_Pr, USHORT tempax);
  2331. extern USHORT SiS_GetVCLK2Ptr(SiS_Private *SiS_Pr, USHORT ModeNo, USHORT ModeIdIndex,
  2332. USHORT RefreshRateTableIndex, PSIS_HW_INFO HwInfo);
  2333. extern BOOLEAN SiS_IsVAMode(SiS_Private *, PSIS_HW_INFO);
  2334. extern BOOLEAN SiS_IsDualEdge(SiS_Private *, PSIS_HW_INFO);
  2335. #ifdef LINUX_XF86
  2336. /* From other sis driver modules: */
  2337. extern int SiS_compute_vclk(int Clock, int *out_n, int *out_dn, int *out_div,
  2338. int *out_sbit, int *out_scale);
  2339. extern void SiSCalcClock(ScrnInfoPtr pScrn, int clock, int max_VLD, unsigned int *vclk);
  2340. extern UCHAR SiS_GetSetBIOSScratch(ScrnInfoPtr pScrn, USHORT offset, UCHAR value);
  2341. extern UCHAR SiS_GetSetModeID(ScrnInfoPtr pScrn, UCHAR id);
  2342. extern USHORT SiS_GetModeNumber(ScrnInfoPtr pScrn, DisplayModePtr mode, ULONG VBFlags);
  2343. #endif
  2344. #endif