diff options
author | Adam Jackson <ajax@redhat.com> | 2009-02-23 15:44:26 -0500 |
---|---|---|
committer | Adam Jackson <ajax@redhat.com> | 2009-02-23 15:46:25 -0500 |
commit | 8fd0e46571c7ba15c05f0a759113f8ca842c76a2 (patch) | |
tree | ecec0d9a2e253a70e07338590b66e0d6f12043c5 | |
parent | 73bc7f113969834d00cd92be8374dbadc62f96a9 (diff) |
Limit CRT DAC speed better.
Verified against the public docs for i8xx parts, although not 9xx yet.
-rw-r--r-- | src/i830_crt.c | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/src/i830_crt.c b/src/i830_crt.c index 605ecf9e..984e77c8 100644 --- a/src/i830_crt.c +++ b/src/i830_crt.c @@ -84,11 +84,23 @@ i830_crt_restore (xf86OutputPtr output) static int i830_crt_mode_valid(xf86OutputPtr output, DisplayModePtr pMode) { + ScrnInfoPtr pScrn = output->scrn; + I830Ptr pI830 = I830Ptr(pScrn); + int maxclock; + if (pMode->Flags & V_DBLSCAN) return MODE_NO_DBLESCAN; - if (pMode->Clock > 400000 || pMode->Clock < 25000) - return MODE_CLOCK_RANGE; + if (pMode->Clock < 25000) + return MODE_CLOCK_LOW; + + if (!IS_I9XX(pI830)) + maxclock = 350000; + else + maxclock = 400000; + + if (pMode->Clock > maxclock) + return MODE_CLOCK_HIGH; return MODE_OK; } |