18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0-or-later */
28c2ecf20Sopenharmony_ci/*
38c2ecf20Sopenharmony_ci * SiS 300/305/540/630(S)/730(S),
48c2ecf20Sopenharmony_ci * SiS 315[E|PRO]/550/[M]65x/[M]66x[F|M|G]X/[M]74x[GX]/330/[M]76x[GX],
58c2ecf20Sopenharmony_ci * XGI V3XT/V5/V8, Z7
68c2ecf20Sopenharmony_ci * frame buffer driver for Linux kernels >=2.4.14 and >=2.6.3
78c2ecf20Sopenharmony_ci *
88c2ecf20Sopenharmony_ci * Copyright (C) 2001-2005 Thomas Winischhofer, Vienna, Austria.
98c2ecf20Sopenharmony_ci */
108c2ecf20Sopenharmony_ci
118c2ecf20Sopenharmony_ci#ifndef _SISFB_MAIN
128c2ecf20Sopenharmony_ci#define _SISFB_MAIN
138c2ecf20Sopenharmony_ci
148c2ecf20Sopenharmony_ci#include "vstruct.h"
158c2ecf20Sopenharmony_ci#include "sis.h"
168c2ecf20Sopenharmony_ci
178c2ecf20Sopenharmony_ci/* Fbcon stuff */
188c2ecf20Sopenharmony_cistatic struct fb_var_screeninfo my_default_var = {
198c2ecf20Sopenharmony_ci	.xres            = 0,
208c2ecf20Sopenharmony_ci	.yres            = 0,
218c2ecf20Sopenharmony_ci	.xres_virtual    = 0,
228c2ecf20Sopenharmony_ci	.yres_virtual    = 0,
238c2ecf20Sopenharmony_ci	.xoffset         = 0,
248c2ecf20Sopenharmony_ci	.yoffset         = 0,
258c2ecf20Sopenharmony_ci	.bits_per_pixel  = 0,
268c2ecf20Sopenharmony_ci	.grayscale       = 0,
278c2ecf20Sopenharmony_ci	.red             = {0, 8, 0},
288c2ecf20Sopenharmony_ci	.green           = {0, 8, 0},
298c2ecf20Sopenharmony_ci	.blue            = {0, 8, 0},
308c2ecf20Sopenharmony_ci	.transp          = {0, 0, 0},
318c2ecf20Sopenharmony_ci	.nonstd          = 0,
328c2ecf20Sopenharmony_ci	.activate        = FB_ACTIVATE_NOW,
338c2ecf20Sopenharmony_ci	.height          = -1,
348c2ecf20Sopenharmony_ci	.width           = -1,
358c2ecf20Sopenharmony_ci	.accel_flags     = 0,
368c2ecf20Sopenharmony_ci	.pixclock        = 0,
378c2ecf20Sopenharmony_ci	.left_margin     = 0,
388c2ecf20Sopenharmony_ci	.right_margin    = 0,
398c2ecf20Sopenharmony_ci	.upper_margin    = 0,
408c2ecf20Sopenharmony_ci	.lower_margin    = 0,
418c2ecf20Sopenharmony_ci	.hsync_len       = 0,
428c2ecf20Sopenharmony_ci	.vsync_len       = 0,
438c2ecf20Sopenharmony_ci	.sync            = 0,
448c2ecf20Sopenharmony_ci	.vmode           = FB_VMODE_NONINTERLACED,
458c2ecf20Sopenharmony_ci};
468c2ecf20Sopenharmony_ci
478c2ecf20Sopenharmony_ci#define MODE_INDEX_NONE           0  /* index for mode=none */
488c2ecf20Sopenharmony_ci
498c2ecf20Sopenharmony_ci/* Boot-time parameters */
508c2ecf20Sopenharmony_cistatic int sisfb_off = 0;
518c2ecf20Sopenharmony_cistatic int sisfb_parm_mem = 0;
528c2ecf20Sopenharmony_cistatic int sisfb_accel = -1;
538c2ecf20Sopenharmony_cistatic int sisfb_ypan = -1;
548c2ecf20Sopenharmony_cistatic int sisfb_max = -1;
558c2ecf20Sopenharmony_cistatic int sisfb_userom = 1;
568c2ecf20Sopenharmony_cistatic int sisfb_useoem = -1;
578c2ecf20Sopenharmony_cistatic int sisfb_mode_idx = -1;               /* Use a default mode if we are inside the kernel */
588c2ecf20Sopenharmony_cistatic int sisfb_parm_rate = -1;
598c2ecf20Sopenharmony_cistatic int sisfb_crt1off = 0;
608c2ecf20Sopenharmony_cistatic int sisfb_forcecrt1 = -1;
618c2ecf20Sopenharmony_cistatic int sisfb_crt2type  = -1;	/* CRT2 type (for overriding autodetection) */
628c2ecf20Sopenharmony_cistatic int sisfb_crt2flags = 0;
638c2ecf20Sopenharmony_cistatic int sisfb_pdc = 0xff;
648c2ecf20Sopenharmony_cistatic int sisfb_pdca = 0xff;
658c2ecf20Sopenharmony_cistatic int sisfb_scalelcd = -1;
668c2ecf20Sopenharmony_cistatic int sisfb_specialtiming = CUT_NONE;
678c2ecf20Sopenharmony_cistatic int sisfb_lvdshl = -1;
688c2ecf20Sopenharmony_cistatic int sisfb_dstn = 0;
698c2ecf20Sopenharmony_cistatic int sisfb_fstn = 0;
708c2ecf20Sopenharmony_cistatic int sisfb_tvplug = -1;		/* Tv plug type (for overriding autodetection) */
718c2ecf20Sopenharmony_cistatic int sisfb_tvstd  = -1;
728c2ecf20Sopenharmony_cistatic int sisfb_tvxposoffset = 0;
738c2ecf20Sopenharmony_cistatic int sisfb_tvyposoffset = 0;
748c2ecf20Sopenharmony_cistatic int sisfb_nocrt2rate = 0;
758c2ecf20Sopenharmony_ci#if !defined(__i386__) && !defined(__x86_64__)
768c2ecf20Sopenharmony_cistatic int sisfb_resetcard = 0;
778c2ecf20Sopenharmony_cistatic int sisfb_videoram = 0;
788c2ecf20Sopenharmony_ci#endif
798c2ecf20Sopenharmony_ci
808c2ecf20Sopenharmony_ci/* List of supported chips */
818c2ecf20Sopenharmony_cistatic struct sisfb_chip_info {
828c2ecf20Sopenharmony_ci	int		chip;
838c2ecf20Sopenharmony_ci	int		vgaengine;
848c2ecf20Sopenharmony_ci	int		mni;
858c2ecf20Sopenharmony_ci	int		hwcursor_size;
868c2ecf20Sopenharmony_ci	int		CRT2_write_enable;
878c2ecf20Sopenharmony_ci	const char	*chip_name;
888c2ecf20Sopenharmony_ci} sisfb_chip_info[] = {
898c2ecf20Sopenharmony_ci	{ SIS_300,    SIS_300_VGA, 0, HW_CURSOR_AREA_SIZE_300 * 2, SIS_CRT2_WENABLE_300, "SiS 300/305" },
908c2ecf20Sopenharmony_ci	{ SIS_540,    SIS_300_VGA, 0, HW_CURSOR_AREA_SIZE_300 * 2, SIS_CRT2_WENABLE_300, "SiS 540" },
918c2ecf20Sopenharmony_ci	{ SIS_630,    SIS_300_VGA, 0, HW_CURSOR_AREA_SIZE_300 * 2, SIS_CRT2_WENABLE_300, "SiS 630" },
928c2ecf20Sopenharmony_ci	{ SIS_315H,   SIS_315_VGA, 1, HW_CURSOR_AREA_SIZE_315 * 4, SIS_CRT2_WENABLE_315, "SiS 315H" },
938c2ecf20Sopenharmony_ci	{ SIS_315,    SIS_315_VGA, 1, HW_CURSOR_AREA_SIZE_315 * 4, SIS_CRT2_WENABLE_315, "SiS 315" },
948c2ecf20Sopenharmony_ci	{ SIS_315PRO, SIS_315_VGA, 1, HW_CURSOR_AREA_SIZE_315 * 4, SIS_CRT2_WENABLE_315, "SiS 315PRO" },
958c2ecf20Sopenharmony_ci	{ SIS_550,    SIS_315_VGA, 1, HW_CURSOR_AREA_SIZE_315 * 4, SIS_CRT2_WENABLE_315, "SiS 55x" },
968c2ecf20Sopenharmony_ci	{ SIS_650,    SIS_315_VGA, 1, HW_CURSOR_AREA_SIZE_315 * 4, SIS_CRT2_WENABLE_315, "SiS 650" },
978c2ecf20Sopenharmony_ci	{ SIS_330,    SIS_315_VGA, 1, HW_CURSOR_AREA_SIZE_315 * 4, SIS_CRT2_WENABLE_315, "SiS 330" },
988c2ecf20Sopenharmony_ci	{ SIS_660,    SIS_315_VGA, 1, HW_CURSOR_AREA_SIZE_315 * 4, SIS_CRT2_WENABLE_315, "SiS 660" },
998c2ecf20Sopenharmony_ci	{ XGI_20,     SIS_315_VGA, 1, HW_CURSOR_AREA_SIZE_315 * 4, SIS_CRT2_WENABLE_315, "XGI Z7" },
1008c2ecf20Sopenharmony_ci	{ XGI_40,     SIS_315_VGA, 1, HW_CURSOR_AREA_SIZE_315 * 4, SIS_CRT2_WENABLE_315, "XGI V3XT/V5/V8" },
1018c2ecf20Sopenharmony_ci};
1028c2ecf20Sopenharmony_ci
1038c2ecf20Sopenharmony_cistatic struct pci_device_id sisfb_pci_table[] = {
1048c2ecf20Sopenharmony_ci#ifdef CONFIG_FB_SIS_300
1058c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_300,     PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0},
1068c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_540_VGA, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 1},
1078c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_630_VGA, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 2},
1088c2ecf20Sopenharmony_ci#endif
1098c2ecf20Sopenharmony_ci#ifdef CONFIG_FB_SIS_315
1108c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_315H,    PCI_ANY_ID, PCI_ANY_ID, 0, 0, 3},
1118c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_315,     PCI_ANY_ID, PCI_ANY_ID, 0, 0, 4},
1128c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_315PRO,  PCI_ANY_ID, PCI_ANY_ID, 0, 0, 5},
1138c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_550_VGA, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 6},
1148c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_650_VGA, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 7},
1158c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_330,     PCI_ANY_ID, PCI_ANY_ID, 0, 0, 8},
1168c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_SI, PCI_DEVICE_ID_SI_660_VGA, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 9},
1178c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_XGI,PCI_DEVICE_ID_XGI_20,     PCI_ANY_ID, PCI_ANY_ID, 0, 0,10},
1188c2ecf20Sopenharmony_ci	{ PCI_VENDOR_ID_XGI,PCI_DEVICE_ID_XGI_40,     PCI_ANY_ID, PCI_ANY_ID, 0, 0,11},
1198c2ecf20Sopenharmony_ci#endif
1208c2ecf20Sopenharmony_ci	{ 0 }
1218c2ecf20Sopenharmony_ci};
1228c2ecf20Sopenharmony_ci
1238c2ecf20Sopenharmony_ciMODULE_DEVICE_TABLE(pci, sisfb_pci_table);
1248c2ecf20Sopenharmony_ci
1258c2ecf20Sopenharmony_cistatic struct sis_video_info *card_list = NULL;
1268c2ecf20Sopenharmony_ci
1278c2ecf20Sopenharmony_ci/* The memory heap is now handled card-wise, by using
1288c2ecf20Sopenharmony_ci   sis_malloc_new/sis_free_new. However, the DRM does
1298c2ecf20Sopenharmony_ci   not do this yet. Until it does, we keep a "global"
1308c2ecf20Sopenharmony_ci   heap which is actually the first card's one.
1318c2ecf20Sopenharmony_ci */
1328c2ecf20Sopenharmony_cistatic struct SIS_HEAP	*sisfb_heap;
1338c2ecf20Sopenharmony_ci
1348c2ecf20Sopenharmony_ci#define MD_SIS300 1
1358c2ecf20Sopenharmony_ci#define MD_SIS315 2
1368c2ecf20Sopenharmony_ci
1378c2ecf20Sopenharmony_ci/* Mode table */
1388c2ecf20Sopenharmony_cistatic const struct _sisbios_mode {
1398c2ecf20Sopenharmony_ci	char name[15];
1408c2ecf20Sopenharmony_ci	u8  mode_no[2];
1418c2ecf20Sopenharmony_ci	u16 vesa_mode_no_1;  /* "SiS defined" VESA mode number */
1428c2ecf20Sopenharmony_ci	u16 vesa_mode_no_2;  /* Real VESA mode numbers */
1438c2ecf20Sopenharmony_ci	u16 xres;
1448c2ecf20Sopenharmony_ci	u16 yres;
1458c2ecf20Sopenharmony_ci	u16 bpp;
1468c2ecf20Sopenharmony_ci	u16 rate_idx;
1478c2ecf20Sopenharmony_ci	u16 cols;
1488c2ecf20Sopenharmony_ci	u16 rows;
1498c2ecf20Sopenharmony_ci	u8  chipset;
1508c2ecf20Sopenharmony_ci} sisbios_mode[] = {
1518c2ecf20Sopenharmony_ci/*0*/	{"none",         {0xff,0xff}, 0x0000, 0x0000,    0,    0,  0, 0,   0,  0, MD_SIS300|MD_SIS315},
1528c2ecf20Sopenharmony_ci	{"320x200x8",    {0x59,0x59}, 0x0138, 0x0000,  320,  200,  8, 1,  40, 12, MD_SIS300|MD_SIS315},
1538c2ecf20Sopenharmony_ci	{"320x200x16",   {0x41,0x41}, 0x010e, 0x0000,  320,  200, 16, 1,  40, 12, MD_SIS300|MD_SIS315},
1548c2ecf20Sopenharmony_ci	{"320x200x24",   {0x4f,0x4f}, 0x0000, 0x0000,  320,  200, 32, 1,  40, 12, MD_SIS300|MD_SIS315},  /* That's for people who mix up color- and fb depth */
1558c2ecf20Sopenharmony_ci	{"320x200x32",   {0x4f,0x4f}, 0x0000, 0x0000,  320,  200, 32, 1,  40, 12, MD_SIS300|MD_SIS315},
1568c2ecf20Sopenharmony_ci	{"320x240x8",    {0x50,0x50}, 0x0132, 0x0000,  320,  240,  8, 1,  40, 15, MD_SIS300|MD_SIS315},
1578c2ecf20Sopenharmony_ci	{"320x240x16",   {0x56,0x56}, 0x0135, 0x0000,  320,  240, 16, 1,  40, 15, MD_SIS300|MD_SIS315},
1588c2ecf20Sopenharmony_ci	{"320x240x24",   {0x53,0x53}, 0x0000, 0x0000,  320,  240, 32, 1,  40, 15, MD_SIS300|MD_SIS315},
1598c2ecf20Sopenharmony_ci	{"320x240x32",   {0x53,0x53}, 0x0000, 0x0000,  320,  240, 32, 1,  40, 15, MD_SIS300|MD_SIS315},
1608c2ecf20Sopenharmony_ci#define MODE_FSTN_8	9
1618c2ecf20Sopenharmony_ci#define MODE_FSTN_16	10
1628c2ecf20Sopenharmony_ci	{"320x240x8",    {0x5a,0x5a}, 0x0132, 0x0000,  320,  240,  8, 1,  40, 15,           MD_SIS315},  /* FSTN */
1638c2ecf20Sopenharmony_ci/*10*/	{"320x240x16",   {0x5b,0x5b}, 0x0135, 0x0000,  320,  240, 16, 1,  40, 15,           MD_SIS315},  /* FSTN */
1648c2ecf20Sopenharmony_ci	{"400x300x8",    {0x51,0x51}, 0x0133, 0x0000,  400,  300,  8, 1,  50, 18, MD_SIS300|MD_SIS315},
1658c2ecf20Sopenharmony_ci	{"400x300x16",   {0x57,0x57}, 0x0136, 0x0000,  400,  300, 16, 1,  50, 18, MD_SIS300|MD_SIS315},
1668c2ecf20Sopenharmony_ci	{"400x300x24",   {0x54,0x54}, 0x0000, 0x0000,  400,  300, 32, 1,  50, 18, MD_SIS300|MD_SIS315},
1678c2ecf20Sopenharmony_ci	{"400x300x32",   {0x54,0x54}, 0x0000, 0x0000,  400,  300, 32, 1,  50, 18, MD_SIS300|MD_SIS315},
1688c2ecf20Sopenharmony_ci	{"512x384x8",    {0x52,0x52}, 0x0000, 0x0000,  512,  384,  8, 1,  64, 24, MD_SIS300|MD_SIS315},
1698c2ecf20Sopenharmony_ci	{"512x384x16",   {0x58,0x58}, 0x0000, 0x0000,  512,  384, 16, 1,  64, 24, MD_SIS300|MD_SIS315},
1708c2ecf20Sopenharmony_ci	{"512x384x24",   {0x5c,0x5c}, 0x0000, 0x0000,  512,  384, 32, 1,  64, 24, MD_SIS300|MD_SIS315},
1718c2ecf20Sopenharmony_ci	{"512x384x32",   {0x5c,0x5c}, 0x0000, 0x0000,  512,  384, 32, 1,  64, 24, MD_SIS300|MD_SIS315},
1728c2ecf20Sopenharmony_ci	{"640x400x8",    {0x2f,0x2f}, 0x0000, 0x0000,  640,  400,  8, 1,  80, 25, MD_SIS300|MD_SIS315},
1738c2ecf20Sopenharmony_ci/*20*/	{"640x400x16",   {0x5d,0x5d}, 0x0000, 0x0000,  640,  400, 16, 1,  80, 25, MD_SIS300|MD_SIS315},
1748c2ecf20Sopenharmony_ci	{"640x400x24",   {0x5e,0x5e}, 0x0000, 0x0000,  640,  400, 32, 1,  80, 25, MD_SIS300|MD_SIS315},
1758c2ecf20Sopenharmony_ci	{"640x400x32",   {0x5e,0x5e}, 0x0000, 0x0000,  640,  400, 32, 1,  80, 25, MD_SIS300|MD_SIS315},
1768c2ecf20Sopenharmony_ci	{"640x480x8",    {0x2e,0x2e}, 0x0101, 0x0101,  640,  480,  8, 1,  80, 30, MD_SIS300|MD_SIS315},
1778c2ecf20Sopenharmony_ci	{"640x480x16",   {0x44,0x44}, 0x0111, 0x0111,  640,  480, 16, 1,  80, 30, MD_SIS300|MD_SIS315},
1788c2ecf20Sopenharmony_ci	{"640x480x24",   {0x62,0x62}, 0x013a, 0x0112,  640,  480, 32, 1,  80, 30, MD_SIS300|MD_SIS315},
1798c2ecf20Sopenharmony_ci	{"640x480x32",   {0x62,0x62}, 0x013a, 0x0112,  640,  480, 32, 1,  80, 30, MD_SIS300|MD_SIS315},
1808c2ecf20Sopenharmony_ci	{"720x480x8",    {0x31,0x31}, 0x0000, 0x0000,  720,  480,  8, 1,  90, 30, MD_SIS300|MD_SIS315},
1818c2ecf20Sopenharmony_ci	{"720x480x16",   {0x33,0x33}, 0x0000, 0x0000,  720,  480, 16, 1,  90, 30, MD_SIS300|MD_SIS315},
1828c2ecf20Sopenharmony_ci	{"720x480x24",   {0x35,0x35}, 0x0000, 0x0000,  720,  480, 32, 1,  90, 30, MD_SIS300|MD_SIS315},
1838c2ecf20Sopenharmony_ci/*30*/	{"720x480x32",   {0x35,0x35}, 0x0000, 0x0000,  720,  480, 32, 1,  90, 30, MD_SIS300|MD_SIS315},
1848c2ecf20Sopenharmony_ci	{"720x576x8",    {0x32,0x32}, 0x0000, 0x0000,  720,  576,  8, 1,  90, 36, MD_SIS300|MD_SIS315},
1858c2ecf20Sopenharmony_ci	{"720x576x16",   {0x34,0x34}, 0x0000, 0x0000,  720,  576, 16, 1,  90, 36, MD_SIS300|MD_SIS315},
1868c2ecf20Sopenharmony_ci	{"720x576x24",   {0x36,0x36}, 0x0000, 0x0000,  720,  576, 32, 1,  90, 36, MD_SIS300|MD_SIS315},
1878c2ecf20Sopenharmony_ci	{"720x576x32",   {0x36,0x36}, 0x0000, 0x0000,  720,  576, 32, 1,  90, 36, MD_SIS300|MD_SIS315},
1888c2ecf20Sopenharmony_ci	{"768x576x8",    {0x5f,0x5f}, 0x0000, 0x0000,  768,  576,  8, 1,  96, 36, MD_SIS300|MD_SIS315},
1898c2ecf20Sopenharmony_ci	{"768x576x16",   {0x60,0x60}, 0x0000, 0x0000,  768,  576, 16, 1,  96, 36, MD_SIS300|MD_SIS315},
1908c2ecf20Sopenharmony_ci	{"768x576x24",   {0x61,0x61}, 0x0000, 0x0000,  768,  576, 32, 1,  96, 36, MD_SIS300|MD_SIS315},
1918c2ecf20Sopenharmony_ci	{"768x576x32",   {0x61,0x61}, 0x0000, 0x0000,  768,  576, 32, 1,  96, 36, MD_SIS300|MD_SIS315},
1928c2ecf20Sopenharmony_ci	{"800x480x8",    {0x70,0x70}, 0x0000, 0x0000,  800,  480,  8, 1, 100, 30, MD_SIS300|MD_SIS315},
1938c2ecf20Sopenharmony_ci/*40*/	{"800x480x16",   {0x7a,0x7a}, 0x0000, 0x0000,  800,  480, 16, 1, 100, 30, MD_SIS300|MD_SIS315},
1948c2ecf20Sopenharmony_ci	{"800x480x24",   {0x76,0x76}, 0x0000, 0x0000,  800,  480, 32, 1, 100, 30, MD_SIS300|MD_SIS315},
1958c2ecf20Sopenharmony_ci	{"800x480x32",   {0x76,0x76}, 0x0000, 0x0000,  800,  480, 32, 1, 100, 30, MD_SIS300|MD_SIS315},
1968c2ecf20Sopenharmony_ci#define DEFAULT_MODE		43 /* index for 800x600x8 */
1978c2ecf20Sopenharmony_ci#define DEFAULT_LCDMODE		43 /* index for 800x600x8 */
1988c2ecf20Sopenharmony_ci#define DEFAULT_TVMODE		43 /* index for 800x600x8 */
1998c2ecf20Sopenharmony_ci	{"800x600x8",    {0x30,0x30}, 0x0103, 0x0103,  800,  600,  8, 2, 100, 37, MD_SIS300|MD_SIS315},
2008c2ecf20Sopenharmony_ci	{"800x600x16",   {0x47,0x47}, 0x0114, 0x0114,  800,  600, 16, 2, 100, 37, MD_SIS300|MD_SIS315},
2018c2ecf20Sopenharmony_ci	{"800x600x24",   {0x63,0x63}, 0x013b, 0x0115,  800,  600, 32, 2, 100, 37, MD_SIS300|MD_SIS315},
2028c2ecf20Sopenharmony_ci	{"800x600x32",   {0x63,0x63}, 0x013b, 0x0115,  800,  600, 32, 2, 100, 37, MD_SIS300|MD_SIS315},
2038c2ecf20Sopenharmony_ci	{"848x480x8",    {0x39,0x39}, 0x0000, 0x0000,  848,  480,  8, 2, 106, 30, MD_SIS300|MD_SIS315},
2048c2ecf20Sopenharmony_ci#define DEFAULT_MODE_848	48
2058c2ecf20Sopenharmony_ci	{"848x480x16",   {0x3b,0x3b}, 0x0000, 0x0000,  848,  480, 16, 2, 106, 30, MD_SIS300|MD_SIS315},
2068c2ecf20Sopenharmony_ci	{"848x480x24",   {0x3e,0x3e}, 0x0000, 0x0000,  848,  480, 32, 2, 106, 30, MD_SIS300|MD_SIS315},
2078c2ecf20Sopenharmony_ci/*50*/	{"848x480x32",   {0x3e,0x3e}, 0x0000, 0x0000,  848,  480, 32, 2, 106, 30, MD_SIS300|MD_SIS315},
2088c2ecf20Sopenharmony_ci	{"856x480x8",    {0x3f,0x3f}, 0x0000, 0x0000,  856,  480,  8, 2, 107, 30, MD_SIS300|MD_SIS315},
2098c2ecf20Sopenharmony_ci#define DEFAULT_MODE_856	52
2108c2ecf20Sopenharmony_ci	{"856x480x16",   {0x42,0x42}, 0x0000, 0x0000,  856,  480, 16, 2, 107, 30, MD_SIS300|MD_SIS315},
2118c2ecf20Sopenharmony_ci	{"856x480x24",   {0x45,0x45}, 0x0000, 0x0000,  856,  480, 32, 2, 107, 30, MD_SIS300|MD_SIS315},
2128c2ecf20Sopenharmony_ci	{"856x480x32",   {0x45,0x45}, 0x0000, 0x0000,  856,  480, 32, 2, 107, 30, MD_SIS300|MD_SIS315},
2138c2ecf20Sopenharmony_ci	{"960x540x8",    {0x1d,0x1d}, 0x0000, 0x0000,  960,  540,  8, 1, 120, 33,           MD_SIS315},
2148c2ecf20Sopenharmony_ci	{"960x540x16",   {0x1e,0x1e}, 0x0000, 0x0000,  960,  540, 16, 1, 120, 33,           MD_SIS315},
2158c2ecf20Sopenharmony_ci	{"960x540x24",   {0x1f,0x1f}, 0x0000, 0x0000,  960,  540, 32, 1, 120, 33,           MD_SIS315},
2168c2ecf20Sopenharmony_ci	{"960x540x32",   {0x1f,0x1f}, 0x0000, 0x0000,  960,  540, 32, 1, 120, 33,           MD_SIS315},
2178c2ecf20Sopenharmony_ci	{"960x600x8",    {0x20,0x20}, 0x0000, 0x0000,  960,  600,  8, 1, 120, 37,           MD_SIS315},
2188c2ecf20Sopenharmony_ci/*60*/	{"960x600x16",   {0x21,0x21}, 0x0000, 0x0000,  960,  600, 16, 1, 120, 37,           MD_SIS315},
2198c2ecf20Sopenharmony_ci	{"960x600x24",   {0x22,0x22}, 0x0000, 0x0000,  960,  600, 32, 1, 120, 37,           MD_SIS315},
2208c2ecf20Sopenharmony_ci	{"960x600x32",   {0x22,0x22}, 0x0000, 0x0000,  960,  600, 32, 1, 120, 37,           MD_SIS315},
2218c2ecf20Sopenharmony_ci	{"1024x576x8",   {0x71,0x71}, 0x0000, 0x0000, 1024,  576,  8, 1, 128, 36, MD_SIS300|MD_SIS315},
2228c2ecf20Sopenharmony_ci	{"1024x576x16",  {0x74,0x74}, 0x0000, 0x0000, 1024,  576, 16, 1, 128, 36, MD_SIS300|MD_SIS315},
2238c2ecf20Sopenharmony_ci	{"1024x576x24",  {0x77,0x77}, 0x0000, 0x0000, 1024,  576, 32, 1, 128, 36, MD_SIS300|MD_SIS315},
2248c2ecf20Sopenharmony_ci	{"1024x576x32",  {0x77,0x77}, 0x0000, 0x0000, 1024,  576, 32, 1, 128, 36, MD_SIS300|MD_SIS315},
2258c2ecf20Sopenharmony_ci	{"1024x600x8",   {0x20,0x20}, 0x0000, 0x0000, 1024,  600,  8, 1, 128, 37, MD_SIS300          },
2268c2ecf20Sopenharmony_ci	{"1024x600x16",  {0x21,0x21}, 0x0000, 0x0000, 1024,  600, 16, 1, 128, 37, MD_SIS300          },
2278c2ecf20Sopenharmony_ci	{"1024x600x24",  {0x22,0x22}, 0x0000, 0x0000, 1024,  600, 32, 1, 128, 37, MD_SIS300          },
2288c2ecf20Sopenharmony_ci/*70*/	{"1024x600x32",  {0x22,0x22}, 0x0000, 0x0000, 1024,  600, 32, 1, 128, 37, MD_SIS300          },
2298c2ecf20Sopenharmony_ci	{"1024x768x8",   {0x38,0x38}, 0x0105, 0x0105, 1024,  768,  8, 2, 128, 48, MD_SIS300|MD_SIS315},
2308c2ecf20Sopenharmony_ci	{"1024x768x16",  {0x4a,0x4a}, 0x0117, 0x0117, 1024,  768, 16, 2, 128, 48, MD_SIS300|MD_SIS315},
2318c2ecf20Sopenharmony_ci	{"1024x768x24",  {0x64,0x64}, 0x013c, 0x0118, 1024,  768, 32, 2, 128, 48, MD_SIS300|MD_SIS315},
2328c2ecf20Sopenharmony_ci	{"1024x768x32",  {0x64,0x64}, 0x013c, 0x0118, 1024,  768, 32, 2, 128, 48, MD_SIS300|MD_SIS315},
2338c2ecf20Sopenharmony_ci	{"1152x768x8",   {0x23,0x23}, 0x0000, 0x0000, 1152,  768,  8, 1, 144, 48, MD_SIS300          },
2348c2ecf20Sopenharmony_ci	{"1152x768x16",  {0x24,0x24}, 0x0000, 0x0000, 1152,  768, 16, 1, 144, 48, MD_SIS300          },
2358c2ecf20Sopenharmony_ci	{"1152x768x24",  {0x25,0x25}, 0x0000, 0x0000, 1152,  768, 32, 1, 144, 48, MD_SIS300          },
2368c2ecf20Sopenharmony_ci	{"1152x768x32",  {0x25,0x25}, 0x0000, 0x0000, 1152,  768, 32, 1, 144, 48, MD_SIS300          },
2378c2ecf20Sopenharmony_ci	{"1152x864x8",   {0x29,0x29}, 0x0000, 0x0000, 1152,  864,  8, 1, 144, 54, MD_SIS300|MD_SIS315},
2388c2ecf20Sopenharmony_ci/*80*/	{"1152x864x16",  {0x2a,0x2a}, 0x0000, 0x0000, 1152,  864, 16, 1, 144, 54, MD_SIS300|MD_SIS315},
2398c2ecf20Sopenharmony_ci	{"1152x864x24",  {0x2b,0x2b}, 0x0000, 0x0000, 1152,  864, 32, 1, 144, 54, MD_SIS300|MD_SIS315},
2408c2ecf20Sopenharmony_ci	{"1152x864x32",  {0x2b,0x2b}, 0x0000, 0x0000, 1152,  864, 32, 1, 144, 54, MD_SIS300|MD_SIS315},
2418c2ecf20Sopenharmony_ci	{"1280x720x8",   {0x79,0x79}, 0x0000, 0x0000, 1280,  720,  8, 1, 160, 45, MD_SIS300|MD_SIS315},
2428c2ecf20Sopenharmony_ci	{"1280x720x16",  {0x75,0x75}, 0x0000, 0x0000, 1280,  720, 16, 1, 160, 45, MD_SIS300|MD_SIS315},
2438c2ecf20Sopenharmony_ci	{"1280x720x24",  {0x78,0x78}, 0x0000, 0x0000, 1280,  720, 32, 1, 160, 45, MD_SIS300|MD_SIS315},
2448c2ecf20Sopenharmony_ci	{"1280x720x32",  {0x78,0x78}, 0x0000, 0x0000, 1280,  720, 32, 1, 160, 45, MD_SIS300|MD_SIS315},
2458c2ecf20Sopenharmony_ci	{"1280x768x8",   {0x55,0x23}, 0x0000, 0x0000, 1280,  768,  8, 1, 160, 48, MD_SIS300|MD_SIS315},
2468c2ecf20Sopenharmony_ci	{"1280x768x16",  {0x5a,0x24}, 0x0000, 0x0000, 1280,  768, 16, 1, 160, 48, MD_SIS300|MD_SIS315},
2478c2ecf20Sopenharmony_ci	{"1280x768x24",  {0x5b,0x25}, 0x0000, 0x0000, 1280,  768, 32, 1, 160, 48, MD_SIS300|MD_SIS315},
2488c2ecf20Sopenharmony_ci/*90*/	{"1280x768x32",  {0x5b,0x25}, 0x0000, 0x0000, 1280,  768, 32, 1, 160, 48, MD_SIS300|MD_SIS315},
2498c2ecf20Sopenharmony_ci	{"1280x800x8",   {0x14,0x14}, 0x0000, 0x0000, 1280,  800,  8, 1, 160, 50,           MD_SIS315},
2508c2ecf20Sopenharmony_ci	{"1280x800x16",  {0x15,0x15}, 0x0000, 0x0000, 1280,  800, 16, 1, 160, 50,           MD_SIS315},
2518c2ecf20Sopenharmony_ci	{"1280x800x24",  {0x16,0x16}, 0x0000, 0x0000, 1280,  800, 32, 1, 160, 50,           MD_SIS315},
2528c2ecf20Sopenharmony_ci	{"1280x800x32",  {0x16,0x16}, 0x0000, 0x0000, 1280,  800, 32, 1, 160, 50,           MD_SIS315},
2538c2ecf20Sopenharmony_ci	{"1280x854x8",   {0x14,0x14}, 0x0000, 0x0000, 1280,  854,  8, 1, 160, 53,           MD_SIS315},
2548c2ecf20Sopenharmony_ci	{"1280x854x16",  {0x15,0x15}, 0x0000, 0x0000, 1280,  854, 16, 1, 160, 53,           MD_SIS315},
2558c2ecf20Sopenharmony_ci	{"1280x854x24",  {0x16,0x16}, 0x0000, 0x0000, 1280,  854, 32, 1, 160, 53,           MD_SIS315},
2568c2ecf20Sopenharmony_ci	{"1280x854x32",  {0x16,0x16}, 0x0000, 0x0000, 1280,  854, 32, 1, 160, 53,           MD_SIS315},
2578c2ecf20Sopenharmony_ci	{"1280x960x8",   {0x7c,0x7c}, 0x0000, 0x0000, 1280,  960,  8, 1, 160, 60, MD_SIS300|MD_SIS315},
2588c2ecf20Sopenharmony_ci/*100*/	{"1280x960x16",  {0x7d,0x7d}, 0x0000, 0x0000, 1280,  960, 16, 1, 160, 60, MD_SIS300|MD_SIS315},
2598c2ecf20Sopenharmony_ci	{"1280x960x24",  {0x7e,0x7e}, 0x0000, 0x0000, 1280,  960, 32, 1, 160, 60, MD_SIS300|MD_SIS315},
2608c2ecf20Sopenharmony_ci	{"1280x960x32",  {0x7e,0x7e}, 0x0000, 0x0000, 1280,  960, 32, 1, 160, 60, MD_SIS300|MD_SIS315},
2618c2ecf20Sopenharmony_ci	{"1280x1024x8",  {0x3a,0x3a}, 0x0107, 0x0107, 1280, 1024,  8, 2, 160, 64, MD_SIS300|MD_SIS315},
2628c2ecf20Sopenharmony_ci	{"1280x1024x16", {0x4d,0x4d}, 0x011a, 0x011a, 1280, 1024, 16, 2, 160, 64, MD_SIS300|MD_SIS315},
2638c2ecf20Sopenharmony_ci	{"1280x1024x24", {0x65,0x65}, 0x013d, 0x011b, 1280, 1024, 32, 2, 160, 64, MD_SIS300|MD_SIS315},
2648c2ecf20Sopenharmony_ci	{"1280x1024x32", {0x65,0x65}, 0x013d, 0x011b, 1280, 1024, 32, 2, 160, 64, MD_SIS300|MD_SIS315},
2658c2ecf20Sopenharmony_ci	{"1360x768x8",   {0x48,0x48}, 0x0000, 0x0000, 1360,  768,  8, 1, 170, 48, MD_SIS300|MD_SIS315},
2668c2ecf20Sopenharmony_ci	{"1360x768x16",  {0x4b,0x4b}, 0x0000, 0x0000, 1360,  768, 16, 1, 170, 48, MD_SIS300|MD_SIS315},
2678c2ecf20Sopenharmony_ci	{"1360x768x24",  {0x4e,0x4e}, 0x0000, 0x0000, 1360,  768, 32, 1, 170, 48, MD_SIS300|MD_SIS315},
2688c2ecf20Sopenharmony_ci/*110*/	{"1360x768x32",  {0x4e,0x4e}, 0x0000, 0x0000, 1360,  768, 32, 1, 170, 48, MD_SIS300|MD_SIS315},
2698c2ecf20Sopenharmony_ci	{"1360x1024x8",  {0x67,0x67}, 0x0000, 0x0000, 1360, 1024,  8, 1, 170, 64, MD_SIS300          },
2708c2ecf20Sopenharmony_ci#define DEFAULT_MODE_1360	112
2718c2ecf20Sopenharmony_ci	{"1360x1024x16", {0x6f,0x6f}, 0x0000, 0x0000, 1360, 1024, 16, 1, 170, 64, MD_SIS300          },
2728c2ecf20Sopenharmony_ci	{"1360x1024x24", {0x72,0x72}, 0x0000, 0x0000, 1360, 1024, 32, 1, 170, 64, MD_SIS300          },
2738c2ecf20Sopenharmony_ci	{"1360x1024x32", {0x72,0x72}, 0x0000, 0x0000, 1360, 1024, 32, 1, 170, 64, MD_SIS300          },
2748c2ecf20Sopenharmony_ci	{"1400x1050x8",  {0x26,0x26}, 0x0000, 0x0000, 1400, 1050,  8, 1, 175, 65,           MD_SIS315},
2758c2ecf20Sopenharmony_ci	{"1400x1050x16", {0x27,0x27}, 0x0000, 0x0000, 1400, 1050, 16, 1, 175, 65,           MD_SIS315},
2768c2ecf20Sopenharmony_ci	{"1400x1050x24", {0x28,0x28}, 0x0000, 0x0000, 1400, 1050, 32, 1, 175, 65,           MD_SIS315},
2778c2ecf20Sopenharmony_ci	{"1400x1050x32", {0x28,0x28}, 0x0000, 0x0000, 1400, 1050, 32, 1, 175, 65,           MD_SIS315},
2788c2ecf20Sopenharmony_ci	{"1600x1200x8",  {0x3c,0x3c}, 0x0130, 0x011c, 1600, 1200,  8, 1, 200, 75, MD_SIS300|MD_SIS315},
2798c2ecf20Sopenharmony_ci/*120*/	{"1600x1200x16", {0x3d,0x3d}, 0x0131, 0x011e, 1600, 1200, 16, 1, 200, 75, MD_SIS300|MD_SIS315},
2808c2ecf20Sopenharmony_ci	{"1600x1200x24", {0x66,0x66}, 0x013e, 0x011f, 1600, 1200, 32, 1, 200, 75, MD_SIS300|MD_SIS315},
2818c2ecf20Sopenharmony_ci	{"1600x1200x32", {0x66,0x66}, 0x013e, 0x011f, 1600, 1200, 32, 1, 200, 75, MD_SIS300|MD_SIS315},
2828c2ecf20Sopenharmony_ci	{"1680x1050x8",  {0x17,0x17}, 0x0000, 0x0000, 1680, 1050,  8, 1, 210, 65,           MD_SIS315},
2838c2ecf20Sopenharmony_ci	{"1680x1050x16", {0x18,0x18}, 0x0000, 0x0000, 1680, 1050, 16, 1, 210, 65,           MD_SIS315},
2848c2ecf20Sopenharmony_ci	{"1680x1050x24", {0x19,0x19}, 0x0000, 0x0000, 1680, 1050, 32, 1, 210, 65,           MD_SIS315},
2858c2ecf20Sopenharmony_ci	{"1680x1050x32", {0x19,0x19}, 0x0000, 0x0000, 1680, 1050, 32, 1, 210, 65,           MD_SIS315},
2868c2ecf20Sopenharmony_ci	{"1920x1080x8",  {0x2c,0x2c}, 0x0000, 0x0000, 1920, 1080,  8, 1, 240, 67,           MD_SIS315},
2878c2ecf20Sopenharmony_ci	{"1920x1080x16", {0x2d,0x2d}, 0x0000, 0x0000, 1920, 1080, 16, 1, 240, 67,           MD_SIS315},
2888c2ecf20Sopenharmony_ci	{"1920x1080x24", {0x73,0x73}, 0x0000, 0x0000, 1920, 1080, 32, 1, 240, 67,           MD_SIS315},
2898c2ecf20Sopenharmony_ci/*130*/	{"1920x1080x32", {0x73,0x73}, 0x0000, 0x0000, 1920, 1080, 32, 1, 240, 67,           MD_SIS315},
2908c2ecf20Sopenharmony_ci	{"1920x1440x8",  {0x68,0x68}, 0x013f, 0x0000, 1920, 1440,  8, 1, 240, 75, MD_SIS300|MD_SIS315},
2918c2ecf20Sopenharmony_ci	{"1920x1440x16", {0x69,0x69}, 0x0140, 0x0000, 1920, 1440, 16, 1, 240, 75, MD_SIS300|MD_SIS315},
2928c2ecf20Sopenharmony_ci	{"1920x1440x24", {0x6b,0x6b}, 0x0141, 0x0000, 1920, 1440, 32, 1, 240, 75, MD_SIS300|MD_SIS315},
2938c2ecf20Sopenharmony_ci	{"1920x1440x32", {0x6b,0x6b}, 0x0141, 0x0000, 1920, 1440, 32, 1, 240, 75, MD_SIS300|MD_SIS315},
2948c2ecf20Sopenharmony_ci	{"2048x1536x8",  {0x6c,0x6c}, 0x0000, 0x0000, 2048, 1536,  8, 1, 256, 96,           MD_SIS315},
2958c2ecf20Sopenharmony_ci	{"2048x1536x16", {0x6d,0x6d}, 0x0000, 0x0000, 2048, 1536, 16, 1, 256, 96,           MD_SIS315},
2968c2ecf20Sopenharmony_ci	{"2048x1536x24", {0x6e,0x6e}, 0x0000, 0x0000, 2048, 1536, 32, 1, 256, 96,           MD_SIS315},
2978c2ecf20Sopenharmony_ci	{"2048x1536x32", {0x6e,0x6e}, 0x0000, 0x0000, 2048, 1536, 32, 1, 256, 96,           MD_SIS315},
2988c2ecf20Sopenharmony_ci	{"\0", {0x00,0x00}, 0, 0, 0, 0, 0, 0, 0}
2998c2ecf20Sopenharmony_ci};
3008c2ecf20Sopenharmony_ci
3018c2ecf20Sopenharmony_ci#define SIS_LCD_NUMBER 18
3028c2ecf20Sopenharmony_cistatic struct _sis_lcd_data {
3038c2ecf20Sopenharmony_ci	u32 lcdtype;
3048c2ecf20Sopenharmony_ci	u16 xres;
3058c2ecf20Sopenharmony_ci	u16 yres;
3068c2ecf20Sopenharmony_ci	u8  default_mode_idx;
3078c2ecf20Sopenharmony_ci} sis_lcd_data[] = {
3088c2ecf20Sopenharmony_ci	{ LCD_640x480,    640,  480,  23 },
3098c2ecf20Sopenharmony_ci	{ LCD_800x600,    800,  600,  43 },
3108c2ecf20Sopenharmony_ci	{ LCD_1024x600,  1024,  600,  67 },
3118c2ecf20Sopenharmony_ci	{ LCD_1024x768,  1024,  768,  71 },
3128c2ecf20Sopenharmony_ci	{ LCD_1152x768,  1152,  768,  75 },
3138c2ecf20Sopenharmony_ci	{ LCD_1152x864,  1152,  864,  79 },
3148c2ecf20Sopenharmony_ci	{ LCD_1280x720,  1280,  720,  83 },
3158c2ecf20Sopenharmony_ci	{ LCD_1280x768,  1280,  768,  87 },
3168c2ecf20Sopenharmony_ci	{ LCD_1280x800,  1280,  800,  91 },
3178c2ecf20Sopenharmony_ci	{ LCD_1280x854,  1280,  854,  95 },
3188c2ecf20Sopenharmony_ci	{ LCD_1280x960,  1280,  960,  99 },
3198c2ecf20Sopenharmony_ci	{ LCD_1280x1024, 1280, 1024, 103 },
3208c2ecf20Sopenharmony_ci	{ LCD_1400x1050, 1400, 1050, 115 },
3218c2ecf20Sopenharmony_ci	{ LCD_1680x1050, 1680, 1050, 123 },
3228c2ecf20Sopenharmony_ci	{ LCD_1600x1200, 1600, 1200, 119 },
3238c2ecf20Sopenharmony_ci	{ LCD_320x240_2,  320,  240,   9 },
3248c2ecf20Sopenharmony_ci	{ LCD_320x240_3,  320,  240,   9 },
3258c2ecf20Sopenharmony_ci	{ LCD_320x240,    320,  240,   9 },
3268c2ecf20Sopenharmony_ci};
3278c2ecf20Sopenharmony_ci
3288c2ecf20Sopenharmony_ci/* CR36 evaluation */
3298c2ecf20Sopenharmony_cistatic unsigned short sis300paneltype[] = {
3308c2ecf20Sopenharmony_ci	LCD_UNKNOWN,   LCD_800x600,   LCD_1024x768,  LCD_1280x1024,
3318c2ecf20Sopenharmony_ci	LCD_1280x960,  LCD_640x480,   LCD_1024x600,  LCD_1152x768,
3328c2ecf20Sopenharmony_ci	LCD_UNKNOWN,   LCD_UNKNOWN,   LCD_UNKNOWN,   LCD_UNKNOWN,
3338c2ecf20Sopenharmony_ci	LCD_UNKNOWN,   LCD_UNKNOWN,   LCD_UNKNOWN,   LCD_UNKNOWN
3348c2ecf20Sopenharmony_ci};
3358c2ecf20Sopenharmony_ci
3368c2ecf20Sopenharmony_cistatic unsigned short sis310paneltype[] = {
3378c2ecf20Sopenharmony_ci	LCD_UNKNOWN,   LCD_800x600,   LCD_1024x768,  LCD_1280x1024,
3388c2ecf20Sopenharmony_ci	LCD_640x480,   LCD_1024x600,  LCD_1152x864,  LCD_1280x960,
3398c2ecf20Sopenharmony_ci	LCD_1152x768,  LCD_1400x1050, LCD_1280x768,  LCD_1600x1200,
3408c2ecf20Sopenharmony_ci	LCD_320x240_2, LCD_320x240_3, LCD_UNKNOWN,   LCD_UNKNOWN
3418c2ecf20Sopenharmony_ci};
3428c2ecf20Sopenharmony_ci
3438c2ecf20Sopenharmony_cistatic unsigned short sis661paneltype[] = {
3448c2ecf20Sopenharmony_ci	LCD_UNKNOWN,   LCD_800x600,   LCD_1024x768,  LCD_1280x1024,
3458c2ecf20Sopenharmony_ci	LCD_640x480,   LCD_1024x600,  LCD_1152x864,  LCD_1280x960,
3468c2ecf20Sopenharmony_ci	LCD_1280x854,  LCD_1400x1050, LCD_1280x768,  LCD_1600x1200,
3478c2ecf20Sopenharmony_ci	LCD_1280x800,  LCD_1680x1050, LCD_1280x720,  LCD_UNKNOWN
3488c2ecf20Sopenharmony_ci};
3498c2ecf20Sopenharmony_ci
3508c2ecf20Sopenharmony_ci#define FL_550_DSTN 0x01
3518c2ecf20Sopenharmony_ci#define FL_550_FSTN 0x02
3528c2ecf20Sopenharmony_ci#define FL_300      0x04
3538c2ecf20Sopenharmony_ci#define FL_315      0x08
3548c2ecf20Sopenharmony_ci
3558c2ecf20Sopenharmony_cistatic struct _sis_crt2type {
3568c2ecf20Sopenharmony_ci	char name[32];
3578c2ecf20Sopenharmony_ci	u32 type_no;
3588c2ecf20Sopenharmony_ci	u32 tvplug_no;
3598c2ecf20Sopenharmony_ci	u16 flags;
3608c2ecf20Sopenharmony_ci} sis_crt2type[] __initdata = {
3618c2ecf20Sopenharmony_ci	{"NONE", 	     0, 	-1,                     FL_300|FL_315},
3628c2ecf20Sopenharmony_ci	{"LCD",  	     CRT2_LCD, 	-1,                     FL_300|FL_315},
3638c2ecf20Sopenharmony_ci	{"TV",   	     CRT2_TV, 	-1,                     FL_300|FL_315},
3648c2ecf20Sopenharmony_ci	{"VGA",  	     CRT2_VGA, 	-1,                     FL_300|FL_315},
3658c2ecf20Sopenharmony_ci	{"SVIDEO", 	     CRT2_TV, 	TV_SVIDEO,              FL_300|FL_315},
3668c2ecf20Sopenharmony_ci	{"COMPOSITE", 	     CRT2_TV, 	TV_AVIDEO,              FL_300|FL_315},
3678c2ecf20Sopenharmony_ci	{"CVBS", 	     CRT2_TV, 	TV_AVIDEO,              FL_300|FL_315},
3688c2ecf20Sopenharmony_ci	{"SVIDEO+COMPOSITE", CRT2_TV,   TV_AVIDEO|TV_SVIDEO,    FL_300|FL_315},
3698c2ecf20Sopenharmony_ci	{"COMPOSITE+SVIDEO", CRT2_TV,   TV_AVIDEO|TV_SVIDEO,    FL_300|FL_315},
3708c2ecf20Sopenharmony_ci	{"SVIDEO+CVBS",      CRT2_TV,   TV_AVIDEO|TV_SVIDEO,    FL_300|FL_315},
3718c2ecf20Sopenharmony_ci	{"CVBS+SVIDEO",      CRT2_TV,   TV_AVIDEO|TV_SVIDEO,    FL_300|FL_315},
3728c2ecf20Sopenharmony_ci	{"SCART", 	     CRT2_TV, 	TV_SCART,               FL_300|FL_315},
3738c2ecf20Sopenharmony_ci	{"HIVISION",	     CRT2_TV,   TV_HIVISION,            FL_315},
3748c2ecf20Sopenharmony_ci	{"YPBPR480I",	     CRT2_TV,   TV_YPBPR|TV_YPBPR525I,  FL_315},
3758c2ecf20Sopenharmony_ci	{"YPBPR480P",	     CRT2_TV,   TV_YPBPR|TV_YPBPR525P,  FL_315},
3768c2ecf20Sopenharmony_ci	{"YPBPR720P",	     CRT2_TV,   TV_YPBPR|TV_YPBPR750P,  FL_315},
3778c2ecf20Sopenharmony_ci	{"YPBPR1080I",	     CRT2_TV,   TV_YPBPR|TV_YPBPR1080I, FL_315},
3788c2ecf20Sopenharmony_ci	{"DSTN",             CRT2_LCD,  -1,                     FL_315|FL_550_DSTN},
3798c2ecf20Sopenharmony_ci	{"FSTN",             CRT2_LCD,  -1,                     FL_315|FL_550_FSTN},
3808c2ecf20Sopenharmony_ci	{"\0",  	     -1, 	-1,                     0}
3818c2ecf20Sopenharmony_ci};
3828c2ecf20Sopenharmony_ci
3838c2ecf20Sopenharmony_ci/* TV standard */
3848c2ecf20Sopenharmony_cistatic struct _sis_tvtype {
3858c2ecf20Sopenharmony_ci	char name[6];
3868c2ecf20Sopenharmony_ci	u32 type_no;
3878c2ecf20Sopenharmony_ci} sis_tvtype[] __initdata = {
3888c2ecf20Sopenharmony_ci	{"PAL",  	TV_PAL},
3898c2ecf20Sopenharmony_ci	{"NTSC", 	TV_NTSC},
3908c2ecf20Sopenharmony_ci	{"PALM",  	TV_PAL|TV_PALM},
3918c2ecf20Sopenharmony_ci	{"PALN",  	TV_PAL|TV_PALN},
3928c2ecf20Sopenharmony_ci	{"NTSCJ",  	TV_NTSC|TV_NTSCJ},
3938c2ecf20Sopenharmony_ci	{"\0",   	-1}
3948c2ecf20Sopenharmony_ci};
3958c2ecf20Sopenharmony_ci
3968c2ecf20Sopenharmony_cistatic const struct _sis_vrate {
3978c2ecf20Sopenharmony_ci	u16 idx;
3988c2ecf20Sopenharmony_ci	u16 xres;
3998c2ecf20Sopenharmony_ci	u16 yres;
4008c2ecf20Sopenharmony_ci	u16 refresh;
4018c2ecf20Sopenharmony_ci	bool SiS730valid32bpp;
4028c2ecf20Sopenharmony_ci} sisfb_vrate[] = {
4038c2ecf20Sopenharmony_ci	{1,  320,  200,  70,  true},
4048c2ecf20Sopenharmony_ci	{1,  320,  240,  60,  true},
4058c2ecf20Sopenharmony_ci	{1,  400,  300,  60,  true},
4068c2ecf20Sopenharmony_ci	{1,  512,  384,  60,  true},
4078c2ecf20Sopenharmony_ci	{1,  640,  400,  72,  true},
4088c2ecf20Sopenharmony_ci	{1,  640,  480,  60,  true}, {2,  640,  480,  72,  true}, {3,  640,  480,  75,  true},
4098c2ecf20Sopenharmony_ci	{4,  640,  480,  85,  true}, {5,  640,  480, 100,  true}, {6,  640,  480, 120,  true},
4108c2ecf20Sopenharmony_ci	{7,  640,  480, 160,  true}, {8,  640,  480, 200,  true},
4118c2ecf20Sopenharmony_ci	{1,  720,  480,  60,  true},
4128c2ecf20Sopenharmony_ci	{1,  720,  576,  58,  true},
4138c2ecf20Sopenharmony_ci	{1,  768,  576,  58,  true},
4148c2ecf20Sopenharmony_ci	{1,  800,  480,  60,  true}, {2,  800,  480,  75,  true}, {3,  800,  480,  85,  true},
4158c2ecf20Sopenharmony_ci	{1,  800,  600,  56,  true}, {2,  800,  600,  60,  true}, {3,  800,  600,  72,  true},
4168c2ecf20Sopenharmony_ci	{4,  800,  600,  75,  true}, {5,  800,  600,  85,  true}, {6,  800,  600, 105,  true},
4178c2ecf20Sopenharmony_ci	{7,  800,  600, 120,  true}, {8,  800,  600, 160,  true},
4188c2ecf20Sopenharmony_ci	{1,  848,  480,  39,  true}, {2,  848,  480,  60,  true},
4198c2ecf20Sopenharmony_ci	{1,  856,  480,  39,  true}, {2,  856,  480,  60,  true},
4208c2ecf20Sopenharmony_ci	{1,  960,  540,  60,  true},
4218c2ecf20Sopenharmony_ci	{1,  960,  600,  60,  true},
4228c2ecf20Sopenharmony_ci	{1, 1024,  576,  60,  true}, {2, 1024,  576,  75,  true}, {3, 1024,  576,  85,  true},
4238c2ecf20Sopenharmony_ci	{1, 1024,  600,  60,  true},
4248c2ecf20Sopenharmony_ci	{1, 1024,  768,  43,  true}, {2, 1024,  768,  60,  true}, {3, 1024,  768,  70, false},
4258c2ecf20Sopenharmony_ci	{4, 1024,  768,  75, false}, {5, 1024,  768,  85,  true}, {6, 1024,  768, 100,  true},
4268c2ecf20Sopenharmony_ci	{7, 1024,  768, 120,  true},
4278c2ecf20Sopenharmony_ci	{1, 1152,  768,  60,  true},
4288c2ecf20Sopenharmony_ci	{1, 1152,  864,  60,  true}, {2, 1152,  864,  75,  true}, {3, 1152,  864,  84,  true},
4298c2ecf20Sopenharmony_ci	{1, 1280,  720,  60,  true}, {2, 1280,  720,  75,  true}, {3, 1280,  720,  85,  true},
4308c2ecf20Sopenharmony_ci	{1, 1280,  768,  60,  true},
4318c2ecf20Sopenharmony_ci	{1, 1280,  800,  60,  true},
4328c2ecf20Sopenharmony_ci	{1, 1280,  854,  60,  true},
4338c2ecf20Sopenharmony_ci	{1, 1280,  960,  60,  true}, {2, 1280,  960,  85,  true},
4348c2ecf20Sopenharmony_ci	{1, 1280, 1024,  43,  true}, {2, 1280, 1024,  60,  true}, {3, 1280, 1024,  75,  true},
4358c2ecf20Sopenharmony_ci	{4, 1280, 1024,  85,  true},
4368c2ecf20Sopenharmony_ci	{1, 1360,  768,  60,  true},
4378c2ecf20Sopenharmony_ci	{1, 1360, 1024,  59,  true},
4388c2ecf20Sopenharmony_ci	{1, 1400, 1050,  60,  true}, {2, 1400, 1050,  75,  true},
4398c2ecf20Sopenharmony_ci	{1, 1600, 1200,  60,  true}, {2, 1600, 1200,  65,  true}, {3, 1600, 1200,  70,  true},
4408c2ecf20Sopenharmony_ci	{4, 1600, 1200,  75,  true}, {5, 1600, 1200,  85,  true}, {6, 1600, 1200, 100,  true},
4418c2ecf20Sopenharmony_ci	{7, 1600, 1200, 120,  true},
4428c2ecf20Sopenharmony_ci	{1, 1680, 1050,  60,  true},
4438c2ecf20Sopenharmony_ci	{1, 1920, 1080,  30,  true},
4448c2ecf20Sopenharmony_ci	{1, 1920, 1440,  60,  true}, {2, 1920, 1440,  65,  true}, {3, 1920, 1440,  70,  true},
4458c2ecf20Sopenharmony_ci	{4, 1920, 1440,  75,  true}, {5, 1920, 1440,  85,  true}, {6, 1920, 1440, 100,  true},
4468c2ecf20Sopenharmony_ci	{1, 2048, 1536,  60,  true}, {2, 2048, 1536,  65,  true}, {3, 2048, 1536,  70,  true},
4478c2ecf20Sopenharmony_ci	{4, 2048, 1536,  75,  true}, {5, 2048, 1536,  85,  true},
4488c2ecf20Sopenharmony_ci	{0,    0,    0,   0, false}
4498c2ecf20Sopenharmony_ci};
4508c2ecf20Sopenharmony_ci
4518c2ecf20Sopenharmony_cistatic struct _sisfbddcsmodes {
4528c2ecf20Sopenharmony_ci	u32 mask;
4538c2ecf20Sopenharmony_ci	u16 h;
4548c2ecf20Sopenharmony_ci	u16 v;
4558c2ecf20Sopenharmony_ci	u32 d;
4568c2ecf20Sopenharmony_ci} sisfb_ddcsmodes[] = {
4578c2ecf20Sopenharmony_ci	{ 0x10000, 67, 75, 108000},
4588c2ecf20Sopenharmony_ci	{ 0x08000, 48, 72,  50000},
4598c2ecf20Sopenharmony_ci	{ 0x04000, 46, 75,  49500},
4608c2ecf20Sopenharmony_ci	{ 0x01000, 35, 43,  44900},
4618c2ecf20Sopenharmony_ci	{ 0x00800, 48, 60,  65000},
4628c2ecf20Sopenharmony_ci	{ 0x00400, 56, 70,  75000},
4638c2ecf20Sopenharmony_ci	{ 0x00200, 60, 75,  78800},
4648c2ecf20Sopenharmony_ci	{ 0x00100, 80, 75, 135000},
4658c2ecf20Sopenharmony_ci	{ 0x00020, 31, 60,  25200},
4668c2ecf20Sopenharmony_ci	{ 0x00008, 38, 72,  31500},
4678c2ecf20Sopenharmony_ci	{ 0x00004, 37, 75,  31500},
4688c2ecf20Sopenharmony_ci	{ 0x00002, 35, 56,  36000},
4698c2ecf20Sopenharmony_ci	{ 0x00001, 38, 60,  40000}
4708c2ecf20Sopenharmony_ci};
4718c2ecf20Sopenharmony_ci
4728c2ecf20Sopenharmony_cistatic struct _sisfbddcfmodes {
4738c2ecf20Sopenharmony_ci	u16 x;
4748c2ecf20Sopenharmony_ci	u16 y;
4758c2ecf20Sopenharmony_ci	u16 v;
4768c2ecf20Sopenharmony_ci	u16 h;
4778c2ecf20Sopenharmony_ci	u32 d;
4788c2ecf20Sopenharmony_ci} sisfb_ddcfmodes[] = {
4798c2ecf20Sopenharmony_ci	{ 1280, 1024, 85, 92, 157500},
4808c2ecf20Sopenharmony_ci	{ 1600, 1200, 60, 75, 162000},
4818c2ecf20Sopenharmony_ci	{ 1600, 1200, 65, 82, 175500},
4828c2ecf20Sopenharmony_ci	{ 1600, 1200, 70, 88, 189000},
4838c2ecf20Sopenharmony_ci	{ 1600, 1200, 75, 94, 202500},
4848c2ecf20Sopenharmony_ci	{ 1600, 1200, 85, 107,229500},
4858c2ecf20Sopenharmony_ci	{ 1920, 1440, 60, 90, 234000},
4868c2ecf20Sopenharmony_ci	{ 1920, 1440, 75, 113,297000}
4878c2ecf20Sopenharmony_ci};
4888c2ecf20Sopenharmony_ci
4898c2ecf20Sopenharmony_ci#ifdef CONFIG_FB_SIS_300
4908c2ecf20Sopenharmony_cistatic struct _chswtable {
4918c2ecf20Sopenharmony_ci	u16  subsysVendor;
4928c2ecf20Sopenharmony_ci	u16  subsysCard;
4938c2ecf20Sopenharmony_ci	char *vendorName;
4948c2ecf20Sopenharmony_ci	char *cardName;
4958c2ecf20Sopenharmony_ci} mychswtable[] = {
4968c2ecf20Sopenharmony_ci	{ 0x1631, 0x1002, "Mitachi", "0x1002" },
4978c2ecf20Sopenharmony_ci	{ 0x1071, 0x7521, "Mitac"  , "7521P"  },
4988c2ecf20Sopenharmony_ci	{ 0,      0,      ""       , ""       }
4998c2ecf20Sopenharmony_ci};
5008c2ecf20Sopenharmony_ci#endif
5018c2ecf20Sopenharmony_ci
5028c2ecf20Sopenharmony_cistatic struct _customttable {
5038c2ecf20Sopenharmony_ci	u16   chipID;
5048c2ecf20Sopenharmony_ci	char  *biosversion;
5058c2ecf20Sopenharmony_ci	char  *biosdate;
5068c2ecf20Sopenharmony_ci	u32   bioschksum;
5078c2ecf20Sopenharmony_ci	u16   biosFootprintAddr[5];
5088c2ecf20Sopenharmony_ci	u8    biosFootprintData[5];
5098c2ecf20Sopenharmony_ci	u16   pcisubsysvendor;
5108c2ecf20Sopenharmony_ci	u16   pcisubsyscard;
5118c2ecf20Sopenharmony_ci	char  *vendorName;
5128c2ecf20Sopenharmony_ci	char  *cardName;
5138c2ecf20Sopenharmony_ci	u32   SpecialID;
5148c2ecf20Sopenharmony_ci	char  *optionName;
5158c2ecf20Sopenharmony_ci} mycustomttable[] = {
5168c2ecf20Sopenharmony_ci	{ SIS_630, "2.00.07", "09/27/2002-13:38:25",
5178c2ecf20Sopenharmony_ci	  0x3240A8,
5188c2ecf20Sopenharmony_ci	  { 0x220, 0x227, 0x228, 0x229, 0x0ee },
5198c2ecf20Sopenharmony_ci	  {  0x01,  0xe3,  0x9a,  0x6a,  0xef },
5208c2ecf20Sopenharmony_ci	  0x1039, 0x6300,
5218c2ecf20Sopenharmony_ci	  "Barco", "iQ R200L/300/400", CUT_BARCO1366, "BARCO_1366"
5228c2ecf20Sopenharmony_ci	},
5238c2ecf20Sopenharmony_ci	{ SIS_630, "2.00.07", "09/27/2002-13:38:25",
5248c2ecf20Sopenharmony_ci	  0x323FBD,
5258c2ecf20Sopenharmony_ci	  { 0x220, 0x227, 0x228, 0x229, 0x0ee },
5268c2ecf20Sopenharmony_ci	  {  0x00,  0x5a,  0x64,  0x41,  0xef },
5278c2ecf20Sopenharmony_ci	  0x1039, 0x6300,
5288c2ecf20Sopenharmony_ci	  "Barco", "iQ G200L/300/400/500", CUT_BARCO1024, "BARCO_1024"
5298c2ecf20Sopenharmony_ci	},
5308c2ecf20Sopenharmony_ci	{ SIS_650, "", "",
5318c2ecf20Sopenharmony_ci	  0,
5328c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5338c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5348c2ecf20Sopenharmony_ci	  0x0e11, 0x083c,
5358c2ecf20Sopenharmony_ci	  "Inventec (Compaq)", "3017cl/3045US", CUT_COMPAQ12802, "COMPAQ_1280"
5368c2ecf20Sopenharmony_ci	},
5378c2ecf20Sopenharmony_ci	{ SIS_650, "", "",
5388c2ecf20Sopenharmony_ci	  0,
5398c2ecf20Sopenharmony_ci	  { 0x00c, 0, 0, 0, 0 },
5408c2ecf20Sopenharmony_ci	  { 'e'  , 0, 0, 0, 0 },
5418c2ecf20Sopenharmony_ci	  0x1558, 0x0287,
5428c2ecf20Sopenharmony_ci	  "Clevo", "L285/L287 (Version 1)", CUT_CLEVO1024, "CLEVO_L28X_1"
5438c2ecf20Sopenharmony_ci	},
5448c2ecf20Sopenharmony_ci	{ SIS_650, "", "",
5458c2ecf20Sopenharmony_ci	  0,
5468c2ecf20Sopenharmony_ci	  { 0x00c, 0, 0, 0, 0 },
5478c2ecf20Sopenharmony_ci	  { 'y'  , 0, 0, 0, 0 },
5488c2ecf20Sopenharmony_ci	  0x1558, 0x0287,
5498c2ecf20Sopenharmony_ci	  "Clevo", "L285/L287 (Version 2)", CUT_CLEVO10242, "CLEVO_L28X_2"
5508c2ecf20Sopenharmony_ci	},
5518c2ecf20Sopenharmony_ci	{ SIS_650, "", "",
5528c2ecf20Sopenharmony_ci	  0,
5538c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5548c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5558c2ecf20Sopenharmony_ci	  0x1558, 0x0400,  /* possibly 401 and 402 as well; not panelsize specific (?) */
5568c2ecf20Sopenharmony_ci	  "Clevo", "D400S/D410S/D400H/D410H", CUT_CLEVO1400, "CLEVO_D4X0"
5578c2ecf20Sopenharmony_ci	},
5588c2ecf20Sopenharmony_ci	{ SIS_650, "", "",
5598c2ecf20Sopenharmony_ci	  0,	/* Shift LCD in LCD-via-CRT1 mode */
5608c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5618c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5628c2ecf20Sopenharmony_ci	  0x1558, 0x2263,
5638c2ecf20Sopenharmony_ci	  "Clevo", "D22ES/D27ES", CUT_UNIWILL1024, "CLEVO_D2X0ES"
5648c2ecf20Sopenharmony_ci	},
5658c2ecf20Sopenharmony_ci	{ SIS_650, "", "",
5668c2ecf20Sopenharmony_ci	  0,	/* Shift LCD in LCD-via-CRT1 mode */
5678c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5688c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5698c2ecf20Sopenharmony_ci	  0x1734, 0x101f,
5708c2ecf20Sopenharmony_ci	  "Uniwill", "N243S9", CUT_UNIWILL1024, "UNIWILL_N243S9"
5718c2ecf20Sopenharmony_ci	},
5728c2ecf20Sopenharmony_ci	{ SIS_650, "", "",
5738c2ecf20Sopenharmony_ci	  0,	/* Shift LCD in LCD-via-CRT1 mode */
5748c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5758c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5768c2ecf20Sopenharmony_ci	  0x1584, 0x5103,
5778c2ecf20Sopenharmony_ci	  "Uniwill", "N35BS1", CUT_UNIWILL10242, "UNIWILL_N35BS1"
5788c2ecf20Sopenharmony_ci	},
5798c2ecf20Sopenharmony_ci	{ SIS_650, "1.09.2c", "",  /* Other versions, too? */
5808c2ecf20Sopenharmony_ci	  0,	/* Shift LCD in LCD-via-CRT1 mode */
5818c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5828c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5838c2ecf20Sopenharmony_ci	  0x1019, 0x0f05,
5848c2ecf20Sopenharmony_ci	  "ECS", "A928", CUT_UNIWILL1024, "ECS_A928"
5858c2ecf20Sopenharmony_ci	},
5868c2ecf20Sopenharmony_ci	{ SIS_740, "1.11.27a", "",
5878c2ecf20Sopenharmony_ci	  0,
5888c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5898c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5908c2ecf20Sopenharmony_ci	  0x1043, 0x1612,
5918c2ecf20Sopenharmony_ci	  "Asus", "L3000D/L3500D", CUT_ASUSL3000D, "ASUS_L3X00"
5928c2ecf20Sopenharmony_ci	},
5938c2ecf20Sopenharmony_ci	{ SIS_650, "1.10.9k", "",
5948c2ecf20Sopenharmony_ci	  0,
5958c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5968c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
5978c2ecf20Sopenharmony_ci	  0x1025, 0x0028,
5988c2ecf20Sopenharmony_ci	  "Acer", "Aspire 1700", CUT_ACER1280, "ACER_ASPIRE1700"
5998c2ecf20Sopenharmony_ci	},
6008c2ecf20Sopenharmony_ci	{ SIS_650, "1.10.7w", "",
6018c2ecf20Sopenharmony_ci	  0,
6028c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6038c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6048c2ecf20Sopenharmony_ci	  0x14c0, 0x0012,
6058c2ecf20Sopenharmony_ci	  "Compal", "??? (V1)", CUT_COMPAL1400_1, "COMPAL_1400_1"
6068c2ecf20Sopenharmony_ci	},
6078c2ecf20Sopenharmony_ci	{ SIS_650, "1.10.7x", "",
6088c2ecf20Sopenharmony_ci	  0,
6098c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6108c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6118c2ecf20Sopenharmony_ci	  0x14c0, 0x0012,
6128c2ecf20Sopenharmony_ci	  "Compal", "??? (V2)", CUT_COMPAL1400_2, "COMPAL_1400_2"
6138c2ecf20Sopenharmony_ci	},
6148c2ecf20Sopenharmony_ci	{ SIS_650, "1.10.8o", "",
6158c2ecf20Sopenharmony_ci	  0,	/* For EMI (unknown) */
6168c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6178c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6188c2ecf20Sopenharmony_ci	  0x1043, 0x1612,
6198c2ecf20Sopenharmony_ci	  "Asus", "A2H (V1)", CUT_ASUSA2H_1, "ASUS_A2H_1"
6208c2ecf20Sopenharmony_ci	},
6218c2ecf20Sopenharmony_ci	{ SIS_650, "1.10.8q", "",
6228c2ecf20Sopenharmony_ci	  0,	/* For EMI */
6238c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6248c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6258c2ecf20Sopenharmony_ci	  0x1043, 0x1612,
6268c2ecf20Sopenharmony_ci	  "Asus", "A2H (V2)", CUT_ASUSA2H_2, "ASUS_A2H_2"
6278c2ecf20Sopenharmony_ci	},
6288c2ecf20Sopenharmony_ci	{ 4321, "", "",			/* never autodetected */
6298c2ecf20Sopenharmony_ci	  0,
6308c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6318c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6328c2ecf20Sopenharmony_ci	  0, 0,
6338c2ecf20Sopenharmony_ci	  "Generic", "LVDS/Parallel 848x480", CUT_PANEL848, "PANEL848x480"
6348c2ecf20Sopenharmony_ci	},
6358c2ecf20Sopenharmony_ci	{ 4322, "", "",			/* never autodetected */
6368c2ecf20Sopenharmony_ci	  0,
6378c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6388c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0, 0 },
6398c2ecf20Sopenharmony_ci	  0, 0,
6408c2ecf20Sopenharmony_ci	  "Generic", "LVDS/Parallel 856x480", CUT_PANEL856, "PANEL856x480"
6418c2ecf20Sopenharmony_ci	},
6428c2ecf20Sopenharmony_ci	{ 0, "", "",
6438c2ecf20Sopenharmony_ci	  0,
6448c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0 },
6458c2ecf20Sopenharmony_ci	  { 0, 0, 0, 0 },
6468c2ecf20Sopenharmony_ci	  0, 0,
6478c2ecf20Sopenharmony_ci	  "", "", CUT_NONE, ""
6488c2ecf20Sopenharmony_ci	}
6498c2ecf20Sopenharmony_ci};
6508c2ecf20Sopenharmony_ci
6518c2ecf20Sopenharmony_ci#endif
652