summaryrefslogtreecommitdiff
path: root/src/i830_crt.c
diff options
context:
space:
mode:
authorKeith Packard <keithp@bouzouki.jf.intel.com>2006-12-06 12:53:22 -0800
committerKeith Packard <keithp@bouzouki.jf.intel.com>2006-12-06 12:53:22 -0800
commit6ee63364f5fabbc5578bcc9ded38c778595f5a6d (patch)
treeabcd0c3f0242c81ad8d411c9b6d83e5082f4411b /src/i830_crt.c
parent56f71194157ef929b62fe34a89c840bd59e56301 (diff)
parentb75ecdb48309a15eb7c52b279c7f8523a95bcd48 (diff)
Merge branch 'modesetting' into nonrandr-setup
Also, fix buffer overflow in i830_debug.c
Diffstat (limited to 'src/i830_crt.c')
-rw-r--r--src/i830_crt.c20
1 files changed, 11 insertions, 9 deletions
diff --git a/src/i830_crt.c b/src/i830_crt.c
index 1bb52d41..3be10ecc 100644
--- a/src/i830_crt.c
+++ b/src/i830_crt.c
@@ -93,13 +93,16 @@ i830_crt_mode_valid(xf86OutputPtr output, DisplayModePtr pMode)
return MODE_OK;
}
-static void
-i830_crt_pre_set_mode (xf86OutputPtr output, DisplayModePtr pMode)
+static Bool
+i830_crt_mode_fixup(xf86OutputPtr output, DisplayModePtr mode,
+ DisplayModePtr adjusted_mode)
{
+ return TRUE;
}
static void
-i830_crt_post_set_mode (xf86OutputPtr output, DisplayModePtr pMode)
+i830_crt_mode_set(xf86OutputPtr output, DisplayModePtr mode,
+ DisplayModePtr adjusted_mode)
{
ScrnInfoPtr pScrn = output->scrn;
I830Ptr pI830 = I830PTR(pScrn);
@@ -122,11 +125,10 @@ i830_crt_post_set_mode (xf86OutputPtr output, DisplayModePtr pMode)
OUTREG(dpll_md_reg, dpll_md & ~DPLL_MD_UDI_MULTIPLIER_MASK);
}
- adpa = ADPA_DAC_ENABLE;
-
- if (pMode->Flags & V_PHSYNC)
+ adpa = 0;
+ if (adjusted_mode->Flags & V_PHSYNC)
adpa |= ADPA_HSYNC_ACTIVE_HIGH;
- if (pMode->Flags & V_PVSYNC)
+ if (adjusted_mode->Flags & V_PVSYNC)
adpa |= ADPA_VSYNC_ACTIVE_HIGH;
if (i830_crtc->pipe == 0)
@@ -370,8 +372,8 @@ static const xf86OutputFuncsRec i830_crt_output_funcs = {
.save = i830_crt_save,
.restore = i830_crt_restore,
.mode_valid = i830_crt_mode_valid,
- .pre_set_mode = i830_crt_pre_set_mode,
- .post_set_mode = i830_crt_post_set_mode,
+ .mode_fixup = i830_crt_mode_fixup,
+ .mode_set = i830_crt_mode_set,
.detect = i830_crt_detect,
.get_modes = i830_crt_get_modes,
.destroy = i830_crt_destroy