summaryrefslogtreecommitdiff
path: root/src/radeon_driver.c
diff options
context:
space:
mode:
authorAlex Deucher <alex@botch2.(none)>2007-12-11 11:57:27 -0500
committerAlex Deucher <alex@botch2.(none)>2007-12-11 11:57:27 -0500
commitf3d2ec3a5ae61215c792018320158750e7aa937c (patch)
treeb166a8e2d7afba01dc6a51266ac08b072cf6ba40 /src/radeon_driver.c
parent9b125312ab6edc585e4f5931a6a6de81e13b6acc (diff)
RADEON: rewrite PLL computation
Algorithm adapted from BeOS radeon driver with some tweaks by me. Actually calulate and use the reference divider rather than using the bios default. Also, always calculate the PLL, rather than falling back to bios dividers. This should fix bugs 12913, 13590, 13533, possibly others.
Diffstat (limited to 'src/radeon_driver.c')
-rw-r--r--src/radeon_driver.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/radeon_driver.c b/src/radeon_driver.c
index 50f78eb..4b5008e 100644
--- a/src/radeon_driver.c
+++ b/src/radeon_driver.c
@@ -1063,6 +1063,15 @@ static void RADEONGetClockInfo(ScrnInfoPtr pScrn)
info->RamWidth / 16);
}
+ /* card limits for computing PLLs */
+ pll->min_ref_div = 2;
+ pll->max_ref_div = 0x3ff;
+ pll->min_feedback_div = 4;
+ pll->max_feedback_div = 0x7ff;
+ pll->pll_in_min = 40;
+ pll->pll_in_max = 100;
+ pll->best_vco = 0;
+
xf86DrvMsg (pScrn->scrnIndex, X_INFO,
"PLL parameters: rf=%u rd=%u min=%u max=%u; xclk=%u\n",
pll->reference_freq,