smtcfb.h 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789
  1. /*
  2. * Silicon Motion SM712 frame buffer device
  3. *
  4. * Copyright (C) 2006 Silicon Motion Technology Corp.
  5. * Authors: Ge Wang, gewang@siliconmotion.com
  6. * Boyod boyod.yang@siliconmotion.com.cn
  7. *
  8. * Copyright (C) 2009 Lemote, Inc.
  9. * Author: Wu Zhangjin, wuzhangjin@gmail.com
  10. *
  11. * This file is subject to the terms and conditions of the GNU General Public
  12. * License. See the file COPYING in the main directory of this archive for
  13. * more details.
  14. */
  15. #define SMTC_LINUX_FB_VERSION "version 0.11.2619.21.01 July 27, 2008"
  16. #define NR_PALETTE 256
  17. #define NR_RGB 2
  18. #define FB_ACCEL_SMI_LYNX 88
  19. #ifdef __BIG_ENDIAN
  20. #define PC_VGA 0
  21. #else
  22. #define PC_VGA 1
  23. #endif
  24. #define SCREEN_X_RES 1024
  25. #define SCREEN_Y_RES 600
  26. #define SCREEN_BPP 16
  27. /*Assume SM712 graphics chip has 4MB VRAM */
  28. #define SM712_VIDEOMEMORYSIZE 0x00400000
  29. /*Assume SM722 graphics chip has 8MB VRAM */
  30. #define SM722_VIDEOMEMORYSIZE 0x00800000
  31. #define dac_reg (0x3c8)
  32. #define dac_val (0x3c9)
  33. extern char *smtc_RegBaseAddress;
  34. #define smtc_mmiowb(dat, reg) writeb(dat, smtc_RegBaseAddress + reg)
  35. #define smtc_mmioww(dat, reg) writew(dat, smtc_RegBaseAddress + reg)
  36. #define smtc_mmiowl(dat, reg) writel(dat, smtc_RegBaseAddress + reg)
  37. #define smtc_mmiorb(reg) readb(smtc_RegBaseAddress + reg)
  38. #define smtc_mmiorw(reg) readw(smtc_RegBaseAddress + reg)
  39. #define smtc_mmiorl(reg) readl(smtc_RegBaseAddress + reg)
  40. #define SIZE_SR00_SR04 (0x04 - 0x00 + 1)
  41. #define SIZE_SR10_SR24 (0x24 - 0x10 + 1)
  42. #define SIZE_SR30_SR75 (0x75 - 0x30 + 1)
  43. #define SIZE_SR80_SR93 (0x93 - 0x80 + 1)
  44. #define SIZE_SRA0_SRAF (0xAF - 0xA0 + 1)
  45. #define SIZE_GR00_GR08 (0x08 - 0x00 + 1)
  46. #define SIZE_AR00_AR14 (0x14 - 0x00 + 1)
  47. #define SIZE_CR00_CR18 (0x18 - 0x00 + 1)
  48. #define SIZE_CR30_CR4D (0x4D - 0x30 + 1)
  49. #define SIZE_CR90_CRA7 (0xA7 - 0x90 + 1)
  50. #define SIZE_VPR (0x6C + 1)
  51. #define SIZE_DPR (0x44 + 1)
  52. static inline void smtc_crtcw(int reg, int val)
  53. {
  54. smtc_mmiowb(reg, 0x3d4);
  55. smtc_mmiowb(val, 0x3d5);
  56. }
  57. static inline unsigned int smtc_crtcr(int reg)
  58. {
  59. smtc_mmiowb(reg, 0x3d4);
  60. return smtc_mmiorb(0x3d5);
  61. }
  62. static inline void smtc_grphw(int reg, int val)
  63. {
  64. smtc_mmiowb(reg, 0x3ce);
  65. smtc_mmiowb(val, 0x3cf);
  66. }
  67. static inline unsigned int smtc_grphr(int reg)
  68. {
  69. smtc_mmiowb(reg, 0x3ce);
  70. return smtc_mmiorb(0x3cf);
  71. }
  72. static inline void smtc_attrw(int reg, int val)
  73. {
  74. smtc_mmiorb(0x3da);
  75. smtc_mmiowb(reg, 0x3c0);
  76. smtc_mmiorb(0x3c1);
  77. smtc_mmiowb(val, 0x3c0);
  78. }
  79. static inline void smtc_seqw(int reg, int val)
  80. {
  81. smtc_mmiowb(reg, 0x3c4);
  82. smtc_mmiowb(val, 0x3c5);
  83. }
  84. static inline unsigned int smtc_seqr(int reg)
  85. {
  86. smtc_mmiowb(reg, 0x3c4);
  87. return smtc_mmiorb(0x3c5);
  88. }
  89. /* The next structure holds all information relevant for a specific video mode.
  90. */
  91. struct ModeInit {
  92. int mmSizeX;
  93. int mmSizeY;
  94. int bpp;
  95. int hz;
  96. unsigned char Init_MISC;
  97. unsigned char Init_SR00_SR04[SIZE_SR00_SR04];
  98. unsigned char Init_SR10_SR24[SIZE_SR10_SR24];
  99. unsigned char Init_SR30_SR75[SIZE_SR30_SR75];
  100. unsigned char Init_SR80_SR93[SIZE_SR80_SR93];
  101. unsigned char Init_SRA0_SRAF[SIZE_SRA0_SRAF];
  102. unsigned char Init_GR00_GR08[SIZE_GR00_GR08];
  103. unsigned char Init_AR00_AR14[SIZE_AR00_AR14];
  104. unsigned char Init_CR00_CR18[SIZE_CR00_CR18];
  105. unsigned char Init_CR30_CR4D[SIZE_CR30_CR4D];
  106. unsigned char Init_CR90_CRA7[SIZE_CR90_CRA7];
  107. };
  108. /**********************************************************************
  109. SM712 Mode table.
  110. **********************************************************************/
  111. struct ModeInit VGAMode[] = {
  112. {
  113. /* mode#0: 640 x 480 16Bpp 60Hz */
  114. 640, 480, 16, 60,
  115. /* Init_MISC */
  116. 0xE3,
  117. { /* Init_SR0_SR4 */
  118. 0x03, 0x01, 0x0F, 0x00, 0x0E,
  119. },
  120. { /* Init_SR10_SR24 */
  121. 0xFF, 0xBE, 0xEF, 0xFF, 0x00, 0x0E, 0x17, 0x2C,
  122. 0x99, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  123. 0xC4, 0x30, 0x02, 0x01, 0x01,
  124. },
  125. { /* Init_SR30_SR75 */
  126. 0x32, 0x03, 0xA0, 0x09, 0xC0, 0x32, 0x32, 0x32,
  127. 0x32, 0x32, 0x32, 0x32, 0x00, 0x00, 0x03, 0xFF,
  128. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x18, 0x00, 0xFC,
  129. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x32, 0x32, 0x32,
  130. 0x04, 0x24, 0x63, 0x4F, 0x52, 0x0B, 0xDF, 0xEA,
  131. 0x04, 0x50, 0x19, 0x32, 0x32, 0x00, 0x00, 0x32,
  132. 0x01, 0x80, 0x7E, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  133. 0x50, 0x03, 0x74, 0x14, 0x07, 0x82, 0x07, 0x04,
  134. 0x00, 0x45, 0x30, 0x30, 0x40, 0x30,
  135. },
  136. { /* Init_SR80_SR93 */
  137. 0xFF, 0x07, 0x00, 0x6F, 0x7F, 0x7F, 0xFF, 0x32,
  138. 0xF7, 0x00, 0x00, 0x00, 0xEF, 0xFF, 0x32, 0x32,
  139. 0x00, 0x00, 0x00, 0x00,
  140. },
  141. { /* Init_SRA0_SRAF */
  142. 0x00, 0xFF, 0xBF, 0xFF, 0xFF, 0xED, 0xED, 0xED,
  143. 0x7B, 0xFF, 0xFF, 0xFF, 0xBF, 0xEF, 0xFF, 0xDF,
  144. },
  145. { /* Init_GR00_GR08 */
  146. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  147. 0xFF,
  148. },
  149. { /* Init_AR00_AR14 */
  150. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  151. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  152. 0x41, 0x00, 0x0F, 0x00, 0x00,
  153. },
  154. { /* Init_CR00_CR18 */
  155. 0x5F, 0x4F, 0x4F, 0x00, 0x53, 0x1F, 0x0B, 0x3E,
  156. 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  157. 0xEA, 0x0C, 0xDF, 0x50, 0x40, 0xDF, 0x00, 0xE3,
  158. 0xFF,
  159. },
  160. { /* Init_CR30_CR4D */
  161. 0x00, 0x00, 0x00, 0x00, 0x00, 0x55, 0x03, 0x20,
  162. 0x00, 0x00, 0x00, 0x40, 0x00, 0xE7, 0xFF, 0xFD,
  163. 0x5F, 0x4F, 0x00, 0x54, 0x00, 0x0B, 0xDF, 0x00,
  164. 0xEA, 0x0C, 0x2E, 0x00, 0x4F, 0xDF,
  165. },
  166. { /* Init_CR90_CRA7 */
  167. 0x56, 0xDD, 0x5E, 0xEA, 0x87, 0x44, 0x8F, 0x55,
  168. 0x0A, 0x8F, 0x55, 0x0A, 0x00, 0x00, 0x18, 0x00,
  169. 0x11, 0x10, 0x0B, 0x0A, 0x0A, 0x0A, 0x0A, 0x00,
  170. },
  171. },
  172. {
  173. /* mode#1: 640 x 480 24Bpp 60Hz */
  174. 640, 480, 24, 60,
  175. /* Init_MISC */
  176. 0xE3,
  177. { /* Init_SR0_SR4 */
  178. 0x03, 0x01, 0x0F, 0x00, 0x0E,
  179. },
  180. { /* Init_SR10_SR24 */
  181. 0xFF, 0xBE, 0xEF, 0xFF, 0x00, 0x0E, 0x17, 0x2C,
  182. 0x99, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  183. 0xC4, 0x30, 0x02, 0x01, 0x01,
  184. },
  185. { /* Init_SR30_SR75 */
  186. 0x32, 0x03, 0xA0, 0x09, 0xC0, 0x32, 0x32, 0x32,
  187. 0x32, 0x32, 0x32, 0x32, 0x00, 0x00, 0x03, 0xFF,
  188. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x18, 0x00, 0xFC,
  189. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x32, 0x32, 0x32,
  190. 0x04, 0x24, 0x63, 0x4F, 0x52, 0x0B, 0xDF, 0xEA,
  191. 0x04, 0x50, 0x19, 0x32, 0x32, 0x00, 0x00, 0x32,
  192. 0x01, 0x80, 0x7E, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  193. 0x50, 0x03, 0x74, 0x14, 0x07, 0x82, 0x07, 0x04,
  194. 0x00, 0x45, 0x30, 0x30, 0x40, 0x30,
  195. },
  196. { /* Init_SR80_SR93 */
  197. 0xFF, 0x07, 0x00, 0x6F, 0x7F, 0x7F, 0xFF, 0x32,
  198. 0xF7, 0x00, 0x00, 0x00, 0xEF, 0xFF, 0x32, 0x32,
  199. 0x00, 0x00, 0x00, 0x00,
  200. },
  201. { /* Init_SRA0_SRAF */
  202. 0x00, 0xFF, 0xBF, 0xFF, 0xFF, 0xED, 0xED, 0xED,
  203. 0x7B, 0xFF, 0xFF, 0xFF, 0xBF, 0xEF, 0xFF, 0xDF,
  204. },
  205. { /* Init_GR00_GR08 */
  206. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  207. 0xFF,
  208. },
  209. { /* Init_AR00_AR14 */
  210. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  211. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  212. 0x41, 0x00, 0x0F, 0x00, 0x00,
  213. },
  214. { /* Init_CR00_CR18 */
  215. 0x5F, 0x4F, 0x4F, 0x00, 0x53, 0x1F, 0x0B, 0x3E,
  216. 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  217. 0xEA, 0x0C, 0xDF, 0x50, 0x40, 0xDF, 0x00, 0xE3,
  218. 0xFF,
  219. },
  220. { /* Init_CR30_CR4D */
  221. 0x00, 0x00, 0x00, 0x00, 0x00, 0x55, 0x03, 0x20,
  222. 0x00, 0x00, 0x00, 0x40, 0x00, 0xE7, 0xFF, 0xFD,
  223. 0x5F, 0x4F, 0x00, 0x54, 0x00, 0x0B, 0xDF, 0x00,
  224. 0xEA, 0x0C, 0x2E, 0x00, 0x4F, 0xDF,
  225. },
  226. { /* Init_CR90_CRA7 */
  227. 0x56, 0xDD, 0x5E, 0xEA, 0x87, 0x44, 0x8F, 0x55,
  228. 0x0A, 0x8F, 0x55, 0x0A, 0x00, 0x00, 0x18, 0x00,
  229. 0x11, 0x10, 0x0B, 0x0A, 0x0A, 0x0A, 0x0A, 0x00,
  230. },
  231. },
  232. {
  233. /* mode#0: 640 x 480 32Bpp 60Hz */
  234. 640, 480, 32, 60,
  235. /* Init_MISC */
  236. 0xE3,
  237. { /* Init_SR0_SR4 */
  238. 0x03, 0x01, 0x0F, 0x00, 0x0E,
  239. },
  240. { /* Init_SR10_SR24 */
  241. 0xFF, 0xBE, 0xEF, 0xFF, 0x00, 0x0E, 0x17, 0x2C,
  242. 0x99, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  243. 0xC4, 0x30, 0x02, 0x01, 0x01,
  244. },
  245. { /* Init_SR30_SR75 */
  246. 0x32, 0x03, 0xA0, 0x09, 0xC0, 0x32, 0x32, 0x32,
  247. 0x32, 0x32, 0x32, 0x32, 0x00, 0x00, 0x03, 0xFF,
  248. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x18, 0x00, 0xFC,
  249. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x32, 0x32, 0x32,
  250. 0x04, 0x24, 0x63, 0x4F, 0x52, 0x0B, 0xDF, 0xEA,
  251. 0x04, 0x50, 0x19, 0x32, 0x32, 0x00, 0x00, 0x32,
  252. 0x01, 0x80, 0x7E, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  253. 0x50, 0x03, 0x74, 0x14, 0x07, 0x82, 0x07, 0x04,
  254. 0x00, 0x45, 0x30, 0x30, 0x40, 0x30,
  255. },
  256. { /* Init_SR80_SR93 */
  257. 0xFF, 0x07, 0x00, 0x6F, 0x7F, 0x7F, 0xFF, 0x32,
  258. 0xF7, 0x00, 0x00, 0x00, 0xEF, 0xFF, 0x32, 0x32,
  259. 0x00, 0x00, 0x00, 0x00,
  260. },
  261. { /* Init_SRA0_SRAF */
  262. 0x00, 0xFF, 0xBF, 0xFF, 0xFF, 0xED, 0xED, 0xED,
  263. 0x7B, 0xFF, 0xFF, 0xFF, 0xBF, 0xEF, 0xFF, 0xDF,
  264. },
  265. { /* Init_GR00_GR08 */
  266. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  267. 0xFF,
  268. },
  269. { /* Init_AR00_AR14 */
  270. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  271. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  272. 0x41, 0x00, 0x0F, 0x00, 0x00,
  273. },
  274. { /* Init_CR00_CR18 */
  275. 0x5F, 0x4F, 0x4F, 0x00, 0x53, 0x1F, 0x0B, 0x3E,
  276. 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  277. 0xEA, 0x0C, 0xDF, 0x50, 0x40, 0xDF, 0x00, 0xE3,
  278. 0xFF,
  279. },
  280. { /* Init_CR30_CR4D */
  281. 0x00, 0x00, 0x00, 0x00, 0x00, 0x55, 0x03, 0x20,
  282. 0x00, 0x00, 0x00, 0x40, 0x00, 0xE7, 0xFF, 0xFD,
  283. 0x5F, 0x4F, 0x00, 0x54, 0x00, 0x0B, 0xDF, 0x00,
  284. 0xEA, 0x0C, 0x2E, 0x00, 0x4F, 0xDF,
  285. },
  286. { /* Init_CR90_CRA7 */
  287. 0x56, 0xDD, 0x5E, 0xEA, 0x87, 0x44, 0x8F, 0x55,
  288. 0x0A, 0x8F, 0x55, 0x0A, 0x00, 0x00, 0x18, 0x00,
  289. 0x11, 0x10, 0x0B, 0x0A, 0x0A, 0x0A, 0x0A, 0x00,
  290. },
  291. },
  292. { /* mode#2: 800 x 600 16Bpp 60Hz */
  293. 800, 600, 16, 60,
  294. /* Init_MISC */
  295. 0x2B,
  296. { /* Init_SR0_SR4 */
  297. 0x03, 0x01, 0x0F, 0x03, 0x0E,
  298. },
  299. { /* Init_SR10_SR24 */
  300. 0xFF, 0xBE, 0xEE, 0xFF, 0x00, 0x0E, 0x17, 0x2C,
  301. 0x99, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
  302. 0xC4, 0x30, 0x02, 0x01, 0x01,
  303. },
  304. { /* Init_SR30_SR75 */
  305. 0x34, 0x03, 0x20, 0x09, 0xC0, 0x24, 0x24, 0x24,
  306. 0x24, 0x24, 0x24, 0x24, 0x00, 0x00, 0x03, 0xFF,
  307. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x38, 0x00, 0xFC,
  308. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x24, 0x24, 0x24,
  309. 0x04, 0x48, 0x83, 0x63, 0x68, 0x72, 0x57, 0x58,
  310. 0x04, 0x55, 0x59, 0x24, 0x24, 0x00, 0x00, 0x24,
  311. 0x01, 0x80, 0x7A, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  312. 0x50, 0x03, 0x74, 0x14, 0x1C, 0x85, 0x35, 0x13,
  313. 0x02, 0x45, 0x30, 0x35, 0x40, 0x20,
  314. },
  315. { /* Init_SR80_SR93 */
  316. 0x00, 0x00, 0x00, 0x6F, 0x7F, 0x7F, 0xFF, 0x24,
  317. 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x24, 0x24,
  318. 0x00, 0x00, 0x00, 0x00,
  319. },
  320. { /* Init_SRA0_SRAF */
  321. 0x00, 0xFF, 0xBF, 0xFF, 0xFF, 0xED, 0xED, 0xED,
  322. 0x7B, 0xFF, 0xFF, 0xFF, 0xBF, 0xEF, 0xBF, 0xDF,
  323. },
  324. { /* Init_GR00_GR08 */
  325. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  326. 0xFF,
  327. },
  328. { /* Init_AR00_AR14 */
  329. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  330. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  331. 0x41, 0x00, 0x0F, 0x00, 0x00,
  332. },
  333. { /* Init_CR00_CR18 */
  334. 0x7F, 0x63, 0x63, 0x00, 0x68, 0x18, 0x72, 0xF0,
  335. 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  336. 0x58, 0x0C, 0x57, 0x64, 0x40, 0x57, 0x00, 0xE3,
  337. 0xFF,
  338. },
  339. { /* Init_CR30_CR4D */
  340. 0x00, 0x00, 0x00, 0x00, 0x00, 0x33, 0x03, 0x20,
  341. 0x00, 0x00, 0x00, 0x40, 0x00, 0xE7, 0xBF, 0xFD,
  342. 0x7F, 0x63, 0x00, 0x69, 0x18, 0x72, 0x57, 0x00,
  343. 0x58, 0x0C, 0xE0, 0x20, 0x63, 0x57,
  344. },
  345. { /* Init_CR90_CRA7 */
  346. 0x56, 0x4B, 0x5E, 0x55, 0x86, 0x9D, 0x8E, 0xAA,
  347. 0xDB, 0x2A, 0xDF, 0x33, 0x00, 0x00, 0x18, 0x00,
  348. 0x20, 0x1F, 0x1A, 0x19, 0x0F, 0x0F, 0x0F, 0x00,
  349. },
  350. },
  351. { /* mode#3: 800 x 600 24Bpp 60Hz */
  352. 800, 600, 24, 60,
  353. 0x2B,
  354. { /* Init_SR0_SR4 */
  355. 0x03, 0x01, 0x0F, 0x03, 0x0E,
  356. },
  357. { /* Init_SR10_SR24 */
  358. 0xFF, 0xBE, 0xEE, 0xFF, 0x00, 0x0E, 0x17, 0x2C,
  359. 0x99, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  360. 0xC4, 0x30, 0x02, 0x01, 0x01,
  361. },
  362. { /* Init_SR30_SR75 */
  363. 0x36, 0x03, 0x20, 0x09, 0xC0, 0x36, 0x36, 0x36,
  364. 0x36, 0x36, 0x36, 0x36, 0x00, 0x00, 0x03, 0xFF,
  365. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x18, 0x00, 0xFC,
  366. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x36, 0x36, 0x36,
  367. 0x04, 0x48, 0x83, 0x63, 0x68, 0x72, 0x57, 0x58,
  368. 0x04, 0x55, 0x59, 0x36, 0x36, 0x00, 0x00, 0x36,
  369. 0x01, 0x80, 0x7E, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  370. 0x50, 0x03, 0x74, 0x14, 0x1C, 0x85, 0x35, 0x13,
  371. 0x02, 0x45, 0x30, 0x30, 0x40, 0x20,
  372. },
  373. { /* Init_SR80_SR93 */
  374. 0xFF, 0x07, 0x00, 0x6F, 0x7F, 0x7F, 0xFF, 0x36,
  375. 0xF7, 0x00, 0x00, 0x00, 0xEF, 0xFF, 0x36, 0x36,
  376. 0x00, 0x00, 0x00, 0x00,
  377. },
  378. { /* Init_SRA0_SRAF */
  379. 0x00, 0xFF, 0xBF, 0xFF, 0xFF, 0xED, 0xED, 0xED,
  380. 0x7B, 0xFF, 0xFF, 0xFF, 0xBF, 0xEF, 0xBF, 0xDF,
  381. },
  382. { /* Init_GR00_GR08 */
  383. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  384. 0xFF,
  385. },
  386. { /* Init_AR00_AR14 */
  387. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  388. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  389. 0x41, 0x00, 0x0F, 0x00, 0x00,
  390. },
  391. { /* Init_CR00_CR18 */
  392. 0x7F, 0x63, 0x63, 0x00, 0x68, 0x18, 0x72, 0xF0,
  393. 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  394. 0x58, 0x0C, 0x57, 0x64, 0x40, 0x57, 0x00, 0xE3,
  395. 0xFF,
  396. },
  397. { /* Init_CR30_CR4D */
  398. 0x00, 0x00, 0x00, 0x00, 0x00, 0x33, 0x03, 0x20,
  399. 0x00, 0x00, 0x00, 0x40, 0x00, 0xE7, 0xBF, 0xFD,
  400. 0x7F, 0x63, 0x00, 0x69, 0x18, 0x72, 0x57, 0x00,
  401. 0x58, 0x0C, 0xE0, 0x20, 0x63, 0x57,
  402. },
  403. { /* Init_CR90_CRA7 */
  404. 0x56, 0x4B, 0x5E, 0x55, 0x86, 0x9D, 0x8E, 0xAA,
  405. 0xDB, 0x2A, 0xDF, 0x33, 0x00, 0x00, 0x18, 0x00,
  406. 0x20, 0x1F, 0x1A, 0x19, 0x0F, 0x0F, 0x0F, 0x00,
  407. },
  408. },
  409. { /* mode#7: 800 x 600 32Bpp 60Hz */
  410. 800, 600, 32, 60,
  411. /* Init_MISC */
  412. 0x2B,
  413. { /* Init_SR0_SR4 */
  414. 0x03, 0x01, 0x0F, 0x03, 0x0E,
  415. },
  416. { /* Init_SR10_SR24 */
  417. 0xFF, 0xBE, 0xEE, 0xFF, 0x00, 0x0E, 0x17, 0x2C,
  418. 0x99, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
  419. 0xC4, 0x30, 0x02, 0x01, 0x01,
  420. },
  421. { /* Init_SR30_SR75 */
  422. 0x34, 0x03, 0x20, 0x09, 0xC0, 0x24, 0x24, 0x24,
  423. 0x24, 0x24, 0x24, 0x24, 0x00, 0x00, 0x03, 0xFF,
  424. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x38, 0x00, 0xFC,
  425. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x24, 0x24, 0x24,
  426. 0x04, 0x48, 0x83, 0x63, 0x68, 0x72, 0x57, 0x58,
  427. 0x04, 0x55, 0x59, 0x24, 0x24, 0x00, 0x00, 0x24,
  428. 0x01, 0x80, 0x7A, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  429. 0x50, 0x03, 0x74, 0x14, 0x1C, 0x85, 0x35, 0x13,
  430. 0x02, 0x45, 0x30, 0x35, 0x40, 0x20,
  431. },
  432. { /* Init_SR80_SR93 */
  433. 0x00, 0x00, 0x00, 0x6F, 0x7F, 0x7F, 0xFF, 0x24,
  434. 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x24, 0x24,
  435. 0x00, 0x00, 0x00, 0x00,
  436. },
  437. { /* Init_SRA0_SRAF */
  438. 0x00, 0xFF, 0xBF, 0xFF, 0xFF, 0xED, 0xED, 0xED,
  439. 0x7B, 0xFF, 0xFF, 0xFF, 0xBF, 0xEF, 0xBF, 0xDF,
  440. },
  441. { /* Init_GR00_GR08 */
  442. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  443. 0xFF,
  444. },
  445. { /* Init_AR00_AR14 */
  446. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  447. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  448. 0x41, 0x00, 0x0F, 0x00, 0x00,
  449. },
  450. { /* Init_CR00_CR18 */
  451. 0x7F, 0x63, 0x63, 0x00, 0x68, 0x18, 0x72, 0xF0,
  452. 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  453. 0x58, 0x0C, 0x57, 0x64, 0x40, 0x57, 0x00, 0xE3,
  454. 0xFF,
  455. },
  456. { /* Init_CR30_CR4D */
  457. 0x00, 0x00, 0x00, 0x00, 0x00, 0x33, 0x03, 0x20,
  458. 0x00, 0x00, 0x00, 0x40, 0x00, 0xE7, 0xBF, 0xFD,
  459. 0x7F, 0x63, 0x00, 0x69, 0x18, 0x72, 0x57, 0x00,
  460. 0x58, 0x0C, 0xE0, 0x20, 0x63, 0x57,
  461. },
  462. { /* Init_CR90_CRA7 */
  463. 0x56, 0x4B, 0x5E, 0x55, 0x86, 0x9D, 0x8E, 0xAA,
  464. 0xDB, 0x2A, 0xDF, 0x33, 0x00, 0x00, 0x18, 0x00,
  465. 0x20, 0x1F, 0x1A, 0x19, 0x0F, 0x0F, 0x0F, 0x00,
  466. },
  467. },
  468. /* We use 1024x768 table to light 1024x600 panel for lemote */
  469. { /* mode#4: 1024 x 600 16Bpp 60Hz */
  470. 1024, 600, 16, 60,
  471. /* Init_MISC */
  472. 0xEB,
  473. { /* Init_SR0_SR4 */
  474. 0x03, 0x01, 0x0F, 0x00, 0x0E,
  475. },
  476. { /* Init_SR10_SR24 */
  477. 0xC8, 0x40, 0x14, 0x60, 0x00, 0x0A, 0x17, 0x20,
  478. 0x51, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
  479. 0xC4, 0x30, 0x02, 0x00, 0x01,
  480. },
  481. { /* Init_SR30_SR75 */
  482. 0x22, 0x03, 0x24, 0x09, 0xC0, 0x22, 0x22, 0x22,
  483. 0x22, 0x22, 0x22, 0x22, 0x00, 0x00, 0x03, 0xFF,
  484. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x18, 0x00, 0xFC,
  485. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x22, 0x22, 0x22,
  486. 0x06, 0x68, 0xA7, 0x7F, 0x83, 0x24, 0xFF, 0x03,
  487. 0x00, 0x60, 0x59, 0x22, 0x22, 0x00, 0x00, 0x22,
  488. 0x01, 0x80, 0x7A, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  489. 0x50, 0x03, 0x16, 0x02, 0x0D, 0x82, 0x09, 0x02,
  490. 0x04, 0x45, 0x3F, 0x30, 0x40, 0x20,
  491. },
  492. { /* Init_SR80_SR93 */
  493. 0xFF, 0x07, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0x3A,
  494. 0xF7, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x3A, 0x3A,
  495. 0x00, 0x00, 0x00, 0x00,
  496. },
  497. { /* Init_SRA0_SRAF */
  498. 0x00, 0xFB, 0x9F, 0x01, 0x00, 0xED, 0xED, 0xED,
  499. 0x7B, 0xFB, 0xFF, 0xFF, 0x97, 0xEF, 0xBF, 0xDF,
  500. },
  501. { /* Init_GR00_GR08 */
  502. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  503. 0xFF,
  504. },
  505. { /* Init_AR00_AR14 */
  506. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  507. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  508. 0x41, 0x00, 0x0F, 0x00, 0x00,
  509. },
  510. { /* Init_CR00_CR18 */
  511. 0xA3, 0x7F, 0x7F, 0x00, 0x85, 0x16, 0x24, 0xF5,
  512. 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  513. 0x03, 0x09, 0xFF, 0x80, 0x40, 0xFF, 0x00, 0xE3,
  514. 0xFF,
  515. },
  516. { /* Init_CR30_CR4D */
  517. 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x02, 0x20,
  518. 0x00, 0x00, 0x00, 0x40, 0x00, 0xFF, 0xBF, 0xFF,
  519. 0xA3, 0x7F, 0x00, 0x82, 0x0b, 0x6f, 0x57, 0x00,
  520. 0x5c, 0x0f, 0xE0, 0xe0, 0x7F, 0x57,
  521. },
  522. { /* Init_CR90_CRA7 */
  523. 0x55, 0xD9, 0x5D, 0xE1, 0x86, 0x1B, 0x8E, 0x26,
  524. 0xDA, 0x8D, 0xDE, 0x94, 0x00, 0x00, 0x18, 0x00,
  525. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x15, 0x03,
  526. },
  527. },
  528. { /* mode#5: 1024 x 768 24Bpp 60Hz */
  529. 1024, 768, 24, 60,
  530. /* Init_MISC */
  531. 0xEB,
  532. { /* Init_SR0_SR4 */
  533. 0x03, 0x01, 0x0F, 0x03, 0x0E,
  534. },
  535. { /* Init_SR10_SR24 */
  536. 0xF3, 0xB6, 0xC0, 0xDD, 0x00, 0x0E, 0x17, 0x2C,
  537. 0x99, 0x02, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
  538. 0xC4, 0x30, 0x02, 0x01, 0x01,
  539. },
  540. { /* Init_SR30_SR75 */
  541. 0x38, 0x03, 0x20, 0x09, 0xC0, 0x3A, 0x3A, 0x3A,
  542. 0x3A, 0x3A, 0x3A, 0x3A, 0x00, 0x00, 0x03, 0xFF,
  543. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x18, 0x00, 0xFC,
  544. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x00, 0x00, 0x3A,
  545. 0x06, 0x68, 0xA7, 0x7F, 0x83, 0x24, 0xFF, 0x03,
  546. 0x00, 0x60, 0x59, 0x3A, 0x3A, 0x00, 0x00, 0x3A,
  547. 0x01, 0x80, 0x7E, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  548. 0x50, 0x03, 0x74, 0x14, 0x3B, 0x0D, 0x09, 0x02,
  549. 0x04, 0x45, 0x30, 0x30, 0x40, 0x20,
  550. },
  551. { /* Init_SR80_SR93 */
  552. 0xFF, 0x07, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0x3A,
  553. 0xF7, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x3A, 0x3A,
  554. 0x00, 0x00, 0x00, 0x00,
  555. },
  556. { /* Init_SRA0_SRAF */
  557. 0x00, 0xFB, 0x9F, 0x01, 0x00, 0xED, 0xED, 0xED,
  558. 0x7B, 0xFB, 0xFF, 0xFF, 0x97, 0xEF, 0xBF, 0xDF,
  559. },
  560. { /* Init_GR00_GR08 */
  561. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  562. 0xFF,
  563. },
  564. { /* Init_AR00_AR14 */
  565. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  566. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  567. 0x41, 0x00, 0x0F, 0x00, 0x00,
  568. },
  569. { /* Init_CR00_CR18 */
  570. 0xA3, 0x7F, 0x7F, 0x00, 0x85, 0x16, 0x24, 0xF5,
  571. 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  572. 0x03, 0x09, 0xFF, 0x80, 0x40, 0xFF, 0x00, 0xE3,
  573. 0xFF,
  574. },
  575. { /* Init_CR30_CR4D */
  576. 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x02, 0x20,
  577. 0x00, 0x00, 0x00, 0x40, 0x00, 0xFF, 0xBF, 0xFF,
  578. 0xA3, 0x7F, 0x00, 0x86, 0x15, 0x24, 0xFF, 0x00,
  579. 0x01, 0x07, 0xE5, 0x20, 0x7F, 0xFF,
  580. },
  581. { /* Init_CR90_CRA7 */
  582. 0x55, 0xD9, 0x5D, 0xE1, 0x86, 0x1B, 0x8E, 0x26,
  583. 0xDA, 0x8D, 0xDE, 0x94, 0x00, 0x00, 0x18, 0x00,
  584. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x15, 0x03,
  585. },
  586. },
  587. { /* mode#4: 1024 x 768 32Bpp 60Hz */
  588. 1024, 768, 32, 60,
  589. /* Init_MISC */
  590. 0xEB,
  591. { /* Init_SR0_SR4 */
  592. 0x03, 0x01, 0x0F, 0x03, 0x0E,
  593. },
  594. { /* Init_SR10_SR24 */
  595. 0xF3, 0xB6, 0xC0, 0xDD, 0x00, 0x0E, 0x17, 0x2C,
  596. 0x99, 0x02, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
  597. 0xC4, 0x32, 0x02, 0x01, 0x01,
  598. },
  599. { /* Init_SR30_SR75 */
  600. 0x38, 0x03, 0x20, 0x09, 0xC0, 0x3A, 0x3A, 0x3A,
  601. 0x3A, 0x3A, 0x3A, 0x3A, 0x00, 0x00, 0x03, 0xFF,
  602. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x18, 0x00, 0xFC,
  603. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x00, 0x00, 0x3A,
  604. 0x06, 0x68, 0xA7, 0x7F, 0x83, 0x24, 0xFF, 0x03,
  605. 0x00, 0x60, 0x59, 0x3A, 0x3A, 0x00, 0x00, 0x3A,
  606. 0x01, 0x80, 0x7E, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  607. 0x50, 0x03, 0x74, 0x14, 0x3B, 0x0D, 0x09, 0x02,
  608. 0x04, 0x45, 0x30, 0x30, 0x40, 0x20,
  609. },
  610. { /* Init_SR80_SR93 */
  611. 0xFF, 0x07, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0x3A,
  612. 0xF7, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x3A, 0x3A,
  613. 0x00, 0x00, 0x00, 0x00,
  614. },
  615. { /* Init_SRA0_SRAF */
  616. 0x00, 0xFB, 0x9F, 0x01, 0x00, 0xED, 0xED, 0xED,
  617. 0x7B, 0xFB, 0xFF, 0xFF, 0x97, 0xEF, 0xBF, 0xDF,
  618. },
  619. { /* Init_GR00_GR08 */
  620. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  621. 0xFF,
  622. },
  623. { /* Init_AR00_AR14 */
  624. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  625. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  626. 0x41, 0x00, 0x0F, 0x00, 0x00,
  627. },
  628. { /* Init_CR00_CR18 */
  629. 0xA3, 0x7F, 0x7F, 0x00, 0x85, 0x16, 0x24, 0xF5,
  630. 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  631. 0x03, 0x09, 0xFF, 0x80, 0x40, 0xFF, 0x00, 0xE3,
  632. 0xFF,
  633. },
  634. { /* Init_CR30_CR4D */
  635. 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x02, 0x20,
  636. 0x00, 0x00, 0x00, 0x40, 0x00, 0xFF, 0xBF, 0xFF,
  637. 0xA3, 0x7F, 0x00, 0x86, 0x15, 0x24, 0xFF, 0x00,
  638. 0x01, 0x07, 0xE5, 0x20, 0x7F, 0xFF,
  639. },
  640. { /* Init_CR90_CRA7 */
  641. 0x55, 0xD9, 0x5D, 0xE1, 0x86, 0x1B, 0x8E, 0x26,
  642. 0xDA, 0x8D, 0xDE, 0x94, 0x00, 0x00, 0x18, 0x00,
  643. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x15, 0x03,
  644. },
  645. },
  646. { /* mode#6: 320 x 240 16Bpp 60Hz */
  647. 320, 240, 16, 60,
  648. /* Init_MISC */
  649. 0xEB,
  650. { /* Init_SR0_SR4 */
  651. 0x03, 0x01, 0x0F, 0x03, 0x0E,
  652. },
  653. { /* Init_SR10_SR24 */
  654. 0xF3, 0xB6, 0xC0, 0xDD, 0x00, 0x0E, 0x17, 0x2C,
  655. 0x99, 0x02, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
  656. 0xC4, 0x32, 0x02, 0x01, 0x01,
  657. },
  658. { /* Init_SR30_SR75 */
  659. 0x38, 0x03, 0x20, 0x09, 0xC0, 0x3A, 0x3A, 0x3A,
  660. 0x3A, 0x3A, 0x3A, 0x3A, 0x00, 0x00, 0x03, 0xFF,
  661. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x18, 0x00, 0xFC,
  662. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x00, 0x00, 0x3A,
  663. 0x06, 0x68, 0xA7, 0x7F, 0x83, 0x24, 0xFF, 0x03,
  664. 0x00, 0x60, 0x59, 0x3A, 0x3A, 0x00, 0x00, 0x3A,
  665. 0x01, 0x80, 0x7E, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  666. 0x50, 0x03, 0x74, 0x14, 0x08, 0x43, 0x08, 0x43,
  667. 0x04, 0x45, 0x30, 0x30, 0x40, 0x20,
  668. },
  669. { /* Init_SR80_SR93 */
  670. 0xFF, 0x07, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0x3A,
  671. 0xF7, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x3A, 0x3A,
  672. 0x00, 0x00, 0x00, 0x00,
  673. },
  674. { /* Init_SRA0_SRAF */
  675. 0x00, 0xFB, 0x9F, 0x01, 0x00, 0xED, 0xED, 0xED,
  676. 0x7B, 0xFB, 0xFF, 0xFF, 0x97, 0xEF, 0xBF, 0xDF,
  677. },
  678. { /* Init_GR00_GR08 */
  679. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  680. 0xFF,
  681. },
  682. { /* Init_AR00_AR14 */
  683. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  684. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  685. 0x41, 0x00, 0x0F, 0x00, 0x00,
  686. },
  687. { /* Init_CR00_CR18 */
  688. 0xA3, 0x7F, 0x7F, 0x00, 0x85, 0x16, 0x24, 0xF5,
  689. 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  690. 0x03, 0x09, 0xFF, 0x80, 0x40, 0xFF, 0x00, 0xE3,
  691. 0xFF,
  692. },
  693. { /* Init_CR30_CR4D */
  694. 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x02, 0x20,
  695. 0x00, 0x00, 0x30, 0x40, 0x00, 0xFF, 0xBF, 0xFF,
  696. 0x2E, 0x27, 0x00, 0x2b, 0x0c, 0x0F, 0xEF, 0x00,
  697. 0xFe, 0x0f, 0x01, 0xC0, 0x27, 0xEF,
  698. },
  699. { /* Init_CR90_CRA7 */
  700. 0x55, 0xD9, 0x5D, 0xE1, 0x86, 0x1B, 0x8E, 0x26,
  701. 0xDA, 0x8D, 0xDE, 0x94, 0x00, 0x00, 0x18, 0x00,
  702. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x15, 0x03,
  703. },
  704. },
  705. { /* mode#8: 320 x 240 32Bpp 60Hz */
  706. 320, 240, 32, 60,
  707. /* Init_MISC */
  708. 0xEB,
  709. { /* Init_SR0_SR4 */
  710. 0x03, 0x01, 0x0F, 0x03, 0x0E,
  711. },
  712. { /* Init_SR10_SR24 */
  713. 0xF3, 0xB6, 0xC0, 0xDD, 0x00, 0x0E, 0x17, 0x2C,
  714. 0x99, 0x02, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
  715. 0xC4, 0x32, 0x02, 0x01, 0x01,
  716. },
  717. { /* Init_SR30_SR75 */
  718. 0x38, 0x03, 0x20, 0x09, 0xC0, 0x3A, 0x3A, 0x3A,
  719. 0x3A, 0x3A, 0x3A, 0x3A, 0x00, 0x00, 0x03, 0xFF,
  720. 0x00, 0xFC, 0x00, 0x00, 0x20, 0x18, 0x00, 0xFC,
  721. 0x20, 0x0C, 0x44, 0x20, 0x00, 0x00, 0x00, 0x3A,
  722. 0x06, 0x68, 0xA7, 0x7F, 0x83, 0x24, 0xFF, 0x03,
  723. 0x00, 0x60, 0x59, 0x3A, 0x3A, 0x00, 0x00, 0x3A,
  724. 0x01, 0x80, 0x7E, 0x1A, 0x1A, 0x00, 0x00, 0x00,
  725. 0x50, 0x03, 0x74, 0x14, 0x08, 0x43, 0x08, 0x43,
  726. 0x04, 0x45, 0x30, 0x30, 0x40, 0x20,
  727. },
  728. { /* Init_SR80_SR93 */
  729. 0xFF, 0x07, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0x3A,
  730. 0xF7, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x3A, 0x3A,
  731. 0x00, 0x00, 0x00, 0x00,
  732. },
  733. { /* Init_SRA0_SRAF */
  734. 0x00, 0xFB, 0x9F, 0x01, 0x00, 0xED, 0xED, 0xED,
  735. 0x7B, 0xFB, 0xFF, 0xFF, 0x97, 0xEF, 0xBF, 0xDF,
  736. },
  737. { /* Init_GR00_GR08 */
  738. 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x0F,
  739. 0xFF,
  740. },
  741. { /* Init_AR00_AR14 */
  742. 0x00, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07,
  743. 0x08, 0x09, 0x0A, 0x0B, 0x0C, 0x0D, 0x0E, 0x0F,
  744. 0x41, 0x00, 0x0F, 0x00, 0x00,
  745. },
  746. { /* Init_CR00_CR18 */
  747. 0xA3, 0x7F, 0x7F, 0x00, 0x85, 0x16, 0x24, 0xF5,
  748. 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
  749. 0x03, 0x09, 0xFF, 0x80, 0x40, 0xFF, 0x00, 0xE3,
  750. 0xFF,
  751. },
  752. { /* Init_CR30_CR4D */
  753. 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x02, 0x20,
  754. 0x00, 0x00, 0x30, 0x40, 0x00, 0xFF, 0xBF, 0xFF,
  755. 0x2E, 0x27, 0x00, 0x2b, 0x0c, 0x0F, 0xEF, 0x00,
  756. 0xFe, 0x0f, 0x01, 0xC0, 0x27, 0xEF,
  757. },
  758. { /* Init_CR90_CRA7 */
  759. 0x55, 0xD9, 0x5D, 0xE1, 0x86, 0x1B, 0x8E, 0x26,
  760. 0xDA, 0x8D, 0xDE, 0x94, 0x00, 0x00, 0x18, 0x00,
  761. 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x15, 0x03,
  762. },
  763. },
  764. };
  765. #define numVGAModes ARRAY_SIZE(VGAMode)