Commit 515b943c authored by Thomas Winischhofer's avatar Thomas Winischhofer

SiS driver update 2004/06/17

parent dccd124b
.\" $XFree86: xc/programs/Xserver/hw/xfree86/drivers/sis/sis.man,v 1.11 2003/08/30 16:13:52 twini Exp $
.\" $XFree86$
.\" $XdotOrg$
.\" shorthand for double quote that works everywhere.
.ds q \N'34'
#ifdef __servername__
#define __myservername__ __servername__
#else
#define __myservername__ XFree86
#endif
#ifdef __xconfigfile__
#define __myxconfigfile__ __xconfigfile__
#else
#define __myxconfigfile__ XF86Config
#endif
.TH SIS __drivermansuffix__ __vendorversion__
.SH NAME
sis \- SiS video driver
......@@ -14,9 +25,9 @@ sis \- SiS video driver
.fi
.SH DESCRIPTION
.B sis
is an XFree86 driver for SiS video chips. The driver is accelerated, and
provides support for 8, 16 and 24 colordepths. XVideo, Render and other
extensions are supported as well.
is an __myservername__ driver for SiS (Silicon Integrated Systems) video chips. The
driver is accelerated, and provides support for colordepths of 8, 16 and 24 bpp.
XVideo, Render and other extensions are supported as well.
.SH SUPPORTED HARDWARE
The
.B sis
......@@ -29,9 +40,10 @@ driver supports PCI and AGP video cards based on the following chipsets:
.B SiS540
.B SiS630/730
.B SiS315/H/PRO
.B SiS550
.B SiS650/651/M650/661FX/M661FX/740/741
.B SiS550/551/552
.B SiS650/651/M650/661FX/M661FX/M661MX/740/741/741GX
.B SiS330 (Xabre)
.B SiS760
.PP
In the following text, the following terms are used:
.PP
......@@ -42,9 +54,10 @@ for SiS5597/5598, 530/620 and 6326/AGP/DVD
for SiS300/305, 540 and 630/730
.PP
.B 315/330 series
for SiS315/H/PRO, 550 and 650/651/M650/661FX/M661FX/740/741, 330
for SiS315, 55x and (M)65x/(M)661xX/74x(GX), 330, 760
.PP
.SH CONFIGURATION DETAILS
Please refer to XF86Config(__filemansuffix__) for general configuration
Please refer to __myxconfigfile__(__filemansuffix__) for general configuration
details. This section only covers configuration details specific to this
driver.
.PP
......@@ -70,37 +83,43 @@ The opposite of HWCursor. Default: SWCursor is off.
.TP
.BI "Option \*qRotate\*q \*qCW\*q"
Rotate the display clockwise. This mode is unaccelerated, and uses
the Shadow Frame Buffer layer.
the Shadow Frame Buffer layer. Using this option disables
the Resize and Rotate extension (RandR).
Default: no rotation.
.TP
.BI "Option \*qRotate\*q \*qCCW\*q"
Rotate the display counterclockwise. This mode is unaccelerated, and
uses the Shadow Frame Buffer layer.
uses the Shadow Frame Buffer layer. Using this option disables
the Resize and Rotate extension (RandR).
Default: no rotation.
.TP
.BI "Option \*qShadowFB\*q \*q" boolean \*q
Enable or disable use of the shadow framebuffer layer.
Default: Shadow framebuffer is off.
.TP
.BI "Option \*qCRT1Gamma\*q \*q" boolean \*q
Enable or disable gamma correction.
Default: Gamma correction is on.
.PP
.I "2. Old series specific information"
.PP
The driver will auto-detect the amount of video memory present for all
these chips, but in the 6326 case, it will limit the memory size to 4MB.
This is because the 6326's 2D engine can only address 4MB. The remaining
memory seems to be intended for 3D texture data, since only the 3D
engine can address RAM above 4MB. However, you can override this forced
these chips, but in the case of the 6326, it will limit the memory size
to 4MB. This is because the 6326's 2D engine can only address 4MB. The
remaining memory seems to be intended for 3D texture data, since only
the 3D engine can address RAM above 4MB. However, you can override this
limitation using the
.B \*qVideoRAM\*q
option in the device section if your board has more than
4MB and you need to use it. However, 2D acceleration, Xvideo and the
HWCursor will be disabled in this case.
option in the Device section if your board has more than 4MB and you
need to use it. However, 2D acceleration, Xvideo and the HWCursor will
be disabled in this case.
.PP
The driver will also auto-detect the maximum dotclock and DAC speed.
If you have problems getting high resolutions because of dot clock
limitations, try using the
.B \*qDacSpeed\*q
option, also in the device section. However, this is not recommended
for the 6326. For this chipset, the driver has two built-in modes for
option, also in the Device section. However, this is not recommended
for the 6326. For this chip, the driver has two built-in modes for
high resolutions which you should use instead. These are named
.B \*qSIS1280x1024-75\*q
and
......@@ -110,13 +129,13 @@ just place them in your Screen section. Example:
.PP
.BI "Modes \*qSIS1600x1200-60\*q \*qSIS1280x1024x75\*q \*q1024x768\*q ...
.PP
1280x1024 is only available at 8, 15 and 16bpp. 1600x1200 is available
at 8bpp only.
Of these modes, 1280x1024 is only available at 8, 15 and 16bpp. 1600x1200
is available at 8bpp only.
.PP
TV support for the 6326
.PP
TV output is supported on the 6326. The driver will auto detect a
TV connected, and in this case add the following modes to the list
TV output is supported for the 6326. The driver will auto detect a
TV connected and in this case add the following modes to the list
of default modes: "PAL800x600", "PAL800x600U", "PAL720x540",
"PAL640x480", "NTSC640x480", "NTSC640x480U" and "NTSC640x400".
Use these modes like the hi-res modes described above.
......@@ -130,11 +149,10 @@ Enable or disable TurboQueue mode. Default: off for SIS530/620, on for
the others
.TP
.BI "Option \*qFastVram\*q \*q" boolean \*q
Enable or disable FastVram mode. Enabling this sets the video RAM timing
to only one cycle per read operation instead of two cycles. Disabling
this will set 2 cycles for read and write operations. Leaving this
option out uses the default.
Default: off for read, on for write.
Enable or disable FastVram mode. Enabling this sets the video RAM timing
to one cycle per read operation instead of two cycles. Disabling this will
set two cycles for read and write operations. Leaving this option out uses
the default, which varies depending on the chipset.
.TP
.BI "Option \*qNoHostBus\*q \*q" boolean \*q
(SiS5597/5598 only). Disable CPU-to-VGA host bus support. This
......@@ -143,39 +161,46 @@ speeds up CPU to video RAM transfers. Default: Host bus is enabled.
.BI "Option \*qNoXVideo\*q \*q" boolean \*q
Disable XV (XVideo) extension support. Default: XVideo is on.
.TP
.BI "Option \*qNoYV12\*q \*q" boolean \*q
Disable YV12 Xv support. This might me required due to hardware bugs in some
chipsets. Disabling YV12 support forces Xv-aware applications to use YUV2 or
XShm for video output.
Default: YV12 support is on.
.TP
.BI "Option \*qTVStandard\*q \*q" string \*q
(6326 only) Possible parameters are
(6326 only) Valid parameters are
.B PAL
or
.B NTSC.
The default is set by a jumper on the card.
.TP
.BI "Option \*qTVXPosOffset\*q \*q" integer \*q
(6326 only) This option allows horizontal relocation the TV output.
The range is from -16 to 16.
(6326 only) This option allows tuning the horizontal position of the image
for TV output. The range is from -16 to 16. Default: 0
.TP
.BI "Option \*qTVYPosOffset\*q \*q" integer \*q
(6326 only) This option allows vertical relocation the TV output.
The range is from -16 to 16.
(6326 only) This option allows tuning the vertical position of the image
for TV output. The range is from -16 to 16. Default: 0
.TP
.BI "Option \*qSIS6326TVEnableYFilter\*q \*q" boolean \*q
(6326 only) This option allows enabling/disabling the Y filter for
(6326 only) This option allows enabling/disabling the Y (chroma) filter for
TV output.
.TP
.BI "Option \*qSIS6326TVAntiFlicker\*q \*q" string \*q
(6326 only) This option allow enabling/disabling the anti flicker
facility for TV output. Possible parameters are
(6326 only) This option allow enabling/disabling the anti flicker facility
for TV output. Possible parameters are
.B OFF, LOW, MED, HIGH
or
.B ADAPTIVE.
By experience,
.B ADAPTIVE
yields the best results.
yields the best results, hence it is the default.
.PP
.I "2. 300 and 315/330 series specific information"
.PP
The 300 and 315/330 series very often come with a video bridge for
controlling LCD and TV output. Hereinafter, the term
The 300 and 315/330 series feature two CRT controllers and very often come
with a video bridge for controlling LCD and TV output. Hereinafter, the
term
.B CRT1
refers to the VGA output of the chip, and
.B CRT2
......@@ -190,7 +215,7 @@ The driver supports the following video bridges:
.B SiS301B(-DH)
.B SiS301C
.B SiS301LV
.B SiS302LV
.B SiS302(E)LV
.PP
Instead of a video bridge, some machines have a
.B LVDS
......@@ -204,13 +229,15 @@ About TV output
.PP
On the SiS301 and the Chrontel 7005, only resolutions up to 800x600
are supported. On all others, resolutions up to 1024x768 are supported.
However, due to a hardware bug, Xvideo might be distorted on SiS video
bridges if running NTSC or PAL-M at 1024x768.
.PP
About XVideo support
.PP
XVideo is supported on all chipsets of both families. However, there
are some differences in hardware features which cause limitations.
The 300 series as well as the SiS550, M650, 651, 661FX, M661FX,
and 741 support two video overlays. The SiS315/H/PRO and 650/740 support
The 300 series as well as the SiS55x, M650, 651, 661FX, M661FX, and
741 support two video overlays. The SiS315/H/PRO, 650/740 and 330 support
only one such overlay. On chips with two overlays, one overlay is used
for CRT1, the other for CRT2. On the other chipsets, the option
.B \*qXvOnCRT2\*q
......@@ -226,7 +253,7 @@ About dual-head support
.PP
Dual head mode has some limitations as regards color depth and
resolution. Due to memory bandwidth limits, CRT1 might have a
reduced refresh rate if running on higher resolutions than
reduced maximum refresh rate if running on higher resolutions than
1280x1024.
.PP
Colordepth 8 is not supported when running in dual head mode.
......@@ -248,24 +275,19 @@ and if this option is either unset or set to
option is set to
.B true
). If either only CRT1 or CRT2 is detected, the driver decides
automatically.
automatically. In Merged Framebuffer mode, this option is ignored.
Default: overlay is used on CRT1
.TP
.BI "Option \*qForceCRT1\*q \*q" boolean \*q
The BIOS detects VGA monitors connected to CRT1 at boot time
and the X driver by default relies on the information passed
by the BIOS. However, some old monitors are not detected
correctly. If this is the case, or if you connected the VGA
monitor after you booted the machine, you may set this
option to
.B true
in order to make the X driver ignore the
information from the BIOS and initialize CRT1 anyway.
Force CRT1 to be on of off. If a monitor is connected, it will be
detected during server start. However, some old monitors are not
detected correctly. In such cases, you may set this option to
.B on
in order to make the driver initialize CRT1 anyway.
If this option is set to
.B false
, the driver will switch
off CRT1 and thus save memory bandwidth.
Default: auto detect CRT1
.B off
, the driver will switch off CRT1.
Default: auto-detect
.TP
.BI "Option \*qForceCRT2Type\*q \*q" string \*q
Force display type to one of:
......@@ -277,6 +299,8 @@ Force display type to one of:
,
.B COMPOSITE
,
.B SVIDEO+COMPOSITE
,
.B SCART
,
.B LCD
......@@ -284,56 +308,54 @@ Force display type to one of:
.B VGA
;
.B NONE
will disable CRT2. The SVIDEO, COMPOSITE and SCART parameters
are for SiS video bridges only and can be used to force the
will disable CRT2. The SVIDEO, COMPOSITE, SVIDEO+COMPOSITE and SCART
parameters are for SiS video bridges only and can be used to force the
driver to use a specific TV output connector (if present).
Default: auto detect.
.TP
.BI "Option \*qPanelDelayCompensation\*q \*q" integer \*q
This option is only for machines with a 300 series chipset
and either a SiS301B-DH video bridge or a LVDS transmitter,
and a 315 series chipset with a SiS30xLV bridge.
Different LCD panels require different delay compensation
values. In most cases, the driver can autodetect this value.
However, due to bad BIOS design this might fail in rare
cases. If your LCD shows small horizontal waves, set the
parameter of this option on the 300 series first to
.B 4
,
.B 32
or
.B 24
and if the problem persists, try using other values between
4 and 60 in steps of 4. On the 315 series, any value can
be set.
.BI "Option \*qCRT2Gamma\*q \*q" boolean \*q
Enable or disable gamma correction for CRT2. Only supported
for SiS video bridges. Default: Gamma correction for CRT2 is on.
.TP
.BI "Option \*qTVStandard\*q \*q" string \*q
Force the TV standard to either
.B PAL
or
.B NTSC.
On some machines with 630, 730 or the 315 series,
On some machines with 630, 730 and the 315/330 series,
.B PALM
and
,
.B PALN
and
.B NTSCJ
are supported as well. Default: BIOS setting.
.TP
.BI "Option \*qTVXPosOffset\*q \*q" integer \*q
This option allows horizontal relocation the TV output.
The range is from -32 to 32. Not supported on the Chrontel
7019.
This option allows tuning the horizontal position of the image for
TV output. The range is from -32 to 32. Not supported on the Chrontel
7019. Default: 0
.TP
.BI "Option \*qTVYPosOffset\*q \*q" integer \*q
This option allows vertical relocation the TV output.
The range is from -32 to 32. Not supported on the Chrontel
7019.
This option allows tuning the vertical position of the image for TV
output. The range is from -32 to 32. Not supported on the Chrontel
7019. Default: 0
.TP
.BI "Option \*qSISTVXScale\*q \*q" integer \*q
This option selects the horizontal zooming level for TV output. The range
is from -16 to 16. Only supported on SiS video bridges. Default: 0
.TP
.BI "Option \*qSISTVYScale\*q \*q" integer \*q
This option selects the vertical zooming level for TV output in the
following modes: 640x480, 800x600. On the 315/330 series, also 720x480,
720x576 and 768x576. The range is from -4 to 3. Only supported on
SiS video bridges. Default: 0
.TP
.BI "Option \*qCHTVOverscan\*q \*q" boolean \*q
On machines with a Chrontel TV encoder, this can be used to
force the TV mode to overscan or underscan.
.B True
On machines with a Chrontel TV encoder, this can be used to force the
TV mode to overscan or underscan.
.B on
means overscan,
.B false
.B off
means underscan.
Default: BIOS setting.
.TP
......@@ -343,57 +365,40 @@ enables a super-overscan mode. This is only supported if
the TV standard is PAL. Super overscan will produce an
image on the TV which is larger than the viewable area.
.PP
The driver supports many more TV related options. Please
see http://www.winischhofer.net/linuxsisvga.shtml for
The driver supports many more options. Please see
http://www.winischhofer.net/linuxsisvga.shtml for
more information.
.PP
.I "3. 300 series specific information"
.PP
DRI is supported on the 300 series only. DRI requires
the kernel's SiS framebuffer driver (
DRI is supported on the 300 series only. On Linux, DRI requires the
kernel's SiS framebuffer driver (
.B sisfb
) and some other modules
which come with either the kernel or XFree86.
.PP
Sisfb takes care of memory management for texture
data. In order to prevent the X driver and sisfb from
overwriting each others video memory, sisfb reserves
an amount of video memory for the X driver. This amount
can either be selected using sisfb's mem parameter, or
auto-selected depending on the amount of total video RAM
available. However, the X driver needs to know about the
amount of RAM sisfb reserved. For this purpose, the
) and some other modules which come with either the kernel or the X server.
.PP
Sisfb takes care of memory management for texture data. In order to
prevent the X Server and sisfb from overwriting each other's data,
sisfb reserves an amount of video memory for the X driver. This amount
can either be selected using sisfb's mem parameter, or auto-selected
depending on the amount of total video RAM available.
.PP
Sisfb can be used for memory management only, or as a complete framebuffer
driver. If you start sisfb with a valid mode (ie you gain a graphical console),
the X driver can communicate with sisfb and doesn't require any
manual configuration for finding out about the video memory it is allowed
to use.
However, if you are running a 2.4 series Linux kernel and use sisfb for
video memory management only, ie you started sisfb with mode=none and still
have a text mode console, there is no communication between sisfb and the
X driver. For this purpose,
the
.TP
.BI "Option \*qMaxXFBMem\*q \*q" integer \*q
.PP
exists.
.PP
XFree 4.3.0 disabled SiS DRI support. Old information follows:
.PP
At the moment (2003), the SiS DRI driver is not
maintained, lacks support for memory swapping and
has a few bugs. If you intend to use DRI, I recommend
setting the total video memory in the BIOS to 64MB
in order to at least overcome the lack of memory
swap functions.
.PP
Sisfb can be used for memory management only, or as
a complete framebuffer driver. If you start sisfb
with a valid mode (ie you gain a graphical console),
the X driver can communicate with sisfb and doesn't
require setting the
.B \*qMaxXFBMem\*q
option at all. The X driver will receive enough information
from sisfb in this case.
.PP
However, if you use sisfb for memory management only, ie
you started sisfb with mode=none and still have a text
mode console, there is no communication between sisfb
and the X driver. In this case, you need to set
.B \*qMaxXFBMem\*q
to the same value as you gave sisfb with its mem
parameter. If you didn't specify any mem parameter,
sisfb will reserve
exists. This option must be set to the same value as given to sisfb through
its "mem" parameter, ie the amount of memory to use for X in kilobytes.
.PP
If you started sisfb without the mem argument, sisfb will reserve
.TP
12288KB if more than 16MB of total video RAM is available,
.TP
......@@ -401,14 +406,24 @@ sisfb will reserve
.TP
4096KB in all other cases.
.PP
Then you need to specify any of these amounts as the
parameter for the
.B \*qMaxXFBMem\*q
option. The value is to be given without 'KB'.
If you intend to use DRI, I recommend setting the total video memory in
the BIOS to 64MB in order to at least overcome the lack of memory swap
functions.
.TP
.BI "Option \*qDRI\*q \*q" boolean \*q
This option allows enabling or disabling DRI. By default, DRI is on.
.TP
.BI "Option \*qAGPSize\*q \*q" integer \*q
This option allows selecting the amount of AGP memory to be used for DRI.
The amount is to be specified in megabyte, the default is 8.
.SH "KNOWN BUGS"
none.
.SH "SEE ALSO"
#ifdef __xservername__
__xservername__(__appmansuffix__), __xconfigfile__(__filemansuffix__), xorgconfig(__appmansuffix__), Xserver(__appmansuffix__), X(__miscmansuffix__)
#else
XFree86(1), XF86Config(__filemansuffix__), xf86config(1), Xserver(1), X(__miscmansuffix__)
#endif
.PP
.B "http://www.winischhofer.net/linuxsisvga.shtml"
for more information and updates
......
/* $XFree86: xc/programs/Xserver/hw/xfree86/drivers/sis/300vtbl.h,v 1.14 2003/07/28 12:39:45 twini Exp $ */
/* $XFree86$ */
/* $XdotOrg$ */
/*
* Register settings for SiS 300 series
*
* Copyright 2002, 2003 by Thomas Winischhofer, Vienna, Austria
* Copyright (C) 2001-2004 by Thomas Winischhofer, Vienna, Austria
*
* If distributed as part of the linux kernel, the contents of this file
* is entirely covered by the GPL.
* If distributed as part of the Linux kernel, the following license terms
* apply:
*
* Otherwise, the following terms apply:
* * This program is free software; you can redistribute it and/or modify
* * it under the terms of the GNU General Public License as published by
* * the Free Software Foundation; either version 2 of the named License,
* * or any later version.
* *
* * This program is distributed in the hope that it will be useful,
* * but WITHOUT ANY WARRANTY; without even the implied warranty of
* * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* * GNU General Public License for more details.
* *
* * You should have received a copy of the GNU General Public License
* * along with this program; if not, write to the Free Software
* * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA
*
* Permission to use, copy, modify, distribute, and sell this software and its
* documentation for any purpose is hereby granted without fee, provided that
* the above copyright notice appear in all copies and that both that
* copyright notice and this permission notice appear in supporting
* documentation, and that the name of the copyright holder not be used in
* advertising or publicity pertaining to distribution of the software without
* specific, written prior permission. The copyright holder makes no representations
* about the suitability of this software for any purpose. It is provided
* "as is" without express or implied warranty.
* Otherwise, the following license terms apply:
*
* THE COPYRIGHT HOLDER DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
* EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
* DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
* TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
* PERFORMANCE OF THIS SOFTWARE.
* * Redistribution and use in source and binary forms, with or without
* * modification, are permitted provided that the following conditions
* * are met:
* * 1) Redistributions of source code must retain the above copyright
* * notice, this list of conditions and the following disclaimer.
* * 2) Redistributions in binary form must reproduce the above copyright
* * notice, this list of conditions and the following disclaimer in the
* * documentation and/or other materials provided with the distribution.
* * 3) The name of the author may not be used to endorse or promote products
* * derived from this software without specific prior written permission.
* *
* * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESSED OR
* * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
* * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
* * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
* * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* Author: Thomas Winischhofer <thomas@winischhofer.net>
*
* Based on code by Silicon Intergrated Systems
*
*/
typedef struct _SiS300_StStruct
{
UCHAR St_ModeID;
USHORT St_ModeFlag;
UCHAR St_StTableIndex;
UCHAR St_CRT2CRTC;
UCHAR St_ResInfo;
UCHAR VB_StTVFlickerIndex;
UCHAR VB_StTVEdgeIndex;
UCHAR VB_StTVYFilterIndex;
} SiS300_StStruct;
static const SiS300_StStruct SiS300_SModeIDTable[] =
{
{0x01,0x9208,0x01,0x00,0x00,0x00,0x00,0x00},
{0x01,0x1210,0x14,0x01,0x01,0x00,0x00,0x00},
{0x01,0x1010,0x17,0x02,0x02,0x00,0x00,0x00},
{0x03,0x8208,0x03,0x00,0x00,0x00,0x00,0x00},
{0x03,0x0210,0x16,0x01,0x01,0x00,0x00,0x00},
{0x03,0x0010,0x18,0x02,0x02,0x00,0x00,0x00},
{0x05,0x9209,0x05,0x00,0x00,0x00,0x00,0x00},
{0x06,0x8209,0x06,0x00,0x00,0x00,0x00,0x00},
{0x07,0x0000,0x07,0x03,0x03,0x00,0x00,0x00},
{0x07,0x0000,0x19,0x02,0x02,0x00,0x00,0x00},
{0x0d,0x920a,0x0d,0x00,0x00,0x00,0x00,0x00},
{0x0e,0x820a,0x0e,0x00,0x00,0x00,0x00,0x00},
{0x0f,0x0202,0x11,0x01,0x01,0x00,0x00,0x00},
{0x10,0x0212,0x12,0x01,0x01,0x00,0x00,0x00},
{0x11,0x0212,0x1a,0x04,0x04,0x00,0x00,0x00},
{0x12,0x0212,0x1b,0x04,0x04,0x00,0x00,0x00},
{0x13,0x021b,0x1c,0x00,0x00,0x00,0x00,0x00},
{0x12,0x0010,0x18,0x02,0x02,0x00,0x00,0x00},
{0x12,0x0210,0x18,0x01,0x01,0x00,0x00,0x00},
{0xff, 0, 0, 0, 0, 0, 0, 0}
};
typedef struct _SiS300_ExtStruct
{
UCHAR Ext_ModeID;
USHORT Ext_ModeFlag;
USHORT Ext_ModeInfo;
USHORT Ext_VESAID;
UCHAR Ext_RESINFO;
UCHAR VB_ExtTVFlickerIndex;
UCHAR VB_ExtTVEdgeIndex;
UCHAR VB_ExtTVYFilterIndex;
UCHAR REFindex;
} SiS300_ExtStruct;
static const SiS300_ExtStruct SiS300_EModeIDTable[] =
{
{0x6a,0x2212,0x0407,0x0102,SIS_RI_800x600, 0x00,0x00,0x00,0x00}, /* 800x600x? */
{0x2e,0x0a1b,0x0306,0x0101,SIS_RI_640x480, 0x00,0x00,0x00,0x08},
{0x2f,0x021b,0x0305,0x0100,SIS_RI_640x400, 0x00,0x00,0x00,0x10}, /* 640x400x8 */
{0x30,0x2a1b,0x0407,0x0103,SIS_RI_800x600, 0x00,0x00,0x00,0x00},
{0x31,0x0a1b,0x0a0d,0x0000,SIS_RI_720x480, 0x00,0x00,0x00,0x11}, /* 720x480x8 */
{0x32,0x2a1b,0x0a0e,0x0000,SIS_RI_720x576, 0x00,0x00,0x00,0x12}, /* 720x576x8 */
{0x33,0x0a1d,0x0a0d,0x0000,SIS_RI_720x480, 0x00,0x00,0x00,0x11}, /* 720x480x16 */
{0x34,0x2a1d,0x0a0e,0x0000,SIS_RI_720x576, 0x00,0x00,0x00,0x12}, /* 720x576x16 */
{0x35,0x0a1f,0x0a0d,0x0000,SIS_RI_720x480, 0x00,0x00,0x00,0x11}, /* 720x480x32 */
{0x36,0x2a1f,0x0a0e,0x0000,SIS_RI_720x576, 0x00,0x00,0x00,0x12}, /* 720x576x32 */
{0x37,0x0212,0x0508,0x0104,SIS_RI_1024x768, 0x00,0x00,0x00,0x13}, /* 1024x768x? */
{0x38,0x0a1b,0x0508,0x0105,SIS_RI_1024x768, 0x00,0x00,0x00,0x13}, /* 1024x768x8 */
{0x3a,0x0e3b,0x0609,0x0107,SIS_RI_1280x1024,0x00,0x00,0x00,0x1a}, /* 1280x1024x8 */
{0x3c,0x063b,0x070a,0x0130,SIS_RI_1600x1200,0x00,0x00,0x00,0x1e},
{0x3d,0x067d,0x070a,0x0131,SIS_RI_1600x1200,0x00,0x00,0x00,0x1e},
{0x40,0x921c,0x0000,0x010d,SIS_RI_320x200, 0x00,0x00,0x00,0x23}, /* 320x200x15 */
{0x41,0x921d,0x0000,0x010e,SIS_RI_320x200, 0x00,0x00,0x00,0x23}, /* 320x200x16 */
{0x43,0x0a1c,0x0306,0x0110,SIS_RI_640x480, 0x00,0x00,0x00,0x08},
{0x44,0x0a1d,0x0306,0x0111,SIS_RI_640x480, 0x00,0x00,0x00,0x08},
{0x46,0x2a1c,0x0407,0x0113,SIS_RI_800x600, 0x00,0x00,0x00,0x00}, /* 800x600x15 */
{0x47,0x2a1d,0x0407,0x0114,SIS_RI_800x600, 0x00,0x00,0x00,0x00}, /* 800x600x16 */
{0x49,0x0a3c,0x0508,0x0116,SIS_RI_1024x768, 0x00,0x00,0x00,0x13},
{0x4a,0x0a3d,0x0508,0x0117,SIS_RI_1024x768, 0x00,0x00,0x00,0x13},
{0x4c,0x0e7c,0x0609,0x0119,SIS_RI_1280x1024,0x00,0x00,0x00,0x1a},
{0x4d,0x0e7d,0x0609,0x011a,SIS_RI_1280x1024,0x00,0x00,0x00,0x1a},
{0x50,0x921b,0x0001,0x0132,SIS_RI_320x240, 0x00,0x00,0x00,0x24}, /* 320x240x8 */
{0x51,0xb21b,0x0103,0x0133,SIS_RI_400x300, 0x00,0x00,0x00,0x25}, /* 400x300x8 */
{0x52,0x921b,0x0204,0x0134,SIS_RI_512x384, 0x00,0x00,0x00,0x26}, /* 512x384x8 */
{0x56,0x921d,0x0001,0x0135,SIS_RI_320x240, 0x00,0x00,0x00,0x24}, /* 320x240x16 */
{0x57,0xb21d,0x0103,0x0136,SIS_RI_400x300, 0x00,0x00,0x00,0x25}, /* 400x300x16 */
{0x58,0x921d,0x0204,0x0137,SIS_RI_512x384, 0x00,0x00,0x00,0x26}, /* 512x384x16 */
{0x59,0x921b,0x0000,0x0138,SIS_RI_320x200, 0x00,0x00,0x00,0x23}, /* 320x200x8 */
{0x5c,0x921f,0x0204,0x0000,SIS_RI_512x384, 0x00,0x00,0x00,0x26}, /* 512x384x32 */
{0x5d,0x021d,0x0305,0x0139,SIS_RI_640x400, 0x00,0x00,0x00,0x10}, /* 640x400x16 */
{0x5e,0x021f,0x0305,0x0000,SIS_RI_640x400, 0x00,0x00,0x00,0x10}, /* 640x400x32 */
{0x62,0x0a3f,0x0306,0x013a,SIS_RI_640x480, 0x00,0x00,0x00,0x08},
{0x63,0x2a3f,0x0407,0x013b,SIS_RI_800x600, 0x00,0x00,0x00,0x00}, /* 800x600x32 */
{0x64,0x0a7f,0x0508,0x013c,SIS_RI_1024x768, 0x00,0x00,0x00,0x13},
{0x65,0x0eff,0x0609,0x013d,SIS_RI_1280x1024,0x00,0x00,0x00,0x1a},
{0x66,0x06ff,0x070a,0x013e,SIS_RI_1600x1200,0x00,0x00,0x00,0x1e},
{0x68,0x067b,0x080b,0x013f,SIS_RI_1920x1440,0x00,0x00,0x00,0x27},
{0x69,0x06fd,0x080b,0x0140,SIS_RI_1920x1440,0x00,0x00,0x00,0x27},
{0x6b,0x07ff,0x080b,0x0000,SIS_RI_1920x1440,0x00,0x00,0x00,0x27},
{0x6c,0x067b,0x090c,0x0000,SIS_RI_2048x1536,0x00,0x00,0x00,0x28}, /* 2048x1536x8 - not in BIOS! */
{0x6d,0x06fd,0x090c,0x0000,SIS_RI_2048x1536,0x00,0x00,0x00,0x28}, /* 2048x1536x16 - not in BIOS! */
{0x70,0x2a1b,0x0400,0x0000,SIS_RI_800x480, 0x00,0x00,0x07,0x2d}, /* 800x480x8 */
{0x71,0x0a1b,0x0501,0x0000,SIS_RI_1024x576, 0x00,0x00,0x00,0x30}, /* 1024x576x8 */
{0x74,0x0a1d,0x0501,0x0000,SIS_RI_1024x576, 0x00,0x00,0x00,0x30}, /* 1024x576x16 */
{0x75,0x0e3d,0x0602,0x0000,SIS_RI_1280x720, 0x00,0x00,0x00,0x33}, /* 1280x720x16 */
{0x76,0x2a1f,0x0400,0x0000,SIS_RI_800x480, 0x00,0x00,0x07,0x2d}, /* 800x480x32 */
{0x77,0x0a3f,0x0501,0x0000,SIS_RI_1024x576, 0x00,0x00,0x00,0x30}, /* 1024x576x32 */
{0x78,0x0eff,0x0602,0x0000,SIS_RI_1280x720, 0x00,0x00,0x00,0x33}, /* 1280x720x32 */
{0x79,0x0e3b,0x0602,0x0000,SIS_RI_1280x720, 0x00,0x00,0x00,0x33}, /* 1280x720x8 */
{0x7a,0x2a1d,0x0400,0x0000,SIS_RI_800x480, 0x00,0x00,0x07,0x2d}, /* 800x480x16 */
{0x7c,0x0a3b,0x060f,0x0000,SIS_RI_1280x960, 0x00,0x00,0x00,0x29}, /* 1280x960x8 */
{0x7d,0x0a7d,0x060f,0x0000,SIS_RI_1280x960, 0x00,0x00,0x00,0x29}, /* 1280x960x16 */
{0x7e,0x0aff,0x060f,0x0000,SIS_RI_1280x960, 0x00,0x00,0x00,0x29}, /* 1280x960x32 */
{0x20,0x0a1b,0x0504,0x0000,SIS_RI_1024x600, 0x00,0x00,0x00,0x2b}, /* 1024x600 */
{0x21,0x0a3d,0x0504,0x0000,SIS_RI_1024x600, 0x00,0x00,0x00,0x2b},
{0x22,0x0a7f,0x0504,0x0000,SIS_RI_1024x600, 0x00,0x00,0x00,0x2b},
{0x23,0x0a1b,0x0c05,0x0000,SIS_RI_1152x768, 0x00,0x00,0x00,0x2c}, /* 1152x768 */
{0x24,0x0a3d,0x0c05,0x0000,SIS_RI_1152x768, 0x00,0x00,0x00,0x2c},
{0x25,0x0a7f,0x0c05,0x0000,SIS_RI_1152x768, 0x00,0x00,0x00,0x2c},
{0x29,0x0e1b,0x0c05,0x0000,SIS_RI_1152x864, 0x00,0x00,0x00,0x36}, /* 1152x864 */
{0x2a,0x0e3d,0x0c05,0x0000,SIS_RI_1152x864, 0x00,0x00,0x00,0x36},
{0x2b,0x0e7f,0x0c05,0x0000,SIS_RI_1152x864, 0x00,0x00,0x00,0x36},
{0x39,0x2a1b,0x0d06,0x0000,SIS_RI_848x480, 0x00,0x00,0x00,0x38}, /* 848x480 */
{0x3b,0x2a3d,0x0d06,0x0000,SIS_RI_848x480, 0x00,0x00,0x00,0x38},
{0x3e,0x2a7f,0x0d06,0x0000,SIS_RI_848x480, 0x00,0x00,0x00,0x38},
{0x3f,0x2a1b,0x0d07,0x0000,SIS_RI_856x480, 0x00,0x00,0x00,0x3a}, /* 856x480 */
{0x42,0x2a3d,0x0d07,0x0000,SIS_RI_856x480, 0x00,0x00,0x00,0x3a},
{0x45,0x2a7f,0x0d07,0x0000,SIS_RI_856x480, 0x00,0x00,0x00,0x3a},
{0x48,0x223b,0x0e08,0x0000,SIS_RI_1360x768, 0x00,0x00,0x00,0x3c}, /* 1360x768 */
{0x4b,0x227d,0x0e08,0x0000,SIS_RI_1360x768, 0x00,0x00,0x00,0x3c},
{0x4e,0x22ff,0x0e08,0x0000,SIS_RI_1360x768, 0x00,0x00,0x00,0x3c},
{0x4f,0x921f,0x0000,0x0000,SIS_RI_320x200, 0x00,0x00,0x00,0x23}, /* 320x200x32 */
{0x53,0x921f,0x0001,0x0000,SIS_RI_320x240, 0x00,0x00,0x00,0x24}, /* 320x240x32 */
{0x54,0xb21f,0x0103,0x0000,SIS_RI_400x300, 0x00,0x00,0x00,0x25}, /* 400x300x32 */
{0x55,0x2e3b,0x0609,0x0000,SIS_RI_1280x768, 0x00,0x00,0x00,0x3d}, /* 1280x768 */
{0x5a,0x2e7d,0x0609,0x0000,SIS_RI_1280x768, 0x00,0x00,0x00,0x3d},
{0x5b,0x2eff,0x0609,0x0000,SIS_RI_1280x768, 0x00,0x00,0x00,0x3d},
{0x5f,0x2a1b,0x0f0e,0x0000,SIS_RI_768x576, 0x00,0x00,0x00,0x3e}, /* 768x576x8 */
{0x60,0x2a1d,0x0f0e,0x0000,SIS_RI_768x576, 0x00,0x00,0x00,0x3e}, /* 768x576x16 */
{0x61,0x2a1f,0x0f0e,0x0000,SIS_RI_768x576, 0x00,0x00,0x00,0x3e}, /* 768x576x32 */
{0x67,0x2e3b,0x0e08,0x0000,SIS_RI_1360x1024,0x00,0x00,0x00,0x3f}, /* 1360x1024x8 (BARCO) */
{0x6f,0x2e7d,0x0e08,0x0000,SIS_RI_1360x1024,0x00,0x00,0x00,0x3f}, /* 1360x1024x16 (BARCO) */
{0x72,0x2eff,0x0e08,0x0000,SIS_RI_1360x1024,0x00,0x00,0x00,0x3f}, /* 1360x1024x32 (BARCO) */
{0xff,0x0000,0x0000,0xffff,0x00, 0x00,0x00,0x00,0x00}