summaryrefslogtreecommitdiff
path: root/src/i830_lvds.c
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2007-05-29 09:49:08 -0700
committerEric Anholt <eric@anholt.net>2007-05-29 11:07:50 -0700
commit906b974bfeeed18d79c244ad3db4f5d30e13e4c8 (patch)
tree9ac21ba7a7e9322d5c6fec542c0863c9244a8f5e /src/i830_lvds.c
parent4b2781291844b61b397e257a0fdb43e964e5f603 (diff)
Add a fixup to LVDS panel mode detection for 1280x768 panel from text mode.
Apparently some BIOSes will program a small mode with large blanking instead of using the pannel fitter.
Diffstat (limited to 'src/i830_lvds.c')
-rw-r--r--src/i830_lvds.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/i830_lvds.c b/src/i830_lvds.c
index 566c8689..ecc91aab 100644
--- a/src/i830_lvds.c
+++ b/src/i830_lvds.c
@@ -496,6 +496,22 @@ i830_lvds_init(ScrnInfoPtr pScrn)
dev_priv->panel_fixed_mode = i830_crtc_mode_get(pScrn, crtc);
if (dev_priv->panel_fixed_mode != NULL)
dev_priv->panel_fixed_mode->type |= M_T_PREFERRED;
+
+ /* Fixup for a 1280x768 panel with the horizontal trimmed
+ * down to 1024 for text mode.
+ */
+ if (!xf86ModesEqual(dev_priv->panel_fixed_mode, bios_mode) &&
+ dev_priv->panel_fixed_mode->HDisplay == 1024 &&
+ dev_priv->panel_fixed_mode->HSyncStart == 1200 &&
+ dev_priv->panel_fixed_mode->HSyncEnd == 1312 &&
+ dev_priv->panel_fixed_mode->HTotal == 1688 &&
+ dev_priv->panel_fixed_mode->VDisplay == 768)
+ {
+ dev_priv->panel_fixed_mode->HDisplay = 1280;
+ dev_priv->panel_fixed_mode->HSyncStart = 1328;
+ dev_priv->panel_fixed_mode->HSyncEnd = 1440;
+ dev_priv->panel_fixed_mode->HTotal = 1688;
+ }
}
}